diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 819babdbf5a2..dbeb29f12dc0 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -3893,7 +3893,7 @@ packages: dependencies: semver: 7.3.8 shelljs: 0.8.5 - typescript: 5.1.0-dev.20230320 + typescript: 5.1.0-dev.20230321 dev: false /ecdsa-sig-formatter/1.0.11: @@ -8749,8 +8749,8 @@ packages: hasBin: true dev: false - /typescript/5.1.0-dev.20230320: - resolution: {integrity: sha512-UWob7IhN/k84vqndbUwXaUNuLfzpgaD3wYm2FAKCUjXE0sMn5rf0Z+A8N2glIfqQBnBObLzIitWepn3TRF9Sjg==} + /typescript/5.1.0-dev.20230321: + resolution: {integrity: sha512-GFq3xvjbJImoKgCDJEiB7Bsa1wQdu/9tlb8Qj475ydSraETbCLzy+Ao3cqQ+KWBM6Mqo+0b1rrpe2Gj0DZz2+w==} engines: {node: '>=12.20'} hasBin: true dev: false @@ -10115,7 +10115,7 @@ packages: dev: false file:projects/arm-appservice-1.tgz: - resolution: {integrity: sha512-Uf11brTpSmZY3Zsj4RZ5gVaTMWOOni6WrFQyLkrb3Sl0MD1m0F2jxaroxMUAGS3hhGRw6AYyBMTsWgBCOSTksw==, tarball: file:projects/arm-appservice-1.tgz} + resolution: {integrity: sha512-Ym0QiyDOZKB1Lya6Z1GBJR8YN6nc5UVO4WHL+vYhC5M+L0FpWGfVClg0x0eFCRE0xh1G4BKnTg2kmbMzzry3iw==, tarball: file:projects/arm-appservice-1.tgz} name: '@rush-temp/arm-appservice-1' version: 0.0.0 dependencies: @@ -10129,7 +10129,8 @@ packages: '@types/node': 14.18.38 chai: 4.3.7 cross-env: 7.0.3 - mkdirp: 1.0.4 + dotenv: 16.0.3 + mkdirp: 2.1.5 mocha: 7.2.0 rimraf: 3.0.2 rollup: 2.79.1 @@ -12170,19 +12171,19 @@ packages: dev: false file:projects/arm-graphservices.tgz: - resolution: {integrity: sha512-FGMQq6BOIpb01GiMS1PDpo/y17Bb9bxNSMVtLJRoORxpGlTgbpDWB+1o65n5kZ4P2Sda2DScSr+Oml3uXoC3kg==, tarball: file:projects/arm-graphservices.tgz} + resolution: {integrity: sha512-W4Mpd/2C0oFq2ylu1h0QbdANHiy70H5DmfFjBxsY/9xE4X9IV9DlihvCO6i+VJNC0X7BTlvGmfa9JLVgFLjqxg==, tarball: file:projects/arm-graphservices.tgz} name: '@rush-temp/arm-graphservices' version: 0.0.0 dependencies: '@azure-tools/test-recorder': 2.0.0 '@azure/identity': 2.1.0 - '@microsoft/api-extractor': 7.34.4_@types+node@14.18.37 + '@microsoft/api-extractor': 7.34.4_@types+node@14.18.38 '@rollup/plugin-commonjs': 24.0.1_rollup@2.79.1 '@rollup/plugin-json': 6.0.0_rollup@2.79.1 '@rollup/plugin-multi-entry': 6.0.0_rollup@2.79.1 '@rollup/plugin-node-resolve': 13.3.0_rollup@2.79.1 '@types/chai': 4.3.4 - '@types/node': 14.18.37 + '@types/node': 14.18.38 chai: 4.3.7 cross-env: 7.0.3 dotenv: 16.0.3 @@ -12190,12 +12191,11 @@ packages: mocha: 7.2.0 rimraf: 3.0.2 rollup: 2.79.1 - rollup-plugin-sourcemaps: 0.6.3_uvqxrz6xmh6o32kxhfeqlqrt5q + rollup-plugin-sourcemaps: 0.6.3_rrfo4ccoq6ga3fxzubpgdsawvq tslib: 2.5.0 typescript: 4.8.4 uglify-js: 3.17.4 transitivePeerDependencies: - - encoding - supports-color dev: false diff --git a/sdk/appservice/arm-appservice/CHANGELOG.md b/sdk/appservice/arm-appservice/CHANGELOG.md index aaadcd276991..c59a89463ab3 100644 --- a/sdk/appservice/arm-appservice/CHANGELOG.md +++ b/sdk/appservice/arm-appservice/CHANGELOG.md @@ -1,15 +1,190 @@ # Release History + +## 14.0.0 (2023-03-10) + +**Features** -## 13.0.4 (Unreleased) - -### Features Added - -### Breaking Changes - -### Bugs Fixed + - Added operation StaticSites.createOrUpdateBasicAuth + - Added operation StaticSites.createOrUpdateBuildDatabaseConnection + - Added operation StaticSites.createOrUpdateDatabaseConnection + - Added operation StaticSites.deleteBuildDatabaseConnection + - Added operation StaticSites.deleteDatabaseConnection + - Added operation StaticSites.getBasicAuth + - Added operation StaticSites.getBuildDatabaseConnection + - Added operation StaticSites.getBuildDatabaseConnectionWithDetails + - Added operation StaticSites.getDatabaseConnection + - Added operation StaticSites.getDatabaseConnectionWithDetails + - Added operation StaticSites.listBasicAuth + - Added operation StaticSites.listBuildDatabaseConnections + - Added operation StaticSites.listBuildDatabaseConnectionsWithDetails + - Added operation StaticSites.listDatabaseConnections + - Added operation StaticSites.listDatabaseConnectionsWithDetails + - Added operation StaticSites.updateBuildDatabaseConnection + - Added operation StaticSites.updateDatabaseConnection + - Added operation WebApps.deployWorkflowArtifacts + - Added operation WebApps.deployWorkflowArtifactsSlot + - Added operation WebApps.getInstanceWorkflowSlot + - Added operation WebApps.getWorkflow + - Added operation WebApps.listInstanceWorkflowsSlot + - Added operation WebApps.listWorkflows + - Added operation WebApps.listWorkflowsConnections + - Added operation WebApps.listWorkflowsConnectionsSlot + - Added Interface AppServiceEnvironmentsCreateOrUpdateHeaders + - Added Interface DatabaseConnection + - Added Interface DatabaseConnectionCollection + - Added Interface DatabaseConnectionOverview + - Added Interface DatabaseConnectionPatchRequest + - Added Interface StaticSiteBasicAuthPropertiesARMResource + - Added Interface StaticSiteBasicAuthPropertiesCollection + - Added Interface StaticSiteDatabaseConnectionConfigurationFileOverview + - Added Interface StaticSitesCreateOrUpdateBasicAuthOptionalParams + - Added Interface StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams + - Added Interface StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams + - Added Interface StaticSitesDeleteBuildDatabaseConnectionOptionalParams + - Added Interface StaticSitesDeleteDatabaseConnectionOptionalParams + - Added Interface StaticSitesGetBasicAuthOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionsNextOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionsOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionsWithDetailsNextOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + - Added Interface StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionsNextOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionsOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionsWithDetailsNextOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + - Added Interface StaticSitesGetDatabaseConnectionWithDetailsOptionalParams + - Added Interface StaticSitesListBasicAuthNextOptionalParams + - Added Interface StaticSitesListBasicAuthOptionalParams + - Added Interface StaticSitesUpdateBuildDatabaseConnectionOptionalParams + - Added Interface StaticSitesUpdateDatabaseConnectionOptionalParams + - Added Interface WebAppsDeployWorkflowArtifactsOptionalParams + - Added Interface WebAppsDeployWorkflowArtifactsSlotOptionalParams + - Added Interface WebAppsGetInstanceWorkflowSlotOptionalParams + - Added Interface WebAppsGetWorkflowOptionalParams + - Added Interface WebAppsListInstanceWorkflowsSlotNextOptionalParams + - Added Interface WebAppsListInstanceWorkflowsSlotOptionalParams + - Added Interface WebAppsListWorkflowsConnectionsOptionalParams + - Added Interface WebAppsListWorkflowsConnectionsSlotOptionalParams + - Added Interface WebAppsListWorkflowsNextOptionalParams + - Added Interface WebAppsListWorkflowsOptionalParams + - Added Interface WorkflowArtifacts + - Added Interface WorkflowEnvelope + - Added Interface WorkflowEnvelopeCollection + - Added Interface WorkflowEnvelopeProperties + - Added Interface WorkflowHealth + - Added Type Alias BasicAuthName + - Added Type Alias DefaultAction + - Added Type Alias ProviderOsTypeSelected + - Added Type Alias ProviderStackOsType + - Added Type Alias StaticSitesCreateOrUpdateBasicAuthResponse + - Added Type Alias StaticSitesCreateOrUpdateBuildDatabaseConnectionResponse + - Added Type Alias StaticSitesCreateOrUpdateDatabaseConnectionResponse + - Added Type Alias StaticSitesGetBasicAuthResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionsNextResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionsResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionsWithDetailsNextResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionsWithDetailsResponse + - Added Type Alias StaticSitesGetBuildDatabaseConnectionWithDetailsResponse + - Added Type Alias StaticSitesGetDatabaseConnectionResponse + - Added Type Alias StaticSitesGetDatabaseConnectionsNextResponse + - Added Type Alias StaticSitesGetDatabaseConnectionsResponse + - Added Type Alias StaticSitesGetDatabaseConnectionsWithDetailsNextResponse + - Added Type Alias StaticSitesGetDatabaseConnectionsWithDetailsResponse + - Added Type Alias StaticSitesGetDatabaseConnectionWithDetailsResponse + - Added Type Alias StaticSitesListBasicAuthNextResponse + - Added Type Alias StaticSitesListBasicAuthResponse + - Added Type Alias StaticSitesUpdateBuildDatabaseConnectionResponse + - Added Type Alias StaticSitesUpdateDatabaseConnectionResponse + - Added Type Alias WebAppsGetInstanceWorkflowSlotResponse + - Added Type Alias WebAppsGetWorkflowResponse + - Added Type Alias WebAppsListInstanceWorkflowsSlotNextResponse + - Added Type Alias WebAppsListInstanceWorkflowsSlotResponse + - Added Type Alias WebAppsListWorkflowsConnectionsResponse + - Added Type Alias WebAppsListWorkflowsConnectionsSlotResponse + - Added Type Alias WebAppsListWorkflowsNextResponse + - Added Type Alias WebAppsListWorkflowsResponse + - Added Type Alias WorkflowHealthState + - Interface Site has a new optional parameter managedEnvironmentId + - Interface SiteConfig has a new optional parameter elasticWebAppScaleLimit + - Interface SiteConfig has a new optional parameter ipSecurityRestrictionsDefaultAction + - Interface SiteConfig has a new optional parameter metadata + - Interface SiteConfig has a new optional parameter scmIpSecurityRestrictionsDefaultAction + - Interface SiteConfigResource has a new optional parameter elasticWebAppScaleLimit + - Interface SiteConfigResource has a new optional parameter ipSecurityRestrictionsDefaultAction + - Interface SiteConfigResource has a new optional parameter metadata + - Interface SiteConfigResource has a new optional parameter scmIpSecurityRestrictionsDefaultAction + - Interface StaticSiteARMResource has a new optional parameter databaseConnections + - Interface StaticSiteBuildARMResource has a new optional parameter databaseConnections + - Interface StaticSitePatchResource has a new optional parameter databaseConnections + - Added Enum KnownBasicAuthName + - Added Enum KnownDefaultAction + - Added Enum KnownProviderOsTypeSelected + - Added Enum KnownProviderStackOsType + - Interface AppServiceEnvironmentsListUsagesNextOptionalParams no longer has parameter filter + - Interface AppServiceEnvironmentsListWebAppsNextOptionalParams no longer has parameter propertiesToInclude + - Interface AppServicePlansListNextOptionalParams no longer has parameter detailed + - Interface AppServicePlansListUsagesNextOptionalParams no longer has parameter filter + - Interface AppServicePlansListWebAppsNextOptionalParams no longer has parameter filter + - Interface AppServicePlansListWebAppsNextOptionalParams no longer has parameter skipToken + - Interface AppServicePlansListWebAppsNextOptionalParams no longer has parameter top + - Interface CertificatesListNextOptionalParams no longer has parameter filter + - Interface ListBillingMetersNextOptionalParams no longer has parameter billingLocation + - Interface ListBillingMetersNextOptionalParams no longer has parameter osType + - Interface ListCustomHostNameSitesNextOptionalParams no longer has parameter hostname + - Interface ListGeoRegionsNextOptionalParams no longer has parameter linuxDynamicWorkersEnabled + - Interface ListGeoRegionsNextOptionalParams no longer has parameter linuxWorkersEnabled + - Interface ListGeoRegionsNextOptionalParams no longer has parameter sku + - Interface ListGeoRegionsNextOptionalParams no longer has parameter xenonWorkersEnabled + - Interface ProviderGetAvailableStacksNextOptionalParams no longer has parameter osTypeSelected + - Interface ProviderGetAvailableStacksOnPremNextOptionalParams no longer has parameter osTypeSelected + - Interface ProviderGetFunctionAppStacksForLocationNextOptionalParams no longer has parameter stackOsType + - Interface ProviderGetFunctionAppStacksNextOptionalParams no longer has parameter stackOsType + - Interface ProviderGetWebAppStacksForLocationNextOptionalParams no longer has parameter stackOsType + - Interface ProviderGetWebAppStacksNextOptionalParams no longer has parameter stackOsType + - Interface RecommendationsListHistoryForHostingEnvironmentNextOptionalParams no longer has parameter expiredOnly + - Interface RecommendationsListHistoryForHostingEnvironmentNextOptionalParams no longer has parameter filter + - Interface RecommendationsListHistoryForWebAppNextOptionalParams no longer has parameter expiredOnly + - Interface RecommendationsListHistoryForWebAppNextOptionalParams no longer has parameter filter + - Interface RecommendationsListNextOptionalParams no longer has parameter featured + - Interface RecommendationsListNextOptionalParams no longer has parameter filter + - Interface RecommendationsListRecommendedRulesForHostingEnvironmentNextOptionalParams no longer has parameter featured + - Interface RecommendationsListRecommendedRulesForHostingEnvironmentNextOptionalParams no longer has parameter filter + - Interface RecommendationsListRecommendedRulesForWebAppNextOptionalParams no longer has parameter featured + - Interface RecommendationsListRecommendedRulesForWebAppNextOptionalParams no longer has parameter filter + - Interface WebAppsListByResourceGroupNextOptionalParams no longer has parameter includeSlots + - Interface WebAppsListPerfMonCountersNextOptionalParams no longer has parameter filter + - Interface WebAppsListPerfMonCountersSlotNextOptionalParams no longer has parameter filter + - Interface WebAppsListUsagesNextOptionalParams no longer has parameter filter + - Interface WebAppsListUsagesSlotNextOptionalParams no longer has parameter filter + - Interface WorkflowRunActionsListNextOptionalParams no longer has parameter filter + - Interface WorkflowRunActionsListNextOptionalParams no longer has parameter top + - Interface WorkflowRunsListNextOptionalParams no longer has parameter filter + - Interface WorkflowRunsListNextOptionalParams no longer has parameter top + - Interface WorkflowTriggerHistoriesListNextOptionalParams no longer has parameter filter + - Interface WorkflowTriggerHistoriesListNextOptionalParams no longer has parameter top + - Interface WorkflowTriggersListNextOptionalParams no longer has parameter filter + - Interface WorkflowTriggersListNextOptionalParams no longer has parameter top + - Interface WorkflowVersionsListNextOptionalParams no longer has parameter top -### Other Changes +**Breaking Changes** + - Type of parameter osTypeSelected of interface ProviderGetAvailableStacksOnPremOptionalParams is changed from Enum19 to ProviderOsTypeSelected + - Type of parameter osTypeSelected of interface ProviderGetAvailableStacksOptionalParams is changed from Enum14 to ProviderOsTypeSelected + - Type of parameter stackOsType of interface ProviderGetFunctionAppStacksForLocationOptionalParams is changed from Enum16 to ProviderStackOsType + - Type of parameter stackOsType of interface ProviderGetFunctionAppStacksOptionalParams is changed from Enum15 to ProviderStackOsType + - Type of parameter stackOsType of interface ProviderGetWebAppStacksForLocationOptionalParams is changed from Enum17 to ProviderStackOsType + - Type of parameter stackOsType of interface ProviderGetWebAppStacksOptionalParams is changed from Enum18 to ProviderStackOsType + - Removed Enum KnownEnum14 + - Removed Enum KnownEnum15 + - Removed Enum KnownEnum16 + - Removed Enum KnownEnum17 + - Removed Enum KnownEnum18 + - Removed Enum KnownEnum19 + - Removed Enum KnownWorkflowState + ## 13.0.3 (2022-11-16) - Bugs Fixed diff --git a/sdk/appservice/arm-appservice/LICENSE b/sdk/appservice/arm-appservice/LICENSE index 5d1d36e0af80..3a1d9b6f24f7 100644 --- a/sdk/appservice/arm-appservice/LICENSE +++ b/sdk/appservice/arm-appservice/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2023 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/appservice/arm-appservice/_meta.json b/sdk/appservice/arm-appservice/_meta.json index afa44d72ad1c..883f7870d67f 100644 --- a/sdk/appservice/arm-appservice/_meta.json +++ b/sdk/appservice/arm-appservice/_meta.json @@ -1,8 +1,8 @@ { - "commit": "492f46331542f76339473ce20ec49ceffe794fff", - "readme": "specification\\web\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\web\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "commit": "4f4044394791773e6e7e82a9bd90d3935caaca1b", + "readme": "specification/web/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\web\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.9 --generate-sample=true", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.6.2", + "use": "@autorest/typescript@6.0.0-rc.9" } \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/package.json b/sdk/appservice/arm-appservice/package.json index 91346dbe8872..d4fc4b1b2c79 100644 --- a/sdk/appservice/arm-appservice/package.json +++ b/sdk/appservice/arm-appservice/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for WebSiteManagementClient.", - "version": "13.0.4", + "version": "14.0.0", "engines": { "node": ">=14.0.0" }, "dependencies": { - "@azure/core-lro": "^2.2.0", + "@azure/core-lro": "^2.5.0", "@azure/abort-controller": "^1.0.0", "@azure/core-paging": "^1.2.0", - "@azure/core-client": "^1.6.1", + "@azure/core-client": "^1.7.0", "@azure/core-auth": "^1.3.0", "@azure/core-rest-pipeline": "^1.8.0", "tslib": "^2.2.0" @@ -33,12 +33,13 @@ "@rollup/plugin-json": "^6.0.0", "@rollup/plugin-multi-entry": "^6.0.0", "@rollup/plugin-node-resolve": "^13.1.3", - "mkdirp": "^1.0.4", + "mkdirp": "^2.1.2", "rollup": "^2.66.1", "rollup-plugin-sourcemaps": "^0.6.3", "typescript": "~4.8.0", "uglify-js": "^3.4.9", "rimraf": "^3.0.0", + "dotenv": "^16.0.0", "@azure/identity": "^2.0.1", "@azure-tools/test-recorder": "^3.0.0", "@azure-tools/test-credential": "^1.0.0", @@ -49,7 +50,6 @@ "@types/node": "^14.0.0", "@azure/dev-tool": "^1.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -111,6 +111,7 @@ ] }, "autoPublish": true, + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice", "//sampleConfiguration": { "productName": "", "productSlugs": [ diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_create_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_create_test.json index d3fe5e482202..40741a847ecc 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_create_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_create_test.json @@ -1,7 +1,7 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-09-01", "RequestMethod": "PUT", "RequestHeaders": { "Accept": "application/json", @@ -10,8 +10,8 @@ "Connection": "keep-alive", "Content-Length": "126", "Content-Type": "application/json", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "0228d245-0caf-417d-9a57-4ba3cbf83033" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "45b40786-78c6-4765-b09e-11025cb517e5" }, "RequestBody": { "location": "eastus", @@ -30,8 +30,8 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:15:52 GMT", - "ETag": "\u00221D8F969BAD78B40\u0022", + "Date": "Mon, 20 Mar 2023 06:45:23 GMT", + "ETag": "\u00221D95AF78AE51D75\u0022", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -40,10 +40,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "9c303785-2940-4fd7-8d7a-d98fe8214535", - "x-ms-ratelimit-remaining-subscription-writes": "1197", - "x-ms-request-id": "e2e33f68-5161-425e-9866-4cca9d70d4c6", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031552Z:9c303785-2940-4fd7-8d7a-d98fe8214535", + "x-ms-correlation-request-id": "51db554e-5f85-4940-ba7f-fa4ebab7a236", + "x-ms-ratelimit-remaining-subscription-writes": "1199", + "x-ms-request-id": "a8a2de0a-98cc-4057-aa68-76635be81f38", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064523Z:51db554e-5f85-4940-ba7f-fa4ebab7a236", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -53,7 +53,7 @@ "kind": "app", "location": "eastus", "properties": { - "serverFarmId": 23123, + "serverFarmId": 8742, "name": "myappserviceplanxxx", "sku": { "name": "S1", @@ -95,7 +95,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "mdmId": "waws-prod-blu-357_23123", + "mdmId": "waws-prod-blu-395_8742", "targetWorkerCount": 0, "targetWorkerSizeId": 0, "provisioningState": "Succeeded", diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_delete_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_delete_test.json index a91f14a450e7..fbaad08301d9 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_delete_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_delete_test.json @@ -1,46 +1,46 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-09-01", "RequestMethod": "DELETE", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "a8e1c213-a469-47c8-92fd-c9c665bb1902" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "994f4a0a-92b4-4674-b8b0-24bd0f29429a" }, "RequestBody": null, "StatusCode": 200, "ResponseHeaders": { "Cache-Control": "no-cache", "Content-Length": "0", - "Date": "Wed, 16 Nov 2022 03:16:44 GMT", + "Date": "Mon, 20 Mar 2023 06:46:21 GMT", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", "Strict-Transport-Security": "max-age=31536000; includeSubDomains", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "8ddd7622-ca48-4d99-b822-380d2f88ed5f", - "x-ms-ratelimit-remaining-subscription-deletes": "14994", - "x-ms-request-id": "d4d9f3af-20ea-430e-8686-cadd6a7ace63", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031644Z:8ddd7622-ca48-4d99-b822-380d2f88ed5f", + "x-ms-correlation-request-id": "4648a155-1a78-4c85-9eaf-f905f5eeae92", + "x-ms-ratelimit-remaining-subscription-deletes": "14998", + "x-ms-request-id": "78ea8c36-4ec4-4ef6-9b31-fd456e5e939b", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064621Z:4648a155-1a78-4c85-9eaf-f905f5eeae92", "X-Powered-By": "ASP.NET" }, "ResponseBody": null }, { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "3807a75c-1da4-48ce-aade-ca0a9e186391" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "a426b097-52e7-4f68-8492-af9f9be49565" }, "RequestBody": null, "StatusCode": 200, @@ -49,16 +49,16 @@ "Content-Encoding": "gzip", "Content-Length": "12", "Content-Type": "application/json; charset=utf-8", - "Date": "Wed, 16 Nov 2022 03:16:44 GMT", + "Date": "Mon, 20 Mar 2023 06:46:21 GMT", "Expires": "-1", "Pragma": "no-cache", "Strict-Transport-Security": "max-age=31536000; includeSubDomains", "Vary": "Accept-Encoding", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "a44404e8-5497-402d-bf48-38992ec03097", - "x-ms-ratelimit-remaining-subscription-reads": "11982", - "x-ms-request-id": "a44404e8-5497-402d-bf48-38992ec03097", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031645Z:a44404e8-5497-402d-bf48-38992ec03097" + "x-ms-correlation-request-id": "a439490f-f98c-4e2c-8a86-06bc98d6c266", + "x-ms-ratelimit-remaining-subscription-reads": "11994", + "x-ms-request-id": "a439490f-f98c-4e2c-8a86-06bc98d6c266", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064622Z:a439490f-f98c-4e2c-8a86-06bc98d6c266" }, "ResponseBody": { "value": [] diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_get_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_get_test.json index 8557f051b929..8092fe1d670a 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_get_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_get_test.json @@ -1,15 +1,15 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms/myappserviceplanxxx?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "60706582-c378-4e39-b3ac-8a06260a121c" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "d0a42c42-26af-41ac-95e0-2df1554702c8" }, "RequestBody": null, "StatusCode": 200, @@ -17,7 +17,7 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:16 GMT", + "Date": "Mon, 20 Mar 2023 06:45:50 GMT", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -26,10 +26,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "948b251c-2c8d-4cf7-9031-202a62668937", - "x-ms-ratelimit-remaining-subscription-reads": "11987", - "x-ms-request-id": "d2ee68ba-88ec-4521-b9fe-de47972f76b5", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031616Z:948b251c-2c8d-4cf7-9031-202a62668937", + "x-ms-correlation-request-id": "5095d877-be9e-4424-894a-8de980d440a9", + "x-ms-ratelimit-remaining-subscription-reads": "11999", + "x-ms-request-id": "bdaf505b-20ee-41c2-82aa-8c8062f4d252", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064550Z:5095d877-be9e-4424-894a-8de980d440a9", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -39,7 +39,7 @@ "kind": "app", "location": "East US", "properties": { - "serverFarmId": 23123, + "serverFarmId": 8742, "name": "myappserviceplanxxx", "workerSize": "Default", "workerSizeId": 0, @@ -74,7 +74,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "mdmId": "waws-prod-blu-357_23123", + "mdmId": "waws-prod-blu-395_8742", "targetWorkerCount": 0, "targetWorkerSizeId": 0, "provisioningState": "Succeeded", diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_list_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_list_test.json index fd27b6f5b801..ff257648fd21 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_list_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_appserviceplans_list_test.json @@ -1,15 +1,15 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/serverfarms?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "d85455a6-d8cf-43d2-a3fd-c63e268de4c6" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "dcd3b514-8914-41b1-87c7-100a6e0aa438" }, "RequestBody": null, "StatusCode": 200, @@ -17,7 +17,7 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:18 GMT", + "Date": "Mon, 20 Mar 2023 06:45:52 GMT", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -26,10 +26,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "c62a9e8b-5f47-42e5-b653-3d59db6ed295", - "x-ms-ratelimit-remaining-subscription-reads": "11985", - "x-ms-request-id": "47f55403-d37a-4628-aee4-160da8a74e51", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031618Z:c62a9e8b-5f47-42e5-b653-3d59db6ed295", + "x-ms-correlation-request-id": "eea0516a-cb3e-4397-b12f-2598de721496", + "x-ms-ratelimit-remaining-subscription-reads": "11997", + "x-ms-request-id": "2d32afe0-a1a5-4bb1-ba85-092f10be5f9f", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064553Z:eea0516a-cb3e-4397-b12f-2598de721496", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -41,7 +41,7 @@ "kind": "app", "location": "East US", "properties": { - "serverFarmId": 23123, + "serverFarmId": 8742, "name": "myappserviceplanxxx", "workerSize": "Default", "workerSizeId": 0, @@ -76,7 +76,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "mdmId": "waws-prod-blu-357_23123", + "mdmId": "waws-prod-blu-395_8742", "targetWorkerCount": 0, "targetWorkerSizeId": 0, "provisioningState": "Succeeded", diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_create_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_create_test.json index f59c479b74c0..01f8ec3bccdf 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_create_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_create_test.json @@ -1,7 +1,7 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-09-01", "RequestMethod": "PUT", "RequestHeaders": { "Accept": "application/json", @@ -10,8 +10,8 @@ "Connection": "keep-alive", "Content-Length": "426", "Content-Type": "application/json", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "fb55e7cf-38f7-432d-93fb-47f9a5a942bb" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "9e2def88-95b6-4c5b-9f03-f88063b3e1a0" }, "RequestBody": { "location": "eastus", @@ -40,8 +40,8 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:15 GMT", - "ETag": "\u00221D8F969BEF7F5F5\u0022", + "Date": "Mon, 20 Mar 2023 06:45:48 GMT", + "ETag": "\u00221D95AF791507C95\u0022", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -50,10 +50,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "c976d244-ee49-4d19-829e-a3dbb4320531", - "x-ms-ratelimit-remaining-subscription-resource-requests": "495", - "x-ms-request-id": "718ad9b6-edb8-4ebc-9916-24a43386d46c", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031615Z:c976d244-ee49-4d19-829e-a3dbb4320531", + "x-ms-correlation-request-id": "920adae1-611b-4559-9622-61033c46663a", + "x-ms-ratelimit-remaining-subscription-resource-requests": "499", + "x-ms-request-id": "8298a276-e3cb-48c4-ba4e-7d6911eb8677", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064549Z:920adae1-611b-4559-9622-61033c46663a", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -69,7 +69,7 @@ "mysitexxxx.azurewebsites.net" ], "webSpace": "myjstest-EastUSwebspace", - "selfLink": "https://waws-prod-blu-357.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", + "selfLink": "https://waws-prod-blu-395.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", "repositorySiteName": "mysitexxxx", "owner": null, "usageState": "Normal", @@ -128,7 +128,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "lastModifiedTimeUtc": "2022-11-16T03:15:57.16", + "lastModifiedTimeUtc": "2023-03-20T06:45:31.7433333", "storageRecoveryDefaultState": "Running", "contentAvailabilityState": "Normal", "runtimeAvailabilityState": "Normal", @@ -259,19 +259,19 @@ "domainVerificationIdentifiers": null, "customDomainVerificationId": "55F2E4435A6748F0C3A4666505B3672446A9A9AEFDDC20F98EFEE4B5DCC7807E", "kind": "app", - "inboundIpAddress": "20.119.0.21", - "possibleInboundIpAddresses": "20.119.0.21", + "inboundIpAddress": "20.119.8.36", + "possibleInboundIpAddresses": "20.119.8.36", "ftpUsername": "mysitexxxx\\$mysitexxxx", - "ftpsHostName": "ftps://waws-prod-blu-357.ftp.azurewebsites.windows.net/site/wwwroot", - "outboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.119.0.21", - "possibleOutboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.237.78.68,20.237.78.102,20.237.78.127,20.121.183.254,20.237.78.248,20.237.79.6,20.237.79.37,20.121.180.135,20.237.79.40,20.237.79.69,20.237.79.144,20.246.200.103,20.237.73.35,20.246.200.115,20.246.200.123,20.246.200.189,20.246.201.37,20.81.102.206,20.81.102.207,20.81.103.133,20.121.177.162,20.121.177.163,20.237.72.228,20.237.73.69,20.119.0.21", + "ftpsHostName": "ftps://waws-prod-blu-395.ftp.azurewebsites.windows.net/site/wwwroot", + "outboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.119.8.36", + "possibleOutboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.246.139.207,20.246.139.220,20.246.139.252,20.246.140.67,20.246.140.77,20.246.140.87,20.246.140.96,20.246.140.108,20.246.140.136,20.246.140.168,20.246.140.182,20.246.140.221,20.246.141.59,20.246.141.88,20.246.141.129,20.246.141.239,20.237.26.27,20.237.26.204,20.237.26.231,20.237.28.32,20.237.28.73,20.237.28.146,20.237.29.75,20.237.29.155,20.119.8.36", "containerSize": 0, "dailyMemoryTimeQuota": 0, "suspendedTill": null, "siteDisabledReason": 0, "functionExecutionUnitsCache": null, "maxNumberOfWorkers": null, - "homeStamp": "waws-prod-blu-357", + "homeStamp": "waws-prod-blu-395", "cloningInfo": null, "hostingEnvironmentId": null, "tags": null, diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_delete_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_delete_test.json index a714b31eef5b..e6eaa69f5655 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_delete_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_delete_test.json @@ -1,47 +1,47 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-09-01", "RequestMethod": "DELETE", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "38ab9473-c929-446f-be69-3b1a6bcca85d" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "02642925-6be0-459c-9b91-34e84e486c21" }, "RequestBody": null, "StatusCode": 200, "ResponseHeaders": { "Cache-Control": "no-cache", "Content-Length": "0", - "Date": "Wed, 16 Nov 2022 03:16:39 GMT", - "ETag": "\u00221D8F969CE9B5BC0\u0022", + "Date": "Mon, 20 Mar 2023 06:46:16 GMT", + "ETag": "\u00221D95AF7A05E5920\u0022", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", "Strict-Transport-Security": "max-age=31536000; includeSubDomains", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "43fb721f-bace-41ce-af33-5045c70127e2", - "x-ms-ratelimit-remaining-subscription-deletes": "14995", - "x-ms-request-id": "359bb360-7bfe-4ff5-b7d2-de6cf011c005", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031640Z:43fb721f-bace-41ce-af33-5045c70127e2", + "x-ms-correlation-request-id": "f9e3a9da-d9d0-4c27-a1bb-2f8ef2155d1c", + "x-ms-ratelimit-remaining-subscription-deletes": "14999", + "x-ms-request-id": "9617edeb-056c-4ca1-8ef1-434bdf79331a", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064616Z:f9e3a9da-d9d0-4c27-a1bb-2f8ef2155d1c", "X-Powered-By": "ASP.NET" }, "ResponseBody": null }, { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "756f219d-61a7-49c6-8419-4e8ee2a15624" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "9ce280e9-6509-4cf2-a856-0a9ea701ee05" }, "RequestBody": null, "StatusCode": 200, @@ -50,16 +50,16 @@ "Content-Encoding": "gzip", "Content-Length": "12", "Content-Type": "application/json; charset=utf-8", - "Date": "Wed, 16 Nov 2022 03:16:39 GMT", + "Date": "Mon, 20 Mar 2023 06:46:16 GMT", "Expires": "-1", "Pragma": "no-cache", "Strict-Transport-Security": "max-age=31536000; includeSubDomains", "Vary": "Accept-Encoding", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "b2912656-9613-4291-8621-a2470ecc5924", - "x-ms-ratelimit-remaining-subscription-reads": "11983", - "x-ms-request-id": "b2912656-9613-4291-8621-a2470ecc5924", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031640Z:b2912656-9613-4291-8621-a2470ecc5924" + "x-ms-correlation-request-id": "7f131704-ea82-450c-951f-c65715326f67", + "x-ms-ratelimit-remaining-subscription-reads": "11995", + "x-ms-request-id": "7f131704-ea82-450c-951f-c65715326f67", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064617Z:7f131704-ea82-450c-951f-c65715326f67" }, "ResponseBody": { "value": [] diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_get_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_get_test.json index 88aff3eb8a8d..c81c4374fb89 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_get_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_get_test.json @@ -1,15 +1,15 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "ea64d38e-51ed-416f-a62e-0b05d2fd711b" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "fa58655a-e70c-44cb-a4e3-677ffd845cb8" }, "RequestBody": null, "StatusCode": 200, @@ -17,8 +17,8 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:17 GMT", - "ETag": "\u00221D8F969BEF7F5F5\u0022", + "Date": "Mon, 20 Mar 2023 06:45:51 GMT", + "ETag": "\u00221D95AF791507C95\u0022", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -27,10 +27,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "f0635a9b-81fb-456b-b005-bd20fcc167cc", - "x-ms-ratelimit-remaining-subscription-reads": "11986", - "x-ms-request-id": "ad4d5c8d-08dc-4f8f-8016-1ea7259226a1", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031617Z:f0635a9b-81fb-456b-b005-bd20fcc167cc", + "x-ms-correlation-request-id": "1b1e0ff0-26ed-4c9a-b792-2a1963c0ab0f", + "x-ms-ratelimit-remaining-subscription-reads": "11998", + "x-ms-request-id": "195e4185-2e47-488b-be22-e82960800878", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064551Z:1b1e0ff0-26ed-4c9a-b792-2a1963c0ab0f", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -46,7 +46,7 @@ "mysitexxxx.azurewebsites.net" ], "webSpace": "myjstest-EastUSwebspace", - "selfLink": "https://waws-prod-blu-357.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", + "selfLink": "https://waws-prod-blu-395.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", "repositorySiteName": "mysitexxxx", "owner": null, "usageState": "Normal", @@ -105,7 +105,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "lastModifiedTimeUtc": "2022-11-16T03:15:57.8233333", + "lastModifiedTimeUtc": "2023-03-20T06:45:32.5533333", "storageRecoveryDefaultState": "Running", "contentAvailabilityState": "Normal", "runtimeAvailabilityState": "Normal", @@ -220,19 +220,19 @@ "domainVerificationIdentifiers": null, "customDomainVerificationId": "55F2E4435A6748F0C3A4666505B3672446A9A9AEFDDC20F98EFEE4B5DCC7807E", "kind": "app", - "inboundIpAddress": "20.119.0.21", - "possibleInboundIpAddresses": "20.119.0.21", + "inboundIpAddress": "20.119.8.36", + "possibleInboundIpAddresses": "20.119.8.36", "ftpUsername": "mysitexxxx\\$mysitexxxx", - "ftpsHostName": "ftps://waws-prod-blu-357.ftp.azurewebsites.windows.net/site/wwwroot", - "outboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.119.0.21", - "possibleOutboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.237.78.68,20.237.78.102,20.237.78.127,20.121.183.254,20.237.78.248,20.237.79.6,20.237.79.37,20.121.180.135,20.237.79.40,20.237.79.69,20.237.79.144,20.246.200.103,20.237.73.35,20.246.200.115,20.246.200.123,20.246.200.189,20.246.201.37,20.81.102.206,20.81.102.207,20.81.103.133,20.121.177.162,20.121.177.163,20.237.72.228,20.237.73.69,20.119.0.21", + "ftpsHostName": "ftps://waws-prod-blu-395.ftp.azurewebsites.windows.net/site/wwwroot", + "outboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.119.8.36", + "possibleOutboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.246.139.207,20.246.139.220,20.246.139.252,20.246.140.67,20.246.140.77,20.246.140.87,20.246.140.96,20.246.140.108,20.246.140.136,20.246.140.168,20.246.140.182,20.246.140.221,20.246.141.59,20.246.141.88,20.246.141.129,20.246.141.239,20.237.26.27,20.237.26.204,20.237.26.231,20.237.28.32,20.237.28.73,20.237.28.146,20.237.29.75,20.237.29.155,20.119.8.36", "containerSize": 0, "dailyMemoryTimeQuota": 0, "suspendedTill": null, "siteDisabledReason": 0, "functionExecutionUnitsCache": null, "maxNumberOfWorkers": null, - "homeStamp": "waws-prod-blu-357", + "homeStamp": "waws-prod-blu-395", "cloningInfo": null, "hostingEnvironmentId": null, "tags": null, diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_list_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_list_test.json index 02d51eb7aea9..3a37a388aa8b 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_list_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_list_test.json @@ -1,15 +1,15 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites?api-version=2022-09-01", "RequestMethod": "GET", "RequestHeaders": { "Accept": "application/json", "Accept-Encoding": "gzip,deflate", "Authorization": "Sanitized", "Connection": "keep-alive", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "f4e61728-d5a3-4789-b659-87f22b79f00f" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "f80839f0-c862-4ed6-8461-a42b1978e384" }, "RequestBody": null, "StatusCode": 200, @@ -17,7 +17,7 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:19 GMT", + "Date": "Mon, 20 Mar 2023 06:45:53 GMT", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -26,10 +26,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "7a098475-4fa5-4edd-9638-6935ee66c739", - "x-ms-ratelimit-remaining-subscription-reads": "11984", - "x-ms-request-id": "7932b6bc-5f84-4062-b014-00ee7dfa1fbb", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031619Z:7a098475-4fa5-4edd-9638-6935ee66c739", + "x-ms-correlation-request-id": "d710fe2f-a2d8-4130-b67e-d8e4f3468ace", + "x-ms-ratelimit-remaining-subscription-reads": "11996", + "x-ms-request-id": "925bfee2-6efa-4e8d-8f80-fc099dbcbd17", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064554Z:d710fe2f-a2d8-4130-b67e-d8e4f3468ace", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -47,7 +47,7 @@ "mysitexxxx.azurewebsites.net" ], "webSpace": "myjstest-EastUSwebspace", - "selfLink": "https://waws-prod-blu-357.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", + "selfLink": "https://waws-prod-blu-395.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", "repositorySiteName": "mysitexxxx", "owner": null, "usageState": "Normal", @@ -106,7 +106,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "lastModifiedTimeUtc": "2022-11-16T03:15:57.8233333", + "lastModifiedTimeUtc": "2023-03-20T06:45:32.5533333", "storageRecoveryDefaultState": "Running", "contentAvailabilityState": "Normal", "runtimeAvailabilityState": "Normal", @@ -221,19 +221,19 @@ "domainVerificationIdentifiers": null, "customDomainVerificationId": "55F2E4435A6748F0C3A4666505B3672446A9A9AEFDDC20F98EFEE4B5DCC7807E", "kind": "app", - "inboundIpAddress": "20.119.0.21", - "possibleInboundIpAddresses": "20.119.0.21", + "inboundIpAddress": "20.119.8.36", + "possibleInboundIpAddresses": "20.119.8.36", "ftpUsername": "mysitexxxx\\$mysitexxxx", - "ftpsHostName": "ftps://waws-prod-blu-357.ftp.azurewebsites.windows.net/site/wwwroot", - "outboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.119.0.21", - "possibleOutboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.237.78.68,20.237.78.102,20.237.78.127,20.121.183.254,20.237.78.248,20.237.79.6,20.237.79.37,20.121.180.135,20.237.79.40,20.237.79.69,20.237.79.144,20.246.200.103,20.237.73.35,20.246.200.115,20.246.200.123,20.246.200.189,20.246.201.37,20.81.102.206,20.81.102.207,20.81.103.133,20.121.177.162,20.121.177.163,20.237.72.228,20.237.73.69,20.119.0.21", + "ftpsHostName": "ftps://waws-prod-blu-395.ftp.azurewebsites.windows.net/site/wwwroot", + "outboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.119.8.36", + "possibleOutboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.246.139.207,20.246.139.220,20.246.139.252,20.246.140.67,20.246.140.77,20.246.140.87,20.246.140.96,20.246.140.108,20.246.140.136,20.246.140.168,20.246.140.182,20.246.140.221,20.246.141.59,20.246.141.88,20.246.141.129,20.246.141.239,20.237.26.27,20.237.26.204,20.237.26.231,20.237.28.32,20.237.28.73,20.237.28.146,20.237.29.75,20.237.29.155,20.119.8.36", "containerSize": 0, "dailyMemoryTimeQuota": 0, "suspendedTill": null, "siteDisabledReason": 0, "functionExecutionUnitsCache": null, "maxNumberOfWorkers": null, - "homeStamp": "waws-prod-blu-357", + "homeStamp": "waws-prod-blu-395", "cloningInfo": null, "hostingEnvironmentId": null, "tags": null, diff --git a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_update_test.json b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_update_test.json index f1032e33a822..9e3440c31535 100644 --- a/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_update_test.json +++ b/sdk/appservice/arm-appservice/recordings/node/web_test/recording_webapps_update_test.json @@ -1,7 +1,7 @@ { "Entries": [ { - "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-03-01", + "RequestUri": "https://management.azure.com/subscriptions/azure_subscription_id/resourceGroups/myjstest/providers/Microsoft.Web/sites/mysitexxxx?api-version=2022-09-01", "RequestMethod": "PATCH", "RequestHeaders": { "Accept": "application/json", @@ -10,8 +10,8 @@ "Connection": "keep-alive", "Content-Length": "316", "Content-Type": "application/json", - "User-Agent": "azsdk-js-arm-appservice/13.0.3 core-rest-pipeline/1.10.1 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", - "x-ms-client-request-id": "beb6de7a-4d13-4e62-a723-589133f46c0f" + "User-Agent": "azsdk-js-arm-appservice/14.0.0 core-rest-pipeline/1.10.3 Node/v16.17.0 OS/(x64-Windows_NT-10.0.22621)", + "x-ms-client-request-id": "482186eb-e74a-4125-bd95-0fd3e0a529ff" }, "RequestBody": { "properties": { @@ -32,8 +32,8 @@ "Cache-Control": "no-cache", "Content-Encoding": "gzip", "Content-Type": "application/json", - "Date": "Wed, 16 Nov 2022 03:16:26 GMT", - "ETag": "\u00221D8F969BEF7F5F5\u0022", + "Date": "Mon, 20 Mar 2023 06:46:03 GMT", + "ETag": "\u00221D95AF791507C95\u0022", "Expires": "-1", "Pragma": "no-cache", "Server": "Microsoft-IIS/10.0", @@ -42,10 +42,10 @@ "Vary": "Accept-Encoding", "X-AspNet-Version": "4.0.30319", "X-Content-Type-Options": "nosniff", - "x-ms-correlation-request-id": "6b62b5df-a52d-4db2-887a-3d88b873f911", - "x-ms-ratelimit-remaining-subscription-resource-requests": "494", - "x-ms-request-id": "0e847453-8edd-4581-9173-da6ce65d09e4", - "x-ms-routing-request-id": "SOUTHEASTASIA:20221116T031626Z:6b62b5df-a52d-4db2-887a-3d88b873f911", + "x-ms-correlation-request-id": "5776b923-7bdd-4a2c-90b4-87e45191b3ed", + "x-ms-ratelimit-remaining-subscription-resource-requests": "498", + "x-ms-request-id": "21bfa258-4c76-4bf1-95e7-53529ae0b060", + "x-ms-routing-request-id": "SOUTHEASTASIA:20230320T064603Z:5776b923-7bdd-4a2c-90b4-87e45191b3ed", "X-Powered-By": "ASP.NET" }, "ResponseBody": { @@ -61,7 +61,7 @@ "mysitexxxx.azurewebsites.net" ], "webSpace": "myjstest-EastUSwebspace", - "selfLink": "https://waws-prod-blu-357.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", + "selfLink": "https://waws-prod-blu-395.api.azurewebsites.windows.net:454/subscriptions/azure_subscription_id/webspaces/myjstest-EastUSwebspace/sites/mysitexxxx", "repositorySiteName": "mysitexxxx", "owner": null, "usageState": "Normal", @@ -120,7 +120,7 @@ "reserved": false, "isXenon": false, "hyperV": false, - "lastModifiedTimeUtc": "2022-11-16T03:16:24.06", + "lastModifiedTimeUtc": "2023-03-20T06:45:57.81", "storageRecoveryDefaultState": "Running", "contentAvailabilityState": "Normal", "runtimeAvailabilityState": "Normal", @@ -251,19 +251,19 @@ "domainVerificationIdentifiers": null, "customDomainVerificationId": "55F2E4435A6748F0C3A4666505B3672446A9A9AEFDDC20F98EFEE4B5DCC7807E", "kind": "app", - "inboundIpAddress": "20.119.0.21", - "possibleInboundIpAddresses": "20.119.0.21", + "inboundIpAddress": "20.119.8.36", + "possibleInboundIpAddresses": "20.119.8.36", "ftpUsername": "mysitexxxx\\$mysitexxxx", - "ftpsHostName": "ftps://waws-prod-blu-357.ftp.azurewebsites.windows.net/site/wwwroot", - "outboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.119.0.21", - "possibleOutboundIpAddresses": "20.121.181.240,20.237.73.136,20.237.77.229,20.237.78.22,20.85.132.26,20.237.78.25,20.237.78.68,20.237.78.102,20.237.78.127,20.121.183.254,20.237.78.248,20.237.79.6,20.237.79.37,20.121.180.135,20.237.79.40,20.237.79.69,20.237.79.144,20.246.200.103,20.237.73.35,20.246.200.115,20.246.200.123,20.246.200.189,20.246.201.37,20.81.102.206,20.81.102.207,20.81.103.133,20.121.177.162,20.121.177.163,20.237.72.228,20.237.73.69,20.119.0.21", + "ftpsHostName": "ftps://waws-prod-blu-395.ftp.azurewebsites.windows.net/site/wwwroot", + "outboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.119.8.36", + "possibleOutboundIpAddresses": "20.237.31.25,20.246.137.184,20.246.138.49,20.246.138.113,20.246.138.205,20.246.139.198,20.246.139.207,20.246.139.220,20.246.139.252,20.246.140.67,20.246.140.77,20.246.140.87,20.246.140.96,20.246.140.108,20.246.140.136,20.246.140.168,20.246.140.182,20.246.140.221,20.246.141.59,20.246.141.88,20.246.141.129,20.246.141.239,20.237.26.27,20.237.26.204,20.237.26.231,20.237.28.32,20.237.28.73,20.237.28.146,20.237.29.75,20.237.29.155,20.119.8.36", "containerSize": 0, "dailyMemoryTimeQuota": 0, "suspendedTill": null, "siteDisabledReason": 0, "functionExecutionUnitsCache": null, "maxNumberOfWorkers": null, - "homeStamp": "waws-prod-blu-357", + "homeStamp": "waws-prod-blu-395", "cloningInfo": null, "hostingEnvironmentId": null, "tags": null, diff --git a/sdk/appservice/arm-appservice/review/arm-appservice.api.md b/sdk/appservice/arm-appservice/review/arm-appservice.api.md index fc51b956dfe4..80ceea40a3fb 100644 --- a/sdk/appservice/arm-appservice/review/arm-appservice.api.md +++ b/sdk/appservice/arm-appservice/review/arm-appservice.api.md @@ -8,9 +8,9 @@ import * as coreAuth from '@azure/core-auth'; import * as coreClient from '@azure/core-client'; +import { OperationState } from '@azure/core-lro'; import { PagedAsyncIterableIterator } from '@azure/core-paging'; -import { PollerLike } from '@azure/core-lro'; -import { PollOperationState } from '@azure/core-lro'; +import { SimplePollerLike } from '@azure/core-lro'; // @public export interface AbnormalTimePeriod { @@ -242,9 +242,9 @@ export interface AppServiceCertificateOrderPatchResource extends ProxyOnlyResour // @public export interface AppServiceCertificateOrders { - beginCreateOrUpdate(resourceGroupName: string, certificateOrderName: string, certificateDistinguishedName: AppServiceCertificateOrder, options?: AppServiceCertificateOrdersCreateOrUpdateOptionalParams): Promise, AppServiceCertificateOrdersCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, certificateOrderName: string, certificateDistinguishedName: AppServiceCertificateOrder, options?: AppServiceCertificateOrdersCreateOrUpdateOptionalParams): Promise, AppServiceCertificateOrdersCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, certificateOrderName: string, certificateDistinguishedName: AppServiceCertificateOrder, options?: AppServiceCertificateOrdersCreateOrUpdateOptionalParams): Promise; - beginCreateOrUpdateCertificate(resourceGroupName: string, certificateOrderName: string, name: string, keyVaultCertificate: AppServiceCertificateResource, options?: AppServiceCertificateOrdersCreateOrUpdateCertificateOptionalParams): Promise, AppServiceCertificateOrdersCreateOrUpdateCertificateResponse>>; + beginCreateOrUpdateCertificate(resourceGroupName: string, certificateOrderName: string, name: string, keyVaultCertificate: AppServiceCertificateResource, options?: AppServiceCertificateOrdersCreateOrUpdateCertificateOptionalParams): Promise, AppServiceCertificateOrdersCreateOrUpdateCertificateResponse>>; beginCreateOrUpdateCertificateAndWait(resourceGroupName: string, certificateOrderName: string, name: string, keyVaultCertificate: AppServiceCertificateResource, options?: AppServiceCertificateOrdersCreateOrUpdateCertificateOptionalParams): Promise; delete(resourceGroupName: string, certificateOrderName: string, options?: AppServiceCertificateOrdersDeleteOptionalParams): Promise; deleteCertificate(resourceGroupName: string, certificateOrderName: string, name: string, options?: AppServiceCertificateOrdersDeleteCertificateOptionalParams): Promise; @@ -501,22 +501,22 @@ export interface AppServiceEnvironmentResource extends Resource { // @public export interface AppServiceEnvironments { - beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse>>; + beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse>>; beginApproveOrRejectPrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise; - beginCreateOrUpdate(resourceGroupName: string, name: string, hostingEnvironmentEnvelope: AppServiceEnvironmentResource, options?: AppServiceEnvironmentsCreateOrUpdateOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, name: string, hostingEnvironmentEnvelope: AppServiceEnvironmentResource, options?: AppServiceEnvironmentsCreateOrUpdateOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, hostingEnvironmentEnvelope: AppServiceEnvironmentResource, options?: AppServiceEnvironmentsCreateOrUpdateOptionalParams): Promise; - beginCreateOrUpdateMultiRolePool(resourceGroupName: string, name: string, multiRolePoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse>>; + beginCreateOrUpdateMultiRolePool(resourceGroupName: string, name: string, multiRolePoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse>>; beginCreateOrUpdateMultiRolePoolAndWait(resourceGroupName: string, name: string, multiRolePoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams): Promise; - beginCreateOrUpdateWorkerPool(resourceGroupName: string, name: string, workerPoolName: string, workerPoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateWorkerPoolOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse>>; + beginCreateOrUpdateWorkerPool(resourceGroupName: string, name: string, workerPoolName: string, workerPoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateWorkerPoolOptionalParams): Promise, AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse>>; beginCreateOrUpdateWorkerPoolAndWait(resourceGroupName: string, name: string, workerPoolName: string, workerPoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateWorkerPoolOptionalParams): Promise; - beginDelete(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteOptionalParams): Promise, void>>; + beginDelete(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteOptionalParams): Promise, void>>; beginDeleteAndWait(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteOptionalParams): Promise; - beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: AppServiceEnvironmentsDeletePrivateEndpointConnectionOptionalParams): Promise, AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse>>; + beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: AppServiceEnvironmentsDeletePrivateEndpointConnectionOptionalParams): Promise, AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse>>; beginDeletePrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: AppServiceEnvironmentsDeletePrivateEndpointConnectionOptionalParams): Promise; beginListChangeVnetAndWait(resourceGroupName: string, name: string, vnetInfo: VirtualNetworkProfile, options?: AppServiceEnvironmentsChangeVnetOptionalParams): PagedAsyncIterableIterator; beginListResumeAndWait(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsResumeOptionalParams): PagedAsyncIterableIterator; beginListSuspendAndWait(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsSuspendOptionalParams): PagedAsyncIterableIterator; - beginUpgrade(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsUpgradeOptionalParams): Promise, void>>; + beginUpgrade(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsUpgradeOptionalParams): Promise, void>>; beginUpgradeAndWait(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsUpgradeOptionalParams): Promise; deleteAseCustomDnsSuffixConfiguration(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationOptionalParams): Promise; get(resourceGroupName: string, name: string, options?: AppServiceEnvironmentsGetOptionalParams): Promise; @@ -583,6 +583,11 @@ export interface AppServiceEnvironmentsChangeVnetOptionalParams extends coreClie // @public export type AppServiceEnvironmentsChangeVnetResponse = WebAppCollection; +// @public +export interface AppServiceEnvironmentsCreateOrUpdateHeaders { + location?: string; +} + // @public export interface AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -880,7 +885,6 @@ export type AppServiceEnvironmentsListResponse = AppServiceEnvironmentCollection // @public export interface AppServiceEnvironmentsListUsagesNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -896,7 +900,6 @@ export type AppServiceEnvironmentsListUsagesResponse = CsmUsageQuotaCollection; // @public export interface AppServiceEnvironmentsListWebAppsNextOptionalParams extends coreClient.OperationOptions { - propertiesToInclude?: string; } // @public @@ -1143,7 +1146,7 @@ export type AppServicePlanRestrictions = "None" | "Free" | "Shared" | "Basic" | // @public export interface AppServicePlans { - beginCreateOrUpdate(resourceGroupName: string, name: string, appServicePlan: AppServicePlan, options?: AppServicePlansCreateOrUpdateOptionalParams): Promise, AppServicePlansCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, name: string, appServicePlan: AppServicePlan, options?: AppServicePlansCreateOrUpdateOptionalParams): Promise, AppServicePlansCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, appServicePlan: AppServicePlan, options?: AppServicePlansCreateOrUpdateOptionalParams): Promise; createOrUpdateVnetRoute(resourceGroupName: string, name: string, vnetName: string, routeName: string, route: VnetRoute, options?: AppServicePlansCreateOrUpdateVnetRouteOptionalParams): Promise; delete(resourceGroupName: string, name: string, options?: AppServicePlansDeleteOptionalParams): Promise; @@ -1294,7 +1297,6 @@ export type AppServicePlansListHybridConnectionsResponse = HybridConnectionColle // @public export interface AppServicePlansListNextOptionalParams extends coreClient.OperationOptions { - detailed?: boolean; } // @public @@ -1317,7 +1319,6 @@ export type AppServicePlansListRoutesForVnetResponse = VnetRoute[]; // @public export interface AppServicePlansListUsagesNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -1354,9 +1355,6 @@ export type AppServicePlansListWebAppsByHybridConnectionResponse = ResourceColle // @public export interface AppServicePlansListWebAppsNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - skipToken?: string; - top?: string; } // @public @@ -1629,6 +1627,9 @@ export interface BackupSchedule { startTime?: Date; } +// @public +export type BasicAuthName = string; + // @public export interface BillingMeter extends ProxyOnlyResource { billingLocation?: string; @@ -1859,7 +1860,6 @@ export type CertificatesListByResourceGroupResponse = CertificateCollection; // @public export interface CertificatesListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -2001,9 +2001,9 @@ export type ContainerAppProvisioningState = string; // @public export interface ContainerApps { - beginCreateOrUpdate(resourceGroupName: string, name: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise, ContainerAppsCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, name: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise, ContainerAppsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams): Promise, void>>; + beginDelete(resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams): Promise, void>>; beginDeleteAndWait(resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams): Promise; get(resourceGroupName: string, name: string, options?: ContainerAppsGetOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: ContainerAppsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; @@ -2465,6 +2465,38 @@ export interface DatabaseBackupSetting { name?: string; } +// @public +export interface DatabaseConnection extends ProxyOnlyResource { + readonly configurationFiles?: StaticSiteDatabaseConnectionConfigurationFileOverview[]; + connectionIdentity?: string; + connectionString?: string; + region?: string; + resourceId?: string; +} + +// @public +export interface DatabaseConnectionCollection { + readonly nextLink?: string; + value: DatabaseConnection[]; +} + +// @public +export interface DatabaseConnectionOverview { + readonly configurationFiles?: StaticSiteDatabaseConnectionConfigurationFileOverview[]; + readonly connectionIdentity?: string; + readonly name?: string; + readonly region?: string; + readonly resourceId?: string; +} + +// @public +export interface DatabaseConnectionPatchRequest { + connectionIdentity?: string; + connectionString?: string; + region?: string; + resourceId?: string; +} + // @public export type DatabaseType = string; @@ -2501,6 +2533,9 @@ export type DayOfWeek = "Sunday" | "Monday" | "Tuesday" | "Wednesday" | "Thursda // @public export type DaysOfWeek = "Sunday" | "Monday" | "Tuesday" | "Wednesday" | "Thursday" | "Friday" | "Saturday"; +// @public +export type DefaultAction = string; + // @public export interface DefaultAuthorizationPolicy { allowedApplications?: string[]; @@ -3152,7 +3187,7 @@ export type DomainRegistrationProviderListOperationsResponse = CsmOperationColle // @public export interface Domains { - beginCreateOrUpdate(resourceGroupName: string, domainName: string, domain: Domain, options?: DomainsCreateOrUpdateOptionalParams): Promise, DomainsCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, domainName: string, domain: Domain, options?: DomainsCreateOrUpdateOptionalParams): Promise, DomainsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, domainName: string, domain: Domain, options?: DomainsCreateOrUpdateOptionalParams): Promise; checkAvailability(identifier: NameIdentifier, options?: DomainsCheckAvailabilityOptionalParams): Promise; createOrUpdateOwnershipIdentifier(resourceGroupName: string, domainName: string, name: string, domainOwnershipIdentifier: DomainOwnershipIdentifier, options?: DomainsCreateOrUpdateOwnershipIdentifierOptionalParams): Promise; @@ -3333,24 +3368,6 @@ export interface EndpointDetail { // @public export type EnterpriseGradeCdnStatus = string; -// @public -export type Enum14 = string; - -// @public -export type Enum15 = string; - -// @public -export type Enum16 = string; - -// @public -export type Enum17 = string; - -// @public -export type Enum18 = string; - -// @public -export type Enum19 = string; - // @public export interface EnvironmentVar { name?: string; @@ -3978,6 +3995,11 @@ export enum KnownActiveRevisionsMode { Single = "single" } +// @public +export enum KnownBasicAuthName { + Default = "default" +} + // @public export enum KnownBuildStatus { Deleting = "Deleting", @@ -4028,6 +4050,12 @@ export enum KnownDatabaseType { SqlAzure = "SqlAzure" } +// @public +export enum KnownDefaultAction { + Allow = "Allow", + Deny = "Deny" +} + // @public export enum KnownDeploymentBuildStatus { BuildAborted = "BuildAborted", @@ -4053,52 +4081,6 @@ export enum KnownEnterpriseGradeCdnStatus { Enabling = "Enabling" } -// @public -export enum KnownEnum14 { - All = "All", - Linux = "Linux", - LinuxFunctions = "LinuxFunctions", - Windows = "Windows", - WindowsFunctions = "WindowsFunctions" -} - -// @public -export enum KnownEnum15 { - All = "All", - Linux = "Linux", - Windows = "Windows" -} - -// @public -export enum KnownEnum16 { - All = "All", - Linux = "Linux", - Windows = "Windows" -} - -// @public -export enum KnownEnum17 { - All = "All", - Linux = "Linux", - Windows = "Windows" -} - -// @public -export enum KnownEnum18 { - All = "All", - Linux = "Linux", - Windows = "Windows" -} - -// @public -export enum KnownEnum19 { - All = "All", - Linux = "Linux", - LinuxFunctions = "LinuxFunctions", - Windows = "Windows", - WindowsFunctions = "WindowsFunctions" -} - // @public export enum KnownFtpsState { AllAllowed = "AllAllowed", @@ -4165,6 +4147,22 @@ export enum KnownParameterType { String = "String" } +// @public +export enum KnownProviderOsTypeSelected { + All = "All", + Linux = "Linux", + LinuxFunctions = "LinuxFunctions", + Windows = "Windows", + WindowsFunctions = "WindowsFunctions" +} + +// @public +export enum KnownProviderStackOsType { + All = "All", + Linux = "Linux", + Windows = "Windows" +} + // @public export enum KnownPublishingProfileFormat { FileZilla3 = "FileZilla3", @@ -4326,16 +4324,6 @@ export enum KnownWorkflowSkuName { Standard = "Standard" } -// @public -export enum KnownWorkflowState { - Completed = "Completed", - Deleted = "Deleted", - Disabled = "Disabled", - Enabled = "Enabled", - NotSpecified = "NotSpecified", - Suspended = "Suspended" -} - // @public export enum KnownWorkflowStatus { Aborted = "Aborted", @@ -4423,9 +4411,9 @@ export type KubeEnvironmentProvisioningState = "Succeeded" | "Failed" | "Cancele // @public export interface KubeEnvironments { - beginCreateOrUpdate(resourceGroupName: string, name: string, kubeEnvironmentEnvelope: KubeEnvironment, options?: KubeEnvironmentsCreateOrUpdateOptionalParams): Promise, KubeEnvironmentsCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, name: string, kubeEnvironmentEnvelope: KubeEnvironment, options?: KubeEnvironmentsCreateOrUpdateOptionalParams): Promise, KubeEnvironmentsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, kubeEnvironmentEnvelope: KubeEnvironment, options?: KubeEnvironmentsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, name: string, options?: KubeEnvironmentsDeleteOptionalParams): Promise, void>>; + beginDelete(resourceGroupName: string, name: string, options?: KubeEnvironmentsDeleteOptionalParams): Promise, void>>; beginDeleteAndWait(resourceGroupName: string, name: string, options?: KubeEnvironmentsDeleteOptionalParams): Promise; get(resourceGroupName: string, name: string, options?: KubeEnvironmentsGetOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: KubeEnvironmentsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; @@ -4512,8 +4500,6 @@ export interface LinuxJavaContainerSettings { // @public export interface ListBillingMetersNextOptionalParams extends coreClient.OperationOptions { - billingLocation?: string; - osType?: string; } // @public @@ -4530,7 +4516,6 @@ export type ListBillingMetersResponse = BillingMeterCollection; // @public export interface ListCustomHostNameSitesNextOptionalParams extends coreClient.OperationOptions { - hostname?: string; } // @public @@ -4546,10 +4531,6 @@ export type ListCustomHostNameSitesResponse = CustomHostnameSitesCollection; // @public export interface ListGeoRegionsNextOptionalParams extends coreClient.OperationOptions { - linuxDynamicWorkersEnabled?: boolean; - linuxWorkersEnabled?: boolean; - sku?: SkuName; - xenonWorkersEnabled?: boolean; } // @public @@ -5165,8 +5146,6 @@ export interface Provider { // @public export interface ProviderGetAvailableStacksNextOptionalParams extends coreClient.OperationOptions { - // (undocumented) - osTypeSelected?: Enum14; } // @public @@ -5174,8 +5153,6 @@ export type ProviderGetAvailableStacksNextResponse = ApplicationStackCollection; // @public export interface ProviderGetAvailableStacksOnPremNextOptionalParams extends coreClient.OperationOptions { - // (undocumented) - osTypeSelected?: Enum19; } // @public @@ -5184,7 +5161,7 @@ export type ProviderGetAvailableStacksOnPremNextResponse = ApplicationStackColle // @public export interface ProviderGetAvailableStacksOnPremOptionalParams extends coreClient.OperationOptions { // (undocumented) - osTypeSelected?: Enum19; + osTypeSelected?: ProviderOsTypeSelected; } // @public @@ -5193,7 +5170,7 @@ export type ProviderGetAvailableStacksOnPremResponse = ApplicationStackCollectio // @public export interface ProviderGetAvailableStacksOptionalParams extends coreClient.OperationOptions { // (undocumented) - osTypeSelected?: Enum14; + osTypeSelected?: ProviderOsTypeSelected; } // @public @@ -5201,7 +5178,6 @@ export type ProviderGetAvailableStacksResponse = ApplicationStackCollection; // @public export interface ProviderGetFunctionAppStacksForLocationNextOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum16; } // @public @@ -5209,7 +5185,7 @@ export type ProviderGetFunctionAppStacksForLocationNextResponse = FunctionAppSta // @public export interface ProviderGetFunctionAppStacksForLocationOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum16; + stackOsType?: ProviderStackOsType; } // @public @@ -5217,7 +5193,6 @@ export type ProviderGetFunctionAppStacksForLocationResponse = FunctionAppStackCo // @public export interface ProviderGetFunctionAppStacksNextOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum15; } // @public @@ -5225,7 +5200,7 @@ export type ProviderGetFunctionAppStacksNextResponse = FunctionAppStackCollectio // @public export interface ProviderGetFunctionAppStacksOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum15; + stackOsType?: ProviderStackOsType; } // @public @@ -5233,7 +5208,6 @@ export type ProviderGetFunctionAppStacksResponse = FunctionAppStackCollection; // @public export interface ProviderGetWebAppStacksForLocationNextOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum17; } // @public @@ -5241,7 +5215,7 @@ export type ProviderGetWebAppStacksForLocationNextResponse = WebAppStackCollecti // @public export interface ProviderGetWebAppStacksForLocationOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum17; + stackOsType?: ProviderStackOsType; } // @public @@ -5249,7 +5223,6 @@ export type ProviderGetWebAppStacksForLocationResponse = WebAppStackCollection; // @public export interface ProviderGetWebAppStacksNextOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum18; } // @public @@ -5257,7 +5230,7 @@ export type ProviderGetWebAppStacksNextResponse = WebAppStackCollection; // @public export interface ProviderGetWebAppStacksOptionalParams extends coreClient.OperationOptions { - stackOsType?: Enum18; + stackOsType?: ProviderStackOsType; } // @public @@ -5277,6 +5250,12 @@ export interface ProviderListOperationsOptionalParams extends coreClient.Operati // @public export type ProviderListOperationsResponse = CsmOperationCollection; +// @public +export type ProviderOsTypeSelected = string; + +// @public +export type ProviderStackOsType = string; + // @public export type ProvisioningState = "Succeeded" | "Failed" | "Canceled" | "InProgress" | "Deleting"; @@ -5461,8 +5440,6 @@ export type RecommendationsGetRuleDetailsByWebAppResponse = RecommendationRule; // @public export interface RecommendationsListHistoryForHostingEnvironmentNextOptionalParams extends coreClient.OperationOptions { - expiredOnly?: boolean; - filter?: string; } // @public @@ -5479,8 +5456,6 @@ export type RecommendationsListHistoryForHostingEnvironmentResponse = Recommenda // @public export interface RecommendationsListHistoryForWebAppNextOptionalParams extends coreClient.OperationOptions { - expiredOnly?: boolean; - filter?: string; } // @public @@ -5497,8 +5472,6 @@ export type RecommendationsListHistoryForWebAppResponse = RecommendationCollecti // @public export interface RecommendationsListNextOptionalParams extends coreClient.OperationOptions { - featured?: boolean; - filter?: string; } // @public @@ -5512,8 +5485,6 @@ export interface RecommendationsListOptionalParams extends coreClient.OperationO // @public export interface RecommendationsListRecommendedRulesForHostingEnvironmentNextOptionalParams extends coreClient.OperationOptions { - featured?: boolean; - filter?: string; } // @public @@ -5530,8 +5501,6 @@ export type RecommendationsListRecommendedRulesForHostingEnvironmentResponse = R // @public export interface RecommendationsListRecommendedRulesForWebAppNextOptionalParams extends coreClient.OperationOptions { - featured?: boolean; - filter?: string; } // @public @@ -6027,6 +5996,7 @@ export interface Site extends Resource { isXenon?: boolean; keyVaultReferenceIdentity?: string; readonly lastModifiedTimeUtc?: Date; + managedEnvironmentId?: string; readonly maxNumberOfWorkers?: number; readonly outboundIpAddresses?: string; readonly possibleOutboundIpAddresses?: string; @@ -6139,6 +6109,7 @@ export interface SiteConfig { defaultDocuments?: string[]; detailedErrorLoggingEnabled?: boolean; documentRoot?: string; + elasticWebAppScaleLimit?: number; experiments?: Experiments; ftpsState?: FtpsState; functionAppScaleLimit?: number; @@ -6148,6 +6119,7 @@ export interface SiteConfig { http20Enabled?: boolean; httpLoggingEnabled?: boolean; ipSecurityRestrictions?: IpSecurityRestriction[]; + ipSecurityRestrictionsDefaultAction?: DefaultAction; javaContainer?: string; javaContainerVersion?: string; javaVersion?: string; @@ -6160,6 +6132,7 @@ export interface SiteConfig { readonly machineKey?: SiteMachineKey; managedPipelineMode?: ManagedPipelineMode; managedServiceIdentityId?: number; + metadata?: NameValuePair[]; minimumElasticInstanceCount?: number; minTlsVersion?: SupportedTlsVersions; netFrameworkVersion?: string; @@ -6177,6 +6150,7 @@ export interface SiteConfig { requestTracingEnabled?: boolean; requestTracingExpirationTime?: Date; scmIpSecurityRestrictions?: IpSecurityRestriction[]; + scmIpSecurityRestrictionsDefaultAction?: DefaultAction; scmIpSecurityRestrictionsUseMain?: boolean; scmMinTlsVersion?: SupportedTlsVersions; scmType?: ScmType; @@ -6220,6 +6194,7 @@ export interface SiteConfigResource extends ProxyOnlyResource { defaultDocuments?: string[]; detailedErrorLoggingEnabled?: boolean; documentRoot?: string; + elasticWebAppScaleLimit?: number; experiments?: Experiments; ftpsState?: FtpsState; functionAppScaleLimit?: number; @@ -6229,6 +6204,7 @@ export interface SiteConfigResource extends ProxyOnlyResource { http20Enabled?: boolean; httpLoggingEnabled?: boolean; ipSecurityRestrictions?: IpSecurityRestriction[]; + ipSecurityRestrictionsDefaultAction?: DefaultAction; javaContainer?: string; javaContainerVersion?: string; javaVersion?: string; @@ -6241,6 +6217,7 @@ export interface SiteConfigResource extends ProxyOnlyResource { readonly machineKey?: SiteMachineKey; managedPipelineMode?: ManagedPipelineMode; managedServiceIdentityId?: number; + metadata?: NameValuePair[]; minimumElasticInstanceCount?: number; minTlsVersion?: SupportedTlsVersions; netFrameworkVersion?: string; @@ -6258,6 +6235,7 @@ export interface SiteConfigResource extends ProxyOnlyResource { requestTracingEnabled?: boolean; requestTracingExpirationTime?: Date; scmIpSecurityRestrictions?: IpSecurityRestriction[]; + scmIpSecurityRestrictionsDefaultAction?: DefaultAction; scmIpSecurityRestrictionsUseMain?: boolean; scmMinTlsVersion?: SupportedTlsVersions; scmType?: ScmType; @@ -6630,6 +6608,7 @@ export interface StaticSiteARMResource extends Resource { buildProperties?: StaticSiteBuildProperties; readonly contentDistributionEndpoint?: string; readonly customDomains?: string[]; + readonly databaseConnections?: DatabaseConnectionOverview[]; readonly defaultHostname?: string; enterpriseGradeCdnStatus?: EnterpriseGradeCdnStatus; identity?: ManagedServiceIdentity; @@ -6646,10 +6625,26 @@ export interface StaticSiteARMResource extends Resource { readonly userProvidedFunctionApps?: StaticSiteUserProvidedFunctionApp[]; } +// @public +export interface StaticSiteBasicAuthPropertiesARMResource extends ProxyOnlyResource { + applicableEnvironmentsMode?: string; + environments?: string[]; + password?: string; + readonly secretState?: string; + secretUrl?: string; +} + +// @public +export interface StaticSiteBasicAuthPropertiesCollection { + readonly nextLink?: string; + value: StaticSiteBasicAuthPropertiesARMResource[]; +} + // @public export interface StaticSiteBuildARMResource extends ProxyOnlyResource { readonly buildId?: string; readonly createdTimeUtc?: Date; + readonly databaseConnections?: DatabaseConnectionOverview[]; readonly hostname?: string; readonly lastUpdatedOn?: Date; readonly linkedBackends?: StaticSiteLinkedBackend[]; @@ -6703,6 +6698,13 @@ export interface StaticSiteCustomDomainRequestPropertiesARMResource extends Prox validationMethod?: string; } +// @public +export interface StaticSiteDatabaseConnectionConfigurationFileOverview { + readonly contents?: string; + readonly fileName?: string; + readonly type?: string; +} + // @public export interface StaticSiteFunctionOverviewARMResource extends ProxyOnlyResource { readonly functionName?: string; @@ -6744,6 +6746,7 @@ export interface StaticSitePatchResource extends ProxyOnlyResource { buildProperties?: StaticSiteBuildProperties; readonly contentDistributionEndpoint?: string; readonly customDomains?: string[]; + readonly databaseConnections?: DatabaseConnectionOverview[]; readonly defaultHostname?: string; enterpriseGradeCdnStatus?: EnterpriseGradeCdnStatus; readonly keyVaultReferenceIdentity?: string; @@ -6766,48 +6769,58 @@ export interface StaticSiteResetPropertiesARMResource extends ProxyOnlyResource // @public export interface StaticSites { - beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, StaticSitesApproveOrRejectPrivateEndpointConnectionResponse>>; + beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, StaticSitesApproveOrRejectPrivateEndpointConnectionResponse>>; beginApproveOrRejectPrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise; - beginCreateOrUpdateStaticSite(resourceGroupName: string, name: string, staticSiteEnvelope: StaticSiteARMResource, options?: StaticSitesCreateOrUpdateStaticSiteOptionalParams): Promise, StaticSitesCreateOrUpdateStaticSiteResponse>>; + beginCreateOrUpdateStaticSite(resourceGroupName: string, name: string, staticSiteEnvelope: StaticSiteARMResource, options?: StaticSitesCreateOrUpdateStaticSiteOptionalParams): Promise, StaticSitesCreateOrUpdateStaticSiteResponse>>; beginCreateOrUpdateStaticSiteAndWait(resourceGroupName: string, name: string, staticSiteEnvelope: StaticSiteARMResource, options?: StaticSitesCreateOrUpdateStaticSiteOptionalParams): Promise; - beginCreateOrUpdateStaticSiteCustomDomain(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesCreateOrUpdateStaticSiteCustomDomainOptionalParams): Promise, StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse>>; + beginCreateOrUpdateStaticSiteCustomDomain(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesCreateOrUpdateStaticSiteCustomDomainOptionalParams): Promise, StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse>>; beginCreateOrUpdateStaticSiteCustomDomainAndWait(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesCreateOrUpdateStaticSiteCustomDomainOptionalParams): Promise; - beginCreateZipDeploymentForStaticSite(resourceGroupName: string, name: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteOptionalParams): Promise, void>>; + beginCreateZipDeploymentForStaticSite(resourceGroupName: string, name: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteOptionalParams): Promise, void>>; beginCreateZipDeploymentForStaticSiteAndWait(resourceGroupName: string, name: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteOptionalParams): Promise; - beginCreateZipDeploymentForStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams): Promise, void>>; + beginCreateZipDeploymentForStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams): Promise, void>>; beginCreateZipDeploymentForStaticSiteBuildAndWait(resourceGroupName: string, name: string, environmentName: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams): Promise; - beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: StaticSitesDeletePrivateEndpointConnectionOptionalParams): Promise, StaticSitesDeletePrivateEndpointConnectionResponse>>; + beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: StaticSitesDeletePrivateEndpointConnectionOptionalParams): Promise, StaticSitesDeletePrivateEndpointConnectionResponse>>; beginDeletePrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: StaticSitesDeletePrivateEndpointConnectionOptionalParams): Promise; - beginDeleteStaticSite(resourceGroupName: string, name: string, options?: StaticSitesDeleteStaticSiteOptionalParams): Promise, void>>; + beginDeleteStaticSite(resourceGroupName: string, name: string, options?: StaticSitesDeleteStaticSiteOptionalParams): Promise, void>>; beginDeleteStaticSiteAndWait(resourceGroupName: string, name: string, options?: StaticSitesDeleteStaticSiteOptionalParams): Promise; - beginDeleteStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesDeleteStaticSiteBuildOptionalParams): Promise, void>>; + beginDeleteStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesDeleteStaticSiteBuildOptionalParams): Promise, void>>; beginDeleteStaticSiteBuildAndWait(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesDeleteStaticSiteBuildOptionalParams): Promise; - beginDeleteStaticSiteCustomDomain(resourceGroupName: string, name: string, domainName: string, options?: StaticSitesDeleteStaticSiteCustomDomainOptionalParams): Promise, void>>; + beginDeleteStaticSiteCustomDomain(resourceGroupName: string, name: string, domainName: string, options?: StaticSitesDeleteStaticSiteCustomDomainOptionalParams): Promise, void>>; beginDeleteStaticSiteCustomDomainAndWait(resourceGroupName: string, name: string, domainName: string, options?: StaticSitesDeleteStaticSiteCustomDomainOptionalParams): Promise; - beginDetachStaticSite(resourceGroupName: string, name: string, options?: StaticSitesDetachStaticSiteOptionalParams): Promise, void>>; + beginDetachStaticSite(resourceGroupName: string, name: string, options?: StaticSitesDetachStaticSiteOptionalParams): Promise, void>>; beginDetachStaticSiteAndWait(resourceGroupName: string, name: string, options?: StaticSitesDetachStaticSiteOptionalParams): Promise; - beginLinkBackend(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendOptionalParams): Promise, StaticSitesLinkBackendResponse>>; + beginLinkBackend(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendOptionalParams): Promise, StaticSitesLinkBackendResponse>>; beginLinkBackendAndWait(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendOptionalParams): Promise; - beginLinkBackendToBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendToBuildOptionalParams): Promise, StaticSitesLinkBackendToBuildResponse>>; + beginLinkBackendToBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendToBuildOptionalParams): Promise, StaticSitesLinkBackendToBuildResponse>>; beginLinkBackendToBuildAndWait(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendToBuildOptionalParams): Promise; - beginRegisterUserProvidedFunctionAppWithStaticSite(resourceGroupName: string, name: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteOptionalParams): Promise, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse>>; + beginRegisterUserProvidedFunctionAppWithStaticSite(resourceGroupName: string, name: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteOptionalParams): Promise, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse>>; beginRegisterUserProvidedFunctionAppWithStaticSiteAndWait(resourceGroupName: string, name: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteOptionalParams): Promise; - beginRegisterUserProvidedFunctionAppWithStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildOptionalParams): Promise, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse>>; + beginRegisterUserProvidedFunctionAppWithStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildOptionalParams): Promise, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse>>; beginRegisterUserProvidedFunctionAppWithStaticSiteBuildAndWait(resourceGroupName: string, name: string, environmentName: string, functionAppName: string, staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildOptionalParams): Promise; - beginValidateBackend(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendOptionalParams): Promise, void>>; + beginValidateBackend(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendOptionalParams): Promise, void>>; beginValidateBackendAndWait(resourceGroupName: string, name: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendOptionalParams): Promise; - beginValidateBackendForBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendForBuildOptionalParams): Promise, void>>; + beginValidateBackendForBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendForBuildOptionalParams): Promise, void>>; beginValidateBackendForBuildAndWait(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendForBuildOptionalParams): Promise; - beginValidateCustomDomainCanBeAddedToStaticSite(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams): Promise, void>>; + beginValidateCustomDomainCanBeAddedToStaticSite(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams): Promise, void>>; beginValidateCustomDomainCanBeAddedToStaticSiteAndWait(resourceGroupName: string, name: string, domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams): Promise; + createOrUpdateBasicAuth(resourceGroupName: string, name: string, basicAuthName: BasicAuthName, basicAuthEnvelope: StaticSiteBasicAuthPropertiesARMResource, options?: StaticSitesCreateOrUpdateBasicAuthOptionalParams): Promise; + createOrUpdateBuildDatabaseConnection(resourceGroupName: string, name: string, environmentName: string, databaseConnectionName: string, databaseConnectionRequestEnvelope: DatabaseConnection, options?: StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams): Promise; + createOrUpdateDatabaseConnection(resourceGroupName: string, name: string, databaseConnectionName: string, databaseConnectionRequestEnvelope: DatabaseConnection, options?: StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams): Promise; createOrUpdateStaticSiteAppSettings(resourceGroupName: string, name: string, appSettings: StringDictionary, options?: StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams): Promise; createOrUpdateStaticSiteBuildAppSettings(resourceGroupName: string, name: string, environmentName: string, appSettings: StringDictionary, options?: StaticSitesCreateOrUpdateStaticSiteBuildAppSettingsOptionalParams): Promise; createOrUpdateStaticSiteBuildFunctionAppSettings(resourceGroupName: string, name: string, environmentName: string, appSettings: StringDictionary, options?: StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOptionalParams): Promise; createOrUpdateStaticSiteFunctionAppSettings(resourceGroupName: string, name: string, appSettings: StringDictionary, options?: StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsOptionalParams): Promise; createUserRolesInvitationLink(resourceGroupName: string, name: string, staticSiteUserRolesInvitationEnvelope: StaticSiteUserInvitationRequestResource, options?: StaticSitesCreateUserRolesInvitationLinkOptionalParams): Promise; + deleteBuildDatabaseConnection(resourceGroupName: string, name: string, environmentName: string, databaseConnectionName: string, options?: StaticSitesDeleteBuildDatabaseConnectionOptionalParams): Promise; + deleteDatabaseConnection(resourceGroupName: string, name: string, databaseConnectionName: string, options?: StaticSitesDeleteDatabaseConnectionOptionalParams): Promise; deleteStaticSiteUser(resourceGroupName: string, name: string, authprovider: string, userid: string, options?: StaticSitesDeleteStaticSiteUserOptionalParams): Promise; detachUserProvidedFunctionAppFromStaticSite(resourceGroupName: string, name: string, functionAppName: string, options?: StaticSitesDetachUserProvidedFunctionAppFromStaticSiteOptionalParams): Promise; detachUserProvidedFunctionAppFromStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, functionAppName: string, options?: StaticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildOptionalParams): Promise; + getBasicAuth(resourceGroupName: string, name: string, basicAuthName: BasicAuthName, options?: StaticSitesGetBasicAuthOptionalParams): Promise; + getBuildDatabaseConnection(resourceGroupName: string, name: string, environmentName: string, databaseConnectionName: string, options?: StaticSitesGetBuildDatabaseConnectionOptionalParams): Promise; + getBuildDatabaseConnectionWithDetails(resourceGroupName: string, name: string, environmentName: string, databaseConnectionName: string, options?: StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams): Promise; + getDatabaseConnection(resourceGroupName: string, name: string, databaseConnectionName: string, options?: StaticSitesGetDatabaseConnectionOptionalParams): Promise; + getDatabaseConnectionWithDetails(resourceGroupName: string, name: string, databaseConnectionName: string, options?: StaticSitesGetDatabaseConnectionWithDetailsOptionalParams): Promise; getLinkedBackend(resourceGroupName: string, name: string, linkedBackendName: string, options?: StaticSitesGetLinkedBackendOptionalParams): Promise; getLinkedBackendForBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, options?: StaticSitesGetLinkedBackendForBuildOptionalParams): Promise; getPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: StaticSitesGetPrivateEndpointConnectionOptionalParams): Promise; @@ -6818,6 +6831,11 @@ export interface StaticSites { getUserProvidedFunctionAppForStaticSite(resourceGroupName: string, name: string, functionAppName: string, options?: StaticSitesGetUserProvidedFunctionAppForStaticSiteOptionalParams): Promise; getUserProvidedFunctionAppForStaticSiteBuild(resourceGroupName: string, name: string, environmentName: string, functionAppName: string, options?: StaticSitesGetUserProvidedFunctionAppForStaticSiteBuildOptionalParams): Promise; list(options?: StaticSitesListOptionalParams): PagedAsyncIterableIterator; + listBasicAuth(resourceGroupName: string, name: string, options?: StaticSitesListBasicAuthOptionalParams): PagedAsyncIterableIterator; + listBuildDatabaseConnections(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams): PagedAsyncIterableIterator; + listBuildDatabaseConnectionsWithDetails(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams): PagedAsyncIterableIterator; + listDatabaseConnections(resourceGroupName: string, name: string, options?: StaticSitesGetDatabaseConnectionsOptionalParams): PagedAsyncIterableIterator; + listDatabaseConnectionsWithDetails(resourceGroupName: string, name: string, options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams): PagedAsyncIterableIterator; listLinkedBackends(resourceGroupName: string, name: string, options?: StaticSitesGetLinkedBackendsOptionalParams): PagedAsyncIterableIterator; listLinkedBackendsForBuild(resourceGroupName: string, name: string, environmentName: string, options?: StaticSitesGetLinkedBackendsForBuildOptionalParams): PagedAsyncIterableIterator; listPrivateEndpointConnectionList(resourceGroupName: string, name: string, options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams): PagedAsyncIterableIterator; @@ -6839,6 +6857,8 @@ export interface StaticSites { resetStaticSiteApiKey(resourceGroupName: string, name: string, resetPropertiesEnvelope: StaticSiteResetPropertiesARMResource, options?: StaticSitesResetStaticSiteApiKeyOptionalParams): Promise; unlinkBackend(resourceGroupName: string, name: string, linkedBackendName: string, options?: StaticSitesUnlinkBackendOptionalParams): Promise; unlinkBackendFromBuild(resourceGroupName: string, name: string, environmentName: string, linkedBackendName: string, options?: StaticSitesUnlinkBackendFromBuildOptionalParams): Promise; + updateBuildDatabaseConnection(resourceGroupName: string, name: string, environmentName: string, databaseConnectionName: string, databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, options?: StaticSitesUpdateBuildDatabaseConnectionOptionalParams): Promise; + updateDatabaseConnection(resourceGroupName: string, name: string, databaseConnectionName: string, databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, options?: StaticSitesUpdateDatabaseConnectionOptionalParams): Promise; updateStaticSite(resourceGroupName: string, name: string, staticSiteEnvelope: StaticSitePatchResource, options?: StaticSitesUpdateStaticSiteOptionalParams): Promise; updateStaticSiteUser(resourceGroupName: string, name: string, authprovider: string, userid: string, staticSiteUserEnvelope: StaticSiteUserARMResource, options?: StaticSitesUpdateStaticSiteUserOptionalParams): Promise; } @@ -6852,6 +6872,27 @@ export interface StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalPara // @public export type StaticSitesApproveOrRejectPrivateEndpointConnectionResponse = RemotePrivateEndpointConnectionARMResource; +// @public +export interface StaticSitesCreateOrUpdateBasicAuthOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesCreateOrUpdateBasicAuthResponse = StaticSiteBasicAuthPropertiesARMResource; + +// @public +export interface StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesCreateOrUpdateBuildDatabaseConnectionResponse = DatabaseConnection; + +// @public +export interface StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesCreateOrUpdateDatabaseConnectionResponse = DatabaseConnection; + // @public export interface StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams extends coreClient.OperationOptions { } @@ -6917,6 +6958,14 @@ export interface StaticSitesCreateZipDeploymentForStaticSiteOptionalParams exten updateIntervalInMs?: number; } +// @public +export interface StaticSitesDeleteBuildDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface StaticSitesDeleteDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + // @public export interface StaticSitesDeletePrivateEndpointConnectionOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -6962,6 +7011,97 @@ export interface StaticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildOpti export interface StaticSitesDetachUserProvidedFunctionAppFromStaticSiteOptionalParams extends coreClient.OperationOptions { } +// @public +export interface StaticSitesGetBasicAuthOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBasicAuthResponse = StaticSiteBasicAuthPropertiesARMResource; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionResponse = DatabaseConnection; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionsNextResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionsResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionsWithDetailsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionsWithDetailsNextResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionsWithDetailsResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetBuildDatabaseConnectionWithDetailsResponse = DatabaseConnection; + +// @public +export interface StaticSitesGetDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionResponse = DatabaseConnection; + +// @public +export interface StaticSitesGetDatabaseConnectionsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionsNextResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetDatabaseConnectionsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionsResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetDatabaseConnectionsWithDetailsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionsWithDetailsNextResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionsWithDetailsResponse = DatabaseConnectionCollection; + +// @public +export interface StaticSitesGetDatabaseConnectionWithDetailsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesGetDatabaseConnectionWithDetailsResponse = DatabaseConnection; + // @public export interface StaticSitesGetLinkedBackendForBuildOptionalParams extends coreClient.OperationOptions { } @@ -7141,6 +7281,20 @@ export interface StaticSitesLinkBackendToBuildOptionalParams extends coreClient. // @public export type StaticSitesLinkBackendToBuildResponse = StaticSiteLinkedBackendARMResource; +// @public +export interface StaticSitesListBasicAuthNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesListBasicAuthNextResponse = StaticSiteBasicAuthPropertiesCollection; + +// @public +export interface StaticSitesListBasicAuthOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesListBasicAuthResponse = StaticSiteBasicAuthPropertiesCollection; + // @public export interface StaticSitesListNextOptionalParams extends coreClient.OperationOptions { } @@ -7294,6 +7448,20 @@ export interface StaticSitesUnlinkBackendOptionalParams extends coreClient.Opera isCleaningAuthConfig?: boolean; } +// @public +export interface StaticSitesUpdateBuildDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesUpdateBuildDatabaseConnectionResponse = DatabaseConnection; + +// @public +export interface StaticSitesUpdateDatabaseConnectionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type StaticSitesUpdateDatabaseConnectionResponse = DatabaseConnection; + // @public export interface StaticSitesUpdateStaticSiteOptionalParams extends coreClient.OperationOptions { } @@ -7908,77 +8076,77 @@ export interface WebApps { applySlotConfigurationSlot(resourceGroupName: string, name: string, slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsApplySlotConfigurationSlotOptionalParams): Promise; backup(resourceGroupName: string, name: string, request: BackupRequest, options?: WebAppsBackupOptionalParams): Promise; backupSlot(resourceGroupName: string, name: string, slot: string, request: BackupRequest, options?: WebAppsBackupSlotOptionalParams): Promise; - beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, WebAppsApproveOrRejectPrivateEndpointConnectionResponse>>; + beginApproveOrRejectPrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise, WebAppsApproveOrRejectPrivateEndpointConnectionResponse>>; beginApproveOrRejectPrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionOptionalParams): Promise; - beginApproveOrRejectPrivateEndpointConnectionSlot(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionSlotOptionalParams): Promise, WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse>>; + beginApproveOrRejectPrivateEndpointConnectionSlot(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionSlotOptionalParams): Promise, WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse>>; beginApproveOrRejectPrivateEndpointConnectionSlotAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionSlotOptionalParams): Promise; - beginCreateFunction(resourceGroupName: string, name: string, functionName: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateFunctionOptionalParams): Promise, WebAppsCreateFunctionResponse>>; + beginCreateFunction(resourceGroupName: string, name: string, functionName: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateFunctionOptionalParams): Promise, WebAppsCreateFunctionResponse>>; beginCreateFunctionAndWait(resourceGroupName: string, name: string, functionName: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateFunctionOptionalParams): Promise; - beginCreateInstanceFunctionSlot(resourceGroupName: string, name: string, functionName: string, slot: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateInstanceFunctionSlotOptionalParams): Promise, WebAppsCreateInstanceFunctionSlotResponse>>; + beginCreateInstanceFunctionSlot(resourceGroupName: string, name: string, functionName: string, slot: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateInstanceFunctionSlotOptionalParams): Promise, WebAppsCreateInstanceFunctionSlotResponse>>; beginCreateInstanceFunctionSlotAndWait(resourceGroupName: string, name: string, functionName: string, slot: string, functionEnvelope: FunctionEnvelope, options?: WebAppsCreateInstanceFunctionSlotOptionalParams): Promise; - beginCreateInstanceMSDeployOperation(resourceGroupName: string, name: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationOptionalParams): Promise, WebAppsCreateInstanceMSDeployOperationResponse>>; + beginCreateInstanceMSDeployOperation(resourceGroupName: string, name: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationOptionalParams): Promise, WebAppsCreateInstanceMSDeployOperationResponse>>; beginCreateInstanceMSDeployOperationAndWait(resourceGroupName: string, name: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationOptionalParams): Promise; - beginCreateInstanceMSDeployOperationSlot(resourceGroupName: string, name: string, slot: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationSlotOptionalParams): Promise, WebAppsCreateInstanceMSDeployOperationSlotResponse>>; + beginCreateInstanceMSDeployOperationSlot(resourceGroupName: string, name: string, slot: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationSlotOptionalParams): Promise, WebAppsCreateInstanceMSDeployOperationSlotResponse>>; beginCreateInstanceMSDeployOperationSlotAndWait(resourceGroupName: string, name: string, slot: string, instanceId: string, mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationSlotOptionalParams): Promise; - beginCreateMSDeployOperation(resourceGroupName: string, name: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationOptionalParams): Promise, WebAppsCreateMSDeployOperationResponse>>; + beginCreateMSDeployOperation(resourceGroupName: string, name: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationOptionalParams): Promise, WebAppsCreateMSDeployOperationResponse>>; beginCreateMSDeployOperationAndWait(resourceGroupName: string, name: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationOptionalParams): Promise; - beginCreateMSDeployOperationSlot(resourceGroupName: string, name: string, slot: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationSlotOptionalParams): Promise, WebAppsCreateMSDeployOperationSlotResponse>>; + beginCreateMSDeployOperationSlot(resourceGroupName: string, name: string, slot: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationSlotOptionalParams): Promise, WebAppsCreateMSDeployOperationSlotResponse>>; beginCreateMSDeployOperationSlotAndWait(resourceGroupName: string, name: string, slot: string, mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationSlotOptionalParams): Promise; - beginCreateOrUpdate(resourceGroupName: string, name: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateOptionalParams): Promise, WebAppsCreateOrUpdateResponse>>; + beginCreateOrUpdate(resourceGroupName: string, name: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateOptionalParams): Promise, WebAppsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateOptionalParams): Promise; - beginCreateOrUpdateSlot(resourceGroupName: string, name: string, slot: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateSlotOptionalParams): Promise, WebAppsCreateOrUpdateSlotResponse>>; + beginCreateOrUpdateSlot(resourceGroupName: string, name: string, slot: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateSlotOptionalParams): Promise, WebAppsCreateOrUpdateSlotResponse>>; beginCreateOrUpdateSlotAndWait(resourceGroupName: string, name: string, slot: string, siteEnvelope: Site, options?: WebAppsCreateOrUpdateSlotOptionalParams): Promise; - beginCreateOrUpdateSourceControl(resourceGroupName: string, name: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlOptionalParams): Promise, WebAppsCreateOrUpdateSourceControlResponse>>; + beginCreateOrUpdateSourceControl(resourceGroupName: string, name: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlOptionalParams): Promise, WebAppsCreateOrUpdateSourceControlResponse>>; beginCreateOrUpdateSourceControlAndWait(resourceGroupName: string, name: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlOptionalParams): Promise; - beginCreateOrUpdateSourceControlSlot(resourceGroupName: string, name: string, slot: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlSlotOptionalParams): Promise, WebAppsCreateOrUpdateSourceControlSlotResponse>>; + beginCreateOrUpdateSourceControlSlot(resourceGroupName: string, name: string, slot: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlSlotOptionalParams): Promise, WebAppsCreateOrUpdateSourceControlSlotResponse>>; beginCreateOrUpdateSourceControlSlotAndWait(resourceGroupName: string, name: string, slot: string, siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlSlotOptionalParams): Promise; - beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: WebAppsDeletePrivateEndpointConnectionOptionalParams): Promise, WebAppsDeletePrivateEndpointConnectionResponse>>; + beginDeletePrivateEndpointConnection(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: WebAppsDeletePrivateEndpointConnectionOptionalParams): Promise, WebAppsDeletePrivateEndpointConnectionResponse>>; beginDeletePrivateEndpointConnectionAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, options?: WebAppsDeletePrivateEndpointConnectionOptionalParams): Promise; - beginDeletePrivateEndpointConnectionSlot(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, options?: WebAppsDeletePrivateEndpointConnectionSlotOptionalParams): Promise, WebAppsDeletePrivateEndpointConnectionSlotResponse>>; + beginDeletePrivateEndpointConnectionSlot(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, options?: WebAppsDeletePrivateEndpointConnectionSlotOptionalParams): Promise, WebAppsDeletePrivateEndpointConnectionSlotResponse>>; beginDeletePrivateEndpointConnectionSlotAndWait(resourceGroupName: string, name: string, privateEndpointConnectionName: string, slot: string, options?: WebAppsDeletePrivateEndpointConnectionSlotOptionalParams): Promise; - beginGetProductionSiteDeploymentStatus(resourceGroupName: string, name: string, deploymentStatusId: string, options?: WebAppsGetProductionSiteDeploymentStatusOptionalParams): Promise, WebAppsGetProductionSiteDeploymentStatusResponse>>; + beginGetProductionSiteDeploymentStatus(resourceGroupName: string, name: string, deploymentStatusId: string, options?: WebAppsGetProductionSiteDeploymentStatusOptionalParams): Promise, WebAppsGetProductionSiteDeploymentStatusResponse>>; beginGetProductionSiteDeploymentStatusAndWait(resourceGroupName: string, name: string, deploymentStatusId: string, options?: WebAppsGetProductionSiteDeploymentStatusOptionalParams): Promise; - beginGetSlotSiteDeploymentStatusSlot(resourceGroupName: string, name: string, slot: string, deploymentStatusId: string, options?: WebAppsGetSlotSiteDeploymentStatusSlotOptionalParams): Promise, WebAppsGetSlotSiteDeploymentStatusSlotResponse>>; + beginGetSlotSiteDeploymentStatusSlot(resourceGroupName: string, name: string, slot: string, deploymentStatusId: string, options?: WebAppsGetSlotSiteDeploymentStatusSlotOptionalParams): Promise, WebAppsGetSlotSiteDeploymentStatusSlotResponse>>; beginGetSlotSiteDeploymentStatusSlotAndWait(resourceGroupName: string, name: string, slot: string, deploymentStatusId: string, options?: WebAppsGetSlotSiteDeploymentStatusSlotOptionalParams): Promise; - beginInstallSiteExtension(resourceGroupName: string, name: string, siteExtensionId: string, options?: WebAppsInstallSiteExtensionOptionalParams): Promise, WebAppsInstallSiteExtensionResponse>>; + beginInstallSiteExtension(resourceGroupName: string, name: string, siteExtensionId: string, options?: WebAppsInstallSiteExtensionOptionalParams): Promise, WebAppsInstallSiteExtensionResponse>>; beginInstallSiteExtensionAndWait(resourceGroupName: string, name: string, siteExtensionId: string, options?: WebAppsInstallSiteExtensionOptionalParams): Promise; - beginInstallSiteExtensionSlot(resourceGroupName: string, name: string, siteExtensionId: string, slot: string, options?: WebAppsInstallSiteExtensionSlotOptionalParams): Promise, WebAppsInstallSiteExtensionSlotResponse>>; + beginInstallSiteExtensionSlot(resourceGroupName: string, name: string, siteExtensionId: string, slot: string, options?: WebAppsInstallSiteExtensionSlotOptionalParams): Promise, WebAppsInstallSiteExtensionSlotResponse>>; beginInstallSiteExtensionSlotAndWait(resourceGroupName: string, name: string, siteExtensionId: string, slot: string, options?: WebAppsInstallSiteExtensionSlotOptionalParams): Promise; - beginListPublishingCredentials(resourceGroupName: string, name: string, options?: WebAppsListPublishingCredentialsOptionalParams): Promise, WebAppsListPublishingCredentialsResponse>>; + beginListPublishingCredentials(resourceGroupName: string, name: string, options?: WebAppsListPublishingCredentialsOptionalParams): Promise, WebAppsListPublishingCredentialsResponse>>; beginListPublishingCredentialsAndWait(resourceGroupName: string, name: string, options?: WebAppsListPublishingCredentialsOptionalParams): Promise; - beginListPublishingCredentialsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListPublishingCredentialsSlotOptionalParams): Promise, WebAppsListPublishingCredentialsSlotResponse>>; + beginListPublishingCredentialsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListPublishingCredentialsSlotOptionalParams): Promise, WebAppsListPublishingCredentialsSlotResponse>>; beginListPublishingCredentialsSlotAndWait(resourceGroupName: string, name: string, slot: string, options?: WebAppsListPublishingCredentialsSlotOptionalParams): Promise; - beginMigrateMySql(resourceGroupName: string, name: string, migrationRequestEnvelope: MigrateMySqlRequest, options?: WebAppsMigrateMySqlOptionalParams): Promise, WebAppsMigrateMySqlResponse>>; + beginMigrateMySql(resourceGroupName: string, name: string, migrationRequestEnvelope: MigrateMySqlRequest, options?: WebAppsMigrateMySqlOptionalParams): Promise, WebAppsMigrateMySqlResponse>>; beginMigrateMySqlAndWait(resourceGroupName: string, name: string, migrationRequestEnvelope: MigrateMySqlRequest, options?: WebAppsMigrateMySqlOptionalParams): Promise; - beginMigrateStorage(subscriptionName: string, resourceGroupName: string, name: string, migrationOptions: StorageMigrationOptions, options?: WebAppsMigrateStorageOptionalParams): Promise, WebAppsMigrateStorageResponse>>; + beginMigrateStorage(subscriptionName: string, resourceGroupName: string, name: string, migrationOptions: StorageMigrationOptions, options?: WebAppsMigrateStorageOptionalParams): Promise, WebAppsMigrateStorageResponse>>; beginMigrateStorageAndWait(subscriptionName: string, resourceGroupName: string, name: string, migrationOptions: StorageMigrationOptions, options?: WebAppsMigrateStorageOptionalParams): Promise; - beginRestore(resourceGroupName: string, name: string, backupId: string, request: RestoreRequest, options?: WebAppsRestoreOptionalParams): Promise, void>>; + beginRestore(resourceGroupName: string, name: string, backupId: string, request: RestoreRequest, options?: WebAppsRestoreOptionalParams): Promise, void>>; beginRestoreAndWait(resourceGroupName: string, name: string, backupId: string, request: RestoreRequest, options?: WebAppsRestoreOptionalParams): Promise; - beginRestoreFromBackupBlob(resourceGroupName: string, name: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobOptionalParams): Promise, void>>; + beginRestoreFromBackupBlob(resourceGroupName: string, name: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobOptionalParams): Promise, void>>; beginRestoreFromBackupBlobAndWait(resourceGroupName: string, name: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobOptionalParams): Promise; - beginRestoreFromBackupBlobSlot(resourceGroupName: string, name: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobSlotOptionalParams): Promise, void>>; + beginRestoreFromBackupBlobSlot(resourceGroupName: string, name: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobSlotOptionalParams): Promise, void>>; beginRestoreFromBackupBlobSlotAndWait(resourceGroupName: string, name: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobSlotOptionalParams): Promise; - beginRestoreFromDeletedApp(resourceGroupName: string, name: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppOptionalParams): Promise, void>>; + beginRestoreFromDeletedApp(resourceGroupName: string, name: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppOptionalParams): Promise, void>>; beginRestoreFromDeletedAppAndWait(resourceGroupName: string, name: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppOptionalParams): Promise; - beginRestoreFromDeletedAppSlot(resourceGroupName: string, name: string, slot: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppSlotOptionalParams): Promise, void>>; + beginRestoreFromDeletedAppSlot(resourceGroupName: string, name: string, slot: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppSlotOptionalParams): Promise, void>>; beginRestoreFromDeletedAppSlotAndWait(resourceGroupName: string, name: string, slot: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppSlotOptionalParams): Promise; - beginRestoreSlot(resourceGroupName: string, name: string, backupId: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreSlotOptionalParams): Promise, void>>; + beginRestoreSlot(resourceGroupName: string, name: string, backupId: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreSlotOptionalParams): Promise, void>>; beginRestoreSlotAndWait(resourceGroupName: string, name: string, backupId: string, slot: string, request: RestoreRequest, options?: WebAppsRestoreSlotOptionalParams): Promise; - beginRestoreSnapshot(resourceGroupName: string, name: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotOptionalParams): Promise, void>>; + beginRestoreSnapshot(resourceGroupName: string, name: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotOptionalParams): Promise, void>>; beginRestoreSnapshotAndWait(resourceGroupName: string, name: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotOptionalParams): Promise; - beginRestoreSnapshotSlot(resourceGroupName: string, name: string, slot: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotSlotOptionalParams): Promise, void>>; + beginRestoreSnapshotSlot(resourceGroupName: string, name: string, slot: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotSlotOptionalParams): Promise, void>>; beginRestoreSnapshotSlotAndWait(resourceGroupName: string, name: string, slot: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotSlotOptionalParams): Promise; - beginStartNetworkTrace(resourceGroupName: string, name: string, options?: WebAppsStartNetworkTraceOptionalParams): Promise, WebAppsStartNetworkTraceResponse>>; + beginStartNetworkTrace(resourceGroupName: string, name: string, options?: WebAppsStartNetworkTraceOptionalParams): Promise, WebAppsStartNetworkTraceResponse>>; beginStartNetworkTraceAndWait(resourceGroupName: string, name: string, options?: WebAppsStartNetworkTraceOptionalParams): Promise; - beginStartNetworkTraceSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartNetworkTraceSlotOptionalParams): Promise, WebAppsStartNetworkTraceSlotResponse>>; + beginStartNetworkTraceSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartNetworkTraceSlotOptionalParams): Promise, WebAppsStartNetworkTraceSlotResponse>>; beginStartNetworkTraceSlotAndWait(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartNetworkTraceSlotOptionalParams): Promise; - beginStartWebSiteNetworkTraceOperation(resourceGroupName: string, name: string, options?: WebAppsStartWebSiteNetworkTraceOperationOptionalParams): Promise, WebAppsStartWebSiteNetworkTraceOperationResponse>>; + beginStartWebSiteNetworkTraceOperation(resourceGroupName: string, name: string, options?: WebAppsStartWebSiteNetworkTraceOperationOptionalParams): Promise, WebAppsStartWebSiteNetworkTraceOperationResponse>>; beginStartWebSiteNetworkTraceOperationAndWait(resourceGroupName: string, name: string, options?: WebAppsStartWebSiteNetworkTraceOperationOptionalParams): Promise; - beginStartWebSiteNetworkTraceOperationSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartWebSiteNetworkTraceOperationSlotOptionalParams): Promise, WebAppsStartWebSiteNetworkTraceOperationSlotResponse>>; + beginStartWebSiteNetworkTraceOperationSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartWebSiteNetworkTraceOperationSlotOptionalParams): Promise, WebAppsStartWebSiteNetworkTraceOperationSlotResponse>>; beginStartWebSiteNetworkTraceOperationSlotAndWait(resourceGroupName: string, name: string, slot: string, options?: WebAppsStartWebSiteNetworkTraceOperationSlotOptionalParams): Promise; - beginSwapSlot(resourceGroupName: string, name: string, slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotOptionalParams): Promise, void>>; + beginSwapSlot(resourceGroupName: string, name: string, slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotOptionalParams): Promise, void>>; beginSwapSlotAndWait(resourceGroupName: string, name: string, slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotOptionalParams): Promise; - beginSwapSlotWithProduction(resourceGroupName: string, name: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotWithProductionOptionalParams): Promise, void>>; + beginSwapSlotWithProduction(resourceGroupName: string, name: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotWithProductionOptionalParams): Promise, void>>; beginSwapSlotWithProductionAndWait(resourceGroupName: string, name: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotWithProductionOptionalParams): Promise; createDeployment(resourceGroupName: string, name: string, id: string, deployment: Deployment, options?: WebAppsCreateDeploymentOptionalParams): Promise; createDeploymentSlot(resourceGroupName: string, name: string, id: string, slot: string, deployment: Deployment, options?: WebAppsCreateDeploymentSlotOptionalParams): Promise; @@ -8047,6 +8215,8 @@ export interface WebApps { deleteTriggeredWebJobSlot(resourceGroupName: string, name: string, webJobName: string, slot: string, options?: WebAppsDeleteTriggeredWebJobSlotOptionalParams): Promise; deleteVnetConnection(resourceGroupName: string, name: string, vnetName: string, options?: WebAppsDeleteVnetConnectionOptionalParams): Promise; deleteVnetConnectionSlot(resourceGroupName: string, name: string, vnetName: string, slot: string, options?: WebAppsDeleteVnetConnectionSlotOptionalParams): Promise; + deployWorkflowArtifacts(resourceGroupName: string, name: string, options?: WebAppsDeployWorkflowArtifactsOptionalParams): Promise; + deployWorkflowArtifactsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsDeployWorkflowArtifactsSlotOptionalParams): Promise; discoverBackup(resourceGroupName: string, name: string, request: RestoreRequest, options?: WebAppsDiscoverBackupOptionalParams): Promise; discoverBackupSlot(resourceGroupName: string, name: string, slot: string, request: RestoreRequest, options?: WebAppsDiscoverBackupSlotOptionalParams): Promise; generateNewSitePublishingPassword(resourceGroupName: string, name: string, options?: WebAppsGenerateNewSitePublishingPasswordOptionalParams): Promise; @@ -8100,6 +8270,7 @@ export interface WebApps { getInstanceProcessModule(resourceGroupName: string, name: string, processId: string, baseAddress: string, instanceId: string, options?: WebAppsGetInstanceProcessModuleOptionalParams): Promise; getInstanceProcessModuleSlot(resourceGroupName: string, name: string, processId: string, baseAddress: string, slot: string, instanceId: string, options?: WebAppsGetInstanceProcessModuleSlotOptionalParams): Promise; getInstanceProcessSlot(resourceGroupName: string, name: string, processId: string, slot: string, instanceId: string, options?: WebAppsGetInstanceProcessSlotOptionalParams): Promise; + getInstanceWorkflowSlot(resourceGroupName: string, name: string, slot: string, workflowName: string, options?: WebAppsGetInstanceWorkflowSlotOptionalParams): Promise; getMigrateMySqlStatus(resourceGroupName: string, name: string, options?: WebAppsGetMigrateMySqlStatusOptionalParams): Promise; getMigrateMySqlStatusSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsGetMigrateMySqlStatusSlotOptionalParams): Promise; getMSDeployLog(resourceGroupName: string, name: string, options?: WebAppsGetMSDeployLogOptionalParams): Promise; @@ -8158,6 +8329,7 @@ export interface WebApps { getWebJobSlot(resourceGroupName: string, name: string, webJobName: string, slot: string, options?: WebAppsGetWebJobSlotOptionalParams): Promise; getWebSiteContainerLogs(resourceGroupName: string, name: string, options?: WebAppsGetWebSiteContainerLogsOptionalParams): Promise; getWebSiteContainerLogsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsGetWebSiteContainerLogsSlotOptionalParams): Promise; + getWorkflow(resourceGroupName: string, name: string, workflowName: string, options?: WebAppsGetWorkflowOptionalParams): Promise; isCloneable(resourceGroupName: string, name: string, options?: WebAppsIsCloneableOptionalParams): Promise; isCloneableSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsIsCloneableSlotOptionalParams): Promise; list(options?: WebAppsListOptionalParams): PagedAsyncIterableIterator; @@ -8208,6 +8380,7 @@ export interface WebApps { listInstanceProcessModulesSlot(resourceGroupName: string, name: string, processId: string, slot: string, instanceId: string, options?: WebAppsListInstanceProcessModulesSlotOptionalParams): PagedAsyncIterableIterator; listInstanceProcessThreads(resourceGroupName: string, name: string, processId: string, instanceId: string, options?: WebAppsListInstanceProcessThreadsOptionalParams): PagedAsyncIterableIterator; listInstanceProcessThreadsSlot(resourceGroupName: string, name: string, processId: string, slot: string, instanceId: string, options?: WebAppsListInstanceProcessThreadsSlotOptionalParams): PagedAsyncIterableIterator; + listInstanceWorkflowsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListInstanceWorkflowsSlotOptionalParams): PagedAsyncIterableIterator; listMetadata(resourceGroupName: string, name: string, options?: WebAppsListMetadataOptionalParams): Promise; listMetadataSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListMetadataSlotOptionalParams): Promise; listNetworkFeatures(resourceGroupName: string, name: string, view: string, options?: WebAppsListNetworkFeaturesOptionalParams): Promise; @@ -8262,6 +8435,9 @@ export interface WebApps { listVnetConnectionsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListVnetConnectionsSlotOptionalParams): Promise; listWebJobs(resourceGroupName: string, name: string, options?: WebAppsListWebJobsOptionalParams): PagedAsyncIterableIterator; listWebJobsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListWebJobsSlotOptionalParams): PagedAsyncIterableIterator; + listWorkflows(resourceGroupName: string, name: string, options?: WebAppsListWorkflowsOptionalParams): PagedAsyncIterableIterator; + listWorkflowsConnections(resourceGroupName: string, name: string, options?: WebAppsListWorkflowsConnectionsOptionalParams): Promise; + listWorkflowsConnectionsSlot(resourceGroupName: string, name: string, slot: string, options?: WebAppsListWorkflowsConnectionsSlotOptionalParams): Promise; putPrivateAccessVnet(resourceGroupName: string, name: string, access: PrivateAccess, options?: WebAppsPutPrivateAccessVnetOptionalParams): Promise; putPrivateAccessVnetSlot(resourceGroupName: string, name: string, slot: string, access: PrivateAccess, options?: WebAppsPutPrivateAccessVnetSlotOptionalParams): Promise; recoverSiteConfigurationSnapshot(resourceGroupName: string, name: string, snapshotId: string, options?: WebAppsRecoverSiteConfigurationSnapshotOptionalParams): Promise; @@ -8866,6 +9042,16 @@ export interface WebAppsDeleteVnetConnectionOptionalParams extends coreClient.Op export interface WebAppsDeleteVnetConnectionSlotOptionalParams extends coreClient.OperationOptions { } +// @public +export interface WebAppsDeployWorkflowArtifactsOptionalParams extends coreClient.OperationOptions { + workflowArtifacts?: WorkflowArtifacts; +} + +// @public +export interface WebAppsDeployWorkflowArtifactsSlotOptionalParams extends coreClient.OperationOptions { + workflowArtifacts?: WorkflowArtifacts; +} + // @public export interface WebAppsDiscoverBackupOptionalParams extends coreClient.OperationOptions { } @@ -9268,6 +9454,13 @@ export interface WebAppsGetInstanceProcessSlotOptionalParams extends coreClient. // @public export type WebAppsGetInstanceProcessSlotResponse = ProcessInfo; +// @public +export interface WebAppsGetInstanceWorkflowSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsGetInstanceWorkflowSlotResponse = WorkflowEnvelope; + // @public export interface WebAppsGetMigrateMySqlStatusOptionalParams extends coreClient.OperationOptions { } @@ -9767,6 +9960,13 @@ export type WebAppsGetWebSiteContainerLogsSlotResponse = { readableStreamBody?: NodeJS.ReadableStream; }; +// @public +export interface WebAppsGetWorkflowOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsGetWorkflowResponse = WorkflowEnvelope; + // @public export interface WebAppsInstallSiteExtensionOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -9899,7 +10099,6 @@ export type WebAppsListBasicPublishingCredentialsPoliciesSlotResponse = Publishi // @public export interface WebAppsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { - includeSlots?: boolean; } // @public @@ -10305,6 +10504,20 @@ export interface WebAppsListInstanceProcessThreadsSlotOptionalParams extends cor // @public export type WebAppsListInstanceProcessThreadsSlotResponse = ProcessThreadInfoCollection; +// @public +export interface WebAppsListInstanceWorkflowsSlotNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListInstanceWorkflowsSlotNextResponse = WorkflowEnvelopeCollection; + +// @public +export interface WebAppsListInstanceWorkflowsSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListInstanceWorkflowsSlotResponse = WorkflowEnvelopeCollection; + // @public export interface WebAppsListMetadataOptionalParams extends coreClient.OperationOptions { } @@ -10346,7 +10559,6 @@ export interface WebAppsListOptionalParams extends coreClient.OperationOptions { // @public export interface WebAppsListPerfMonCountersNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -10362,7 +10574,6 @@ export type WebAppsListPerfMonCountersResponse = PerfMonCounterCollection; // @public export interface WebAppsListPerfMonCountersSlotNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -10840,7 +11051,6 @@ export type WebAppsListTriggeredWebJobsSlotResponse = TriggeredWebJobCollection; // @public export interface WebAppsListUsagesNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -10856,7 +11066,6 @@ export type WebAppsListUsagesResponse = CsmUsageQuotaCollection; // @public export interface WebAppsListUsagesSlotNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -10912,6 +11121,34 @@ export interface WebAppsListWebJobsSlotOptionalParams extends coreClient.Operati // @public export type WebAppsListWebJobsSlotResponse = WebJobCollection; +// @public +export interface WebAppsListWorkflowsConnectionsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListWorkflowsConnectionsResponse = WorkflowEnvelope; + +// @public +export interface WebAppsListWorkflowsConnectionsSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListWorkflowsConnectionsSlotResponse = WorkflowEnvelope; + +// @public +export interface WebAppsListWorkflowsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListWorkflowsNextResponse = WorkflowEnvelopeCollection; + +// @public +export interface WebAppsListWorkflowsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type WebAppsListWorkflowsResponse = WorkflowEnvelopeCollection; + // @public export interface WebAppsMigrateMySqlOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -11680,11 +11917,54 @@ export interface Workflow extends WorkflowResource { readonly version?: string; } +// @public +export interface WorkflowArtifacts { + appSettings?: Record; + files?: { + [propertyName: string]: Record; + }; + filesToDelete?: string[]; +} + +// @public +export interface WorkflowEnvelope { + readonly id?: string; + kind?: string; + location?: string; + readonly name?: string; + properties?: WorkflowEnvelopeProperties; + readonly type?: string; +} + +// @public +export interface WorkflowEnvelopeCollection { + readonly nextLink?: string; + value: WorkflowEnvelope[]; +} + +// @public +export interface WorkflowEnvelopeProperties { + files?: { + [propertyName: string]: Record; + }; + flowState?: WorkflowState; + health?: WorkflowHealth; +} + // @public export interface WorkflowFilter { state?: WorkflowState; } +// @public +export interface WorkflowHealth { + error?: ErrorEntity; + state: WorkflowHealthState; +} + +// @public +export type WorkflowHealthState = "NotSpecified" | "Healthy" | "Unhealthy" | "Unknown"; + // @public export interface WorkflowListResult { nextLink?: string; @@ -11924,8 +12204,6 @@ export type WorkflowRunActionsListExpressionTracesResponse = ExpressionTraces; // @public export interface WorkflowRunActionsListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - top?: number; } // @public @@ -11971,8 +12249,6 @@ export type WorkflowRunsGetResponse = WorkflowRun; // @public export interface WorkflowRunsListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - top?: number; } // @public @@ -12025,7 +12301,7 @@ export interface WorkflowsRegenerateAccessKeyOptionalParams extends coreClient.O } // @public -export type WorkflowState = string; +export type WorkflowState = "NotSpecified" | "Completed" | "Enabled" | "Disabled" | "Deleted" | "Suspended"; // @public export type WorkflowStatus = string; @@ -12066,7 +12342,7 @@ export interface WorkflowTriggerFilter { // @public export interface WorkflowTriggerHistories { - beginResubmit(resourceGroupName: string, name: string, workflowName: string, triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesResubmitOptionalParams): Promise, void>>; + beginResubmit(resourceGroupName: string, name: string, workflowName: string, triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesResubmitOptionalParams): Promise, void>>; beginResubmitAndWait(resourceGroupName: string, name: string, workflowName: string, triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesResubmitOptionalParams): Promise; get(resourceGroupName: string, name: string, workflowName: string, triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesGetOptionalParams): Promise; list(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggerHistoriesListOptionalParams): PagedAsyncIterableIterator; @@ -12081,8 +12357,6 @@ export type WorkflowTriggerHistoriesGetResponse = WorkflowTriggerHistory; // @public export interface WorkflowTriggerHistoriesListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - top?: number; } // @public @@ -12162,7 +12436,7 @@ export interface WorkflowTriggerRecurrence { // @public export interface WorkflowTriggers { - beginRun(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggersRunOptionalParams): Promise, void>>; + beginRun(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggersRunOptionalParams): Promise, void>>; beginRunAndWait(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggersRunOptionalParams): Promise; get(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggersGetOptionalParams): Promise; getSchemaJson(resourceGroupName: string, name: string, workflowName: string, triggerName: string, options?: WorkflowTriggersGetSchemaJsonOptionalParams): Promise; @@ -12193,8 +12467,6 @@ export type WorkflowTriggersListCallbackUrlResponse = WorkflowTriggerCallbackUrl // @public export interface WorkflowTriggersListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - top?: number; } // @public @@ -12254,7 +12526,6 @@ export type WorkflowVersionsGetResponse = WorkflowVersion; // @public export interface WorkflowVersionsListNextOptionalParams extends coreClient.OperationOptions { - top?: number; } // @public diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts index acf62a99a3da..cd6d4818638e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificate.json */ async function createCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate: AppServiceCertificateResource = { @@ -42,4 +48,8 @@ async function createCertificate() { console.log(result); } -createCertificate().catch(console.error); +async function main() { + createCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateSample.ts index 7499b4b43629..25bf1e810e06 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersCreateOrUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificateOrder.json */ async function createCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName: AppServiceCertificateOrder = { autoRenew: true, @@ -54,4 +60,8 @@ async function createCertificateOrder() { console.log(result); } -createCertificateOrder().catch(console.error); +async function main() { + createCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteCertificateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteCertificateSample.ts index 0a8217b4999f..b32252ef0c6d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteCertificateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete the certificate associated with a certificate order. * * @summary Description for Delete the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificate.json */ async function deleteAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function deleteAppServiceCertificate() { console.log(result); } -deleteAppServiceCertificate().catch(console.error); +async function main() { + deleteAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteSample.ts index ce9d1a9934fa..a000c0e45243 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersDeleteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete an existing certificate order. * * @summary Description for Delete an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificateOrder.json */ async function deleteAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function deleteAppServiceCertificateOrder() { console.log(result); } -deleteAppServiceCertificateOrder().catch(console.error); +async function main() { + deleteAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetCertificateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetCertificateSample.ts index 305a7346fed8..22fc06a06de7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetCertificateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the certificate associated with a certificate order. * * @summary Description for Get the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificate.json */ async function getAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getAppServiceCertificate() { console.log(result); } -getAppServiceCertificate().catch(console.error); +async function main() { + getAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetSample.ts index 906bd3e6b7a3..6254d66de3bb 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get a certificate order. * * @summary Description for Get a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificateOrder.json */ async function getAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getAppServiceCertificateOrder() { console.log(result); } -getAppServiceCertificateOrder().catch(console.error); +async function main() { + getAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListByResourceGroupSample.ts index faa619a08286..313779edd359 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get certificate orders in a resource group. * * @summary Description for Get certificate orders in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json */ async function listAppServiceCertificateOrdersByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listAppServiceCertificateOrdersByResourceGroup() { console.log(resArray); } -listAppServiceCertificateOrdersByResourceGroup().catch(console.error); +async function main() { + listAppServiceCertificateOrdersByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListCertificatesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListCertificatesSample.ts index 95906b80949d..69e1cd47adc4 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListCertificatesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListCertificatesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all certificates associated with a certificate order. * * @summary Description for List all certificates associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListCertificatesByAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListCertificatesByAppServiceCertificateOrder.json */ async function listCertificatesByAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listCertificatesByAppServiceCertificate() { console.log(resArray); } -listCertificatesByAppServiceCertificate().catch(console.error); +async function main() { + listCertificatesByAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListSample.ts index 5a98b07d23b9..47774c306cc1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all certificate orders in a subscription. * * @summary Description for List all certificate orders in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersBySubscription.json */ async function listAppServiceCertificateOrdersBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listAppServiceCertificateOrdersBySubscription() { console.log(resArray); } -listAppServiceCertificateOrdersBySubscription().catch(console.error); +async function main() { + listAppServiceCertificateOrdersBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersReissueSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersReissueSample.ts index cba9fe28aff1..2a1649d30b74 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersReissueSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersReissueSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Reissue an existing certificate order. * * @summary Description for Reissue an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ReissueAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ReissueAppServiceCertificateOrder.json */ async function reissueAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const reissueCertificateOrderRequest: ReissueCertificateOrderRequest = { csr: "CSR1223238Value", @@ -40,4 +46,8 @@ async function reissueAppServiceCertificateOrder() { console.log(result); } -reissueAppServiceCertificateOrder().catch(console.error); +async function main() { + reissueAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRenewSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRenewSample.ts index eacf061fd3bf..7f1f6bf78321 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRenewSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRenewSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Renew an existing certificate order. * * @summary Description for Renew an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RenewAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RenewAppServiceCertificateOrder.json */ async function renewAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const renewCertificateOrderRequest: RenewCertificateOrderRequest = { csr: "CSR1223238Value", @@ -39,4 +45,8 @@ async function renewAppServiceCertificateOrder() { console.log(result); } -renewAppServiceCertificateOrder().catch(console.error); +async function main() { + renewAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendEmailSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendEmailSample.ts index b17e990400e1..2bed7e6e7dc3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendEmailSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendEmailSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Resend certificate email. * * @summary Description for Resend certificate email. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendAppServiceCertificateOrderEmail.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendAppServiceCertificateOrderEmail.json */ async function resendAppServiceCertificateOrderEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function resendAppServiceCertificateOrderEmail() { console.log(result); } -resendAppServiceCertificateOrderEmail().catch(console.error); +async function main() { + resendAppServiceCertificateOrderEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendRequestEmailsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendRequestEmailsSample.ts index b4fbc327641a..410878d361f0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendRequestEmailsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersResendRequestEmailsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { NameIdentifier, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order * * @summary Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendDomainOwnershipVerificationEmail.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendDomainOwnershipVerificationEmail.json */ async function resendDomainOwnershipVerificationEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const nameIdentifier: NameIdentifier = { name: "Domain name" }; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function resendDomainOwnershipVerificationEmail() { console.log(result); } -resendDomainOwnershipVerificationEmail().catch(console.error); +async function main() { + resendDomainOwnershipVerificationEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts index 1143dede767a..ec2a839de825 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Retrieve the list of certificate actions. * * @summary Description for Retrieve the list of certificate actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateOrderActions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateOrderActions.json */ async function retrieveCertificateOrderActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleCertOrder"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function retrieveCertificateOrderActions() { console.log(result); } -retrieveCertificateOrderActions().catch(console.error); +async function main() { + retrieveCertificateOrderActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts index b1a4c766512a..f1fbb9d74af3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Retrieve email history. * * @summary Description for Retrieve email history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateEmailHistory.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateEmailHistory.json */ async function retrieveCertificateEmailHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleCertOrder"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function retrieveCertificateEmailHistory() { console.log(result); } -retrieveCertificateEmailHistory().catch(console.error); +async function main() { + retrieveCertificateEmailHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveSiteSealSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveSiteSealSample.ts index 0d7db52b0fe6..aea65a1d6d6b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveSiteSealSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersRetrieveSiteSealSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. * * @summary This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveSiteSeal.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveSiteSeal.json */ async function retrieveSiteSeal() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertOrder"; const siteSealRequest: SiteSealRequest = { lightTheme: true, @@ -38,4 +44,8 @@ async function retrieveSiteSeal() { console.log(result); } -retrieveSiteSeal().catch(console.error); +async function main() { + retrieveSiteSeal(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateCertificateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateCertificateSample.ts index 1c706b2e95b5..a1da6f0cb4cb 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateCertificateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificate.json */ async function updateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate: AppServiceCertificatePatchResource = { @@ -41,4 +47,8 @@ async function updateCertificate() { console.log(result); } -updateCertificate().catch(console.error); +async function main() { + updateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateSample.ts index 4dd2967027c4..4687c83e3651 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificateOrder.json */ async function updateCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName: AppServiceCertificateOrderPatchResource = { autoRenew: true, @@ -53,4 +59,8 @@ async function updateCertificateOrder() { console.log(result); } -updateCertificateOrder().catch(console.error); +async function main() { + updateCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersValidatePurchaseInformationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersValidatePurchaseInformationSample.ts index a984eb8d27a4..b750acdaa5c0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersValidatePurchaseInformationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersValidatePurchaseInformationSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Validate information for a certificate order. * * @summary Description for Validate information for a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json */ async function validateAppServiceCertificatePurchaseInformationBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const appServiceCertificateOrder: AppServiceCertificateOrder = { autoRenew: true, certificates: { @@ -50,6 +55,8 @@ async function validateAppServiceCertificatePurchaseInformationBySubscription() console.log(result); } -validateAppServiceCertificatePurchaseInformationBySubscription().catch( - console.error -); +async function main() { + validateAppServiceCertificatePurchaseInformationBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts index 1c6edd6b3c15..09f9649b69ec 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Verify domain ownership for this certificate order. * * @summary Description for Verify domain ownership for this certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/VerifyDomainOwnership.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/VerifyDomainOwnership.json */ async function verifyDomainOwnership() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function verifyDomainOwnership() { console.log(result); } -verifyDomainOwnership().catch(console.error); +async function main() { + verifyDomainOwnership(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts index 2bd1f6456589..41e7232b0bc9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -42,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnection() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnection().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsChangeVnetSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsChangeVnetSample.ts index 2d21f0f74ba0..7c68a5cd34ae 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsChangeVnetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsChangeVnetSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Move an App Service Environment to a different VNET. * * @summary Description for Move an App Service Environment to a different VNET. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ChangeVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ChangeVnet.json */ async function moveAnAppServiceEnvironmentToADifferentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const vnetInfo: VirtualNetworkProfile = { id: @@ -41,4 +47,8 @@ async function moveAnAppServiceEnvironmentToADifferentVnet() { console.log(resArray); } -moveAnAppServiceEnvironmentToADifferentVnet().catch(console.error); +async function main() { + moveAnAppServiceEnvironmentToADifferentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts index ac835dae20ff..3184f29c330f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a multi-role pool. * * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json */ async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const multiRolePoolEnvelope: WorkerPoolResource = { workerCount: 3, @@ -38,4 +44,8 @@ async function createOrUpdateAMultiRolePool() { console.log(result); } -createOrUpdateAMultiRolePool().catch(console.error); +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateSample.ts index a7dde7c05402..e9ed5ac17811 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdate.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope: AppServiceEnvironmentResource = { kind: "Asev3", @@ -42,4 +48,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts index b517ffc6b617..5ba2fa250fa7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a worker pool. * * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json */ async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const workerPoolEnvelope: WorkerPoolResource = { @@ -40,4 +46,8 @@ async function getPropertiesOfAWorkerPool() { console.log(result); } -getPropertiesOfAWorkerPool().catch(console.error); +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts index 5aa3d488ea60..2d3cba0b2dd3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Delete Custom Dns Suffix configuration of an App Service Environment * * @summary Delete Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAseCustomDnsSuffixConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAseCustomDnsSuffixConfiguration.json */ async function deleteAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function deleteAseCustomDnsSuffixConfiguration() { console.log(result); } -deleteAseCustomDnsSuffixConfiguration().catch(console.error); +async function main() { + deleteAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts index 6dd37e3b671a..b740a212c515 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json */ async function deletesAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function deletesAPrivateEndpointConnection() { console.log(result); } -deletesAPrivateEndpointConnection().catch(console.error); +async function main() { + deletesAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteSample.ts index 2a7bc6bf6b8a..ff955f26b1e9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsDeleteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete an App Service Environment. * * @summary Description for Delete an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Delete.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Delete.json */ async function deleteAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function deleteAnAppServiceEnvironment() { console.log(result); } -deleteAnAppServiceEnvironment().catch(console.error); +async function main() { + deleteAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts index a60b12cfaec7..994754b73915 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get Custom Dns Suffix configuration of an App Service Environment * * @summary Get Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAseCustomDnsSuffixConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAseCustomDnsSuffixConfiguration.json */ async function getAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getAseCustomDnsSuffixConfiguration() { console.log(result); } -getAseCustomDnsSuffixConfiguration().catch(console.error); +async function main() { + getAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts index abb594d4e517..41b5c16efc24 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get networking configuration of an App Service Environment * * @summary Description for Get networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json */ async function getNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getNetworkingConfigurationOfAnAppServiceEnvironment() { console.log(result); } -getNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetDiagnosticsItemSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetDiagnosticsItemSample.ts index 7c19a75a6d24..77eab217ef94 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetDiagnosticsItemSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetDiagnosticsItemSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get a diagnostics item for an App Service Environment. * * @summary Description for Get a diagnostics item for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json */ async function getADiagnosticsItemForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const diagnosticsName = "test-diagnostic"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getADiagnosticsItemForAnAppServiceEnvironment() { console.log(result); } -getADiagnosticsItemForAnAppServiceEnvironment().catch(console.error); +async function main() { + getADiagnosticsItemForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts index c4ae05e3e12e..9e159d846f0c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the network endpoints of all inbound dependencies of an App Service Environment. * * @summary Description for Get the network endpoints of all inbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetInboundNetworkDependenciesEndpoints.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetInboundNetworkDependenciesEndpoints.json */ async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const name = "SampleAse"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvir console.log(resArray); } -getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetMultiRolePoolSample.ts index ff5e4d6c07ff..6bcf465e1524 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetMultiRolePoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetMultiRolePoolSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get properties of a multi-role pool. * * @summary Description for Get properties of a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetMultiRolePool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetMultiRolePool.json */ async function getPropertiesOfAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getPropertiesOfAMultiRolePool() { console.log(result); } -getPropertiesOfAMultiRolePool().catch(console.error); +async function main() { + getPropertiesOfAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts index e95bec416a4a..8abf6a516823 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the network endpoints of all outbound dependencies of an App Service Environment. * * @summary Description for Get the network endpoints of all outbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetOutboundNetworkDependenciesEndpoints.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetOutboundNetworkDependenciesEndpoints.json */ async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const name = "SampleAse"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvi console.log(resArray); } -getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts index de27aa0cfddc..f3d76232323e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the list of private endpoints associated with a hosting environment * * @summary Description for Gets the list of private endpoints associated with a hosting environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json */ async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() console.log(resArray); } -getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment().catch( - console.error -); +async function main() { + getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts index f5b01f9b52a2..9e9041015f5c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a private endpoint connection * * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json */ async function getsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getsAPrivateEndpointConnection() { console.log(result); } -getsAPrivateEndpointConnection().catch(console.error); +async function main() { + getsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts index 558fc46ad940..065c95489ea6 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the private link resources * * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json */ async function getsThePrivateLinkResources() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getsThePrivateLinkResources() { console.log(result); } -getsThePrivateLinkResources().catch(console.error); +async function main() { + getsThePrivateLinkResources(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetSample.ts index 60243a81a093..583df5bbfc8d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the properties of an App Service Environment. * * @summary Description for Get the properties of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Get.json */ async function getThePropertiesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getThePropertiesOfAnAppServiceEnvironment() { console.log(result); } -getThePropertiesOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getThePropertiesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetVipInfoSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetVipInfoSample.ts index c80c30e4184b..bb6be66e1646 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetVipInfoSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetVipInfoSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get IP addresses assigned to an App Service Environment. * * @summary Description for Get IP addresses assigned to an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetVipInfo.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetVipInfo.json */ async function getIPAddressesAssignedToAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getIPAddressesAssignedToAnAppServiceEnvironment() { console.log(result); } -getIPAddressesAssignedToAnAppServiceEnvironment().catch(console.error); +async function main() { + getIPAddressesAssignedToAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetWorkerPoolSample.ts index 4e010a7a5c47..bd8eb507c722 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetWorkerPoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsGetWorkerPoolSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get properties of a worker pool. * * @summary Description for Get properties of a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetWorkerPool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetWorkerPool.json */ async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "workerPool1"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getPropertiesOfAWorkerPool() { console.log(result); } -getPropertiesOfAWorkerPool().catch(console.error); +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListAppServicePlansSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListAppServicePlansSample.ts index acdd6375b53e..e11c666799d7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListAppServicePlansSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListAppServicePlansSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service plans in an App Service Environment. * * @summary Description for Get all App Service plans in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListAppServicePlans.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListAppServicePlans.json */ async function getAllAppServicePlansInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAllAppServicePlansInAnAppServiceEnvironment() { console.log(resArray); } -getAllAppServicePlansInAnAppServiceEnvironment().catch(console.error); +async function main() { + getAllAppServicePlansInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListByResourceGroupSample.ts index b88e9b7c10fe..f565c82b26b2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service Environments in a resource group. * * @summary Description for Get all App Service Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListByResourceGroup.json */ async function getAllAppServiceEnvironmentsInAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function getAllAppServiceEnvironmentsInAResourceGroup() { console.log(resArray); } -getAllAppServiceEnvironmentsInAResourceGroup().catch(console.error); +async function main() { + getAllAppServiceEnvironmentsInAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListCapacitiesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListCapacitiesSample.ts index 1ab10666b97c..d397ae9b18d9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListCapacitiesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListCapacitiesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the used, available, and total worker capacity an App Service Environment. * * @summary Description for Get the used, available, and total worker capacity an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListCapacities.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListCapacities.json */ async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment( console.log(resArray); } -getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListDiagnosticsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListDiagnosticsSample.ts index f803e6d7e70e..e197b7e8cb0f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListDiagnosticsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListDiagnosticsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get diagnostic information for an App Service Environment. * * @summary Description for Get diagnostic information for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListDiagnostics.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListDiagnostics.json */ async function getDiagnosticInformationForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getDiagnosticInformationForAnAppServiceEnvironment() { console.log(result); } -getDiagnosticInformationForAnAppServiceEnvironment().catch(console.error); +async function main() { + getDiagnosticInformationForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts index 0f6e3eb42940..4ec594b6850b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get metric definitions for a multi-role pool of an App Service Environment. * * @summary Description for Get metric definitions for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json */ async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() console.log(resArray); } -getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts index 1631c1ac8891..650781118656 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. * * @summary Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json */ async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const instance = "10.7.1.8"; const credential = new DefaultAzureCredential(); @@ -35,6 +41,8 @@ async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppSe console.log(resArray); } -getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolSkusSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolSkusSample.ts index 3575848be4f5..1f1530433615 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolSkusSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolSkusSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available SKUs for scaling a multi-role pool. * * @summary Description for Get available SKUs for scaling a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json */ async function getAvailableSkUsForScalingAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAvailableSkUsForScalingAMultiRolePool() { console.log(resArray); } -getAvailableSkUsForScalingAMultiRolePool().catch(console.error); +async function main() { + getAvailableSkUsForScalingAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolsSample.ts index dc8e63bd4e57..be8974e3f889 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRolePoolsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all multi-role pools. * * @summary Description for Get all multi-role pools. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePools.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePools.json */ async function getAllMultiRolePools() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAllMultiRolePools() { console.log(resArray); } -getAllMultiRolePools().catch(console.error); +async function main() { + getAllMultiRolePools(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleUsagesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleUsagesSample.ts index 171289ebb5ae..51025f1b6bf3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleUsagesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListMultiRoleUsagesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get usage metrics for a multi-role pool of an App Service Environment. * * @summary Description for Get usage metrics for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json */ async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +39,8 @@ async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { console.log(resArray); } -getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListOperationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListOperationsSample.ts index 2bbe9293b348..3ad10b91b6f1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListOperationsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all currently running operations on the App Service Environment. * * @summary Description for List all currently running operations on the App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListOperations.json */ async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,6 +36,8 @@ async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { console.log(result); } -listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment().catch( - console.error -); +async function main() { + listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListSample.ts index 5e410501d081..16624930c453 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service Environments for a subscription. * * @summary Description for Get all App Service Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_List.json */ async function getAllAppServiceEnvironmentsForASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getAllAppServiceEnvironmentsForASubscription() { console.log(resArray); } -getAllAppServiceEnvironmentsForASubscription().catch(console.error); +async function main() { + getAllAppServiceEnvironmentsForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListUsagesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListUsagesSample.ts index 420a41c37423..d2ad7d985d10 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListUsagesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListUsagesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get global usage metrics of an App Service Environment. * * @summary Description for Get global usage metrics of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListUsages.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListUsages.json */ async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { console.log(resArray); } -getGlobalUsageMetricsOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getGlobalUsageMetricsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebAppsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebAppsSample.ts index e8c539235e3d..39204abedcfa 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebAppsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebAppsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all apps in an App Service Environment. * * @summary Description for Get all apps in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebApps.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebApps.json */ async function getAllAppsInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAllAppsInAnAppServiceEnvironment() { console.log(resArray); } -getAllAppsInAnAppServiceEnvironment().catch(console.error); +async function main() { + getAllAppsInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts index f7762e4002eb..b7c49fb44795 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get metric definitions for a worker pool of an App Service Environment. * * @summary Description for Get metric definitions for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json */ async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const credential = new DefaultAzureCredential(); @@ -35,6 +41,8 @@ async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { console.log(resArray); } -getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerUsagesSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerUsagesSample.ts index 2f5e4f03b531..d8093ba6adeb 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerUsagesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWebWorkerUsagesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get usage metrics for a worker pool of an App Service Environment. * * @summary Description for Get usage metrics for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json */ async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { console.log(resArray); } -getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts index 6697e0aa9403..61b0338538d3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. * * @summary Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json */ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const instance = "10.8.0.7"; @@ -37,6 +43,8 @@ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServi console.log(resArray); } -getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolSkusSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolSkusSample.ts index d4e9f1ba2453..2e38ec565fdd 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolSkusSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolSkusSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available SKUs for scaling a worker pool. * * @summary Description for Get available SKUs for scaling a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json */ async function getAvailableSkUsForScalingAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "workerPool1"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function getAvailableSkUsForScalingAWorkerPool() { console.log(resArray); } -getAvailableSkUsForScalingAWorkerPool().catch(console.error); +async function main() { + getAvailableSkUsForScalingAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolsSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolsSample.ts index a6dfb8486625..d906f74d8c51 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsListWorkerPoolsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all worker pools of an App Service Environment. * * @summary Description for Get all worker pools of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPools.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPools.json */ async function getAllWorkerPoolsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAllWorkerPoolsOfAnAppServiceEnvironment() { console.log(resArray); } -getAllWorkerPoolsOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getAllWorkerPoolsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsRebootSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsRebootSample.ts index e4ad77bca460..c786376320bf 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsRebootSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsRebootSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Reboot all machines in an App Service Environment. * * @summary Description for Reboot all machines in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Reboot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Reboot.json */ async function rebootAllMachinesInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function rebootAllMachinesInAnAppServiceEnvironment() { console.log(result); } -rebootAllMachinesInAnAppServiceEnvironment().catch(console.error); +async function main() { + rebootAllMachinesInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsResumeSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsResumeSample.ts index 221ff4fd9143..7995dd0456fe 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsResumeSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsResumeSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Resume an App Service Environment. * * @summary Description for Resume an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Resume.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Resume.json */ async function resumeAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function resumeAnAppServiceEnvironment() { console.log(resArray); } -resumeAnAppServiceEnvironment().catch(console.error); +async function main() { + resumeAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsSuspendSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsSuspendSample.ts index 4ebd9fa3aa92..b28d3d301e41 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsSuspendSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsSuspendSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Suspend an App Service Environment. * * @summary Description for Suspend an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Suspend.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Suspend.json */ async function suspendAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function suspendAnAppServiceEnvironment() { console.log(resArray); } -suspendAnAppServiceEnvironment().catch(console.error); +async function main() { + suspendAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts index 1d98f0b54e76..1a1f089c0778 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Send a test notification that an upgrade is available for this App Service Environment. * * @summary Send a test notification that an upgrade is available for this App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json */ async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "SampleHostingEnvironment"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,6 +35,8 @@ async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnv console.log(result); } -sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment().catch( - console.error -); +async function main() { + sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts index 54b0e2024f3c..33437097e47a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Update Custom Dns Suffix configuration of an App Service Environment * * @summary Update Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateAseCustomDnsSuffixConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAseCustomDnsSuffixConfiguration.json */ async function updateAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const customDnsSuffixConfiguration: CustomDnsSuffixConfiguration = { certificateUrl: "https://test-kv.vault.azure.net/secrets/contosocert", @@ -40,4 +46,8 @@ async function updateAseCustomDnsSuffixConfiguration() { console.log(result); } -updateAseCustomDnsSuffixConfiguration().catch(console.error); +async function main() { + updateAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts index 4cd7f88e627e..d96aa7f6a9a9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Update networking configuration of an App Service Environment * * @summary Description for Update networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json */ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const aseNetworkingConfiguration: AseV3NetworkingConfiguration = { ftpEnabled: true, @@ -38,4 +44,8 @@ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { console.log(result); } -updateNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); +async function main() { + updateNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateMultiRolePoolSample.ts index 0406015f59c3..dbe7d698c5ec 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateMultiRolePoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateMultiRolePoolSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a multi-role pool. * * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json */ async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const multiRolePoolEnvelope: WorkerPoolResource = { workerCount: 3, @@ -38,4 +44,8 @@ async function createOrUpdateAMultiRolePool() { console.log(result); } -createOrUpdateAMultiRolePool().catch(console.error); +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateSample.ts index 1a8f72443296..608f7aadb0bc 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Update.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Update.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope: AppServiceEnvironmentPatchResource = { frontEndScaleFactor: 20, @@ -41,4 +47,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateWorkerPoolSample.ts index 81fb6bd24298..d5bae2349dc9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateWorkerPoolSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpdateWorkerPoolSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a worker pool. * * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json */ async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const workerPoolEnvelope: WorkerPoolResource = { @@ -40,4 +46,8 @@ async function getPropertiesOfAWorkerPool() { console.log(result); } -getPropertiesOfAWorkerPool().catch(console.error); +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpgradeSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpgradeSample.ts index 50f5379e1e73..3837caacf86b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpgradeSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServiceEnvironmentsUpgradeSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Initiate an upgrade of an App Service Environment if one is available. * * @summary Description for Initiate an upgrade of an App Service Environment if one is available. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Upgrade.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Upgrade.json */ async function initiateAnUpgradeOnAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "SampleHostingEnvironment"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function initiateAnUpgradeOnAnAppServiceEnvironment() { console.log(result); } -initiateAnUpgradeOnAnAppServiceEnvironment().catch(console.error); +async function main() { + initiateAnUpgradeOnAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansCreateOrUpdateSample.ts index 2d8beab309d0..f370294e600b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansCreateOrUpdateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { AppServicePlan, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates an App Service Plan. * * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateAppServicePlan.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateAppServicePlan.json */ async function createOrUpdateAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsf6141"; const appServicePlan: AppServicePlan = { kind: "app", @@ -36,4 +42,8 @@ async function createOrUpdateAppServicePlan() { console.log(result); } -createOrUpdateAppServicePlan().catch(console.error); +async function main() { + createOrUpdateAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansDeleteSample.ts index 3facd811971c..84dce044b637 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansDeleteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete an App Service plan. * * @summary Description for Delete an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAppServicePlan.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAppServicePlan.json */ async function deleteAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsf6141"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function deleteAppServicePlan() { console.log(result); } -deleteAppServicePlan().catch(console.error); +async function main() { + deleteAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansGetSample.ts index 30078a70fedc..a50b975f8415 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get an App Service plan. * * @summary Description for Get an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAppServicePlan.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAppServicePlan.json */ async function getAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsf6141"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function getAppServicePlan() { console.log(result); } -getAppServicePlan().catch(console.error); +async function main() { + getAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansListByResourceGroupSample.ts index 3f0e99b140a5..4ba752300f06 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service plans in a resource group. * * @summary Description for Get all App Service plans in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlansByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlansByResourceGroup.json */ async function listAppServicePlansByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listAppServicePlansByResourceGroup() { console.log(resArray); } -listAppServicePlansByResourceGroup().catch(console.error); +async function main() { + listAppServicePlansByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansListSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansListSample.ts index 2048e93e1a8e..5dfb0204cc4f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service plans for a subscription. * * @summary Description for Get all App Service plans for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlans.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlans.json */ async function listAppServicePlans() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listAppServicePlans() { console.log(resArray); } -listAppServicePlans().catch(console.error); +async function main() { + listAppServicePlans(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/appServicePlansUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/appServicePlansUpdateSample.ts index bdaa4bc3a512..33f8e46b416b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/appServicePlansUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/appServicePlansUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates an App Service Plan. * * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchAppServicePlan.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchAppServicePlan.json */ async function patchServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsf6141"; const appServicePlan: AppServicePlanPatchResource = { kind: "app" }; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function patchServicePlan() { console.log(result); } -patchServicePlan().catch(console.error); +async function main() { + patchServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts index 36237e628535..c4b15f388a91 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. * * @summary Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json */ async function getAppServiceCertificateOrderDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const certificateOrderName = "SampleCertificateOrderName"; const detectorName = "AutoRenewStatus"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getAppServiceCertificateOrderDetectorResponse() { console.log(result); } -getAppServiceCertificateOrderDetectorResponse().catch(console.error); +async function main() { + getAppServiceCertificateOrderDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts index dda6b6ce756b..2edccd224880 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. * * @summary Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json */ async function listAppServiceCertificateDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listAppServiceCertificateDetectorResponse() { console.log(resArray); } -listAppServiceCertificateDetectorResponse().catch(console.error); +async function main() { + listAppServiceCertificateDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificateRegistrationProviderListOperationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificateRegistrationProviderListOperationsSample.ts index f819a6a640df..b62002afacf8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificateRegistrationProviderListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificateRegistrationProviderListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesCreateOrUpdateSample.ts index a0f8eb601720..97b5ef924329 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesCreateOrUpdateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { Certificate, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate. * * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateCertificate.json */ async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const certificateEnvelope: Certificate = { hostNames: ["ServerCert"], @@ -36,4 +42,8 @@ async function createOrUpdateCertificate() { console.log(result); } -createOrUpdateCertificate().catch(console.error); +async function main() { + createOrUpdateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesDeleteSample.ts index 49b858c2b590..d344f9959c79 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesDeleteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete a certificate. * * @summary Description for Delete a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteCertificate.json */ async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function deleteCertificate() { console.log(result); } -deleteCertificate().catch(console.error); +async function main() { + deleteCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesGetSample.ts index 3637ec2347da..d952721a7349 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get a certificate. * * @summary Description for Get a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetCertificate.json */ async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function getCertificate() { console.log(result); } -getCertificate().catch(console.error); +async function main() { + getCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesListByResourceGroupSample.ts index 4ee4118926e6..6f25e8c28e31 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all certificates in a resource group. * * @summary Description for Get all certificates in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificatesByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificatesByResourceGroup.json */ async function listCertificatesByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listCertificatesByResourceGroup() { console.log(resArray); } -listCertificatesByResourceGroup().catch(console.error); +async function main() { + listCertificatesByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesListSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesListSample.ts index 2fdcbc3b6206..64769c9de825 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all certificates for a subscription. * * @summary Description for Get all certificates for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificates.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificates.json */ async function listCertificatesForSubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listCertificatesForSubscription() { console.log(resArray); } -listCertificatesForSubscription().catch(console.error); +async function main() { + listCertificatesForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/certificatesUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/certificatesUpdateSample.ts index 15d05398ce1c..c82ed000398f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/certificatesUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/certificatesUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate. * * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchCertificate.json */ async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const certificateEnvelope: CertificatePatchResource = { password: "" @@ -37,4 +43,8 @@ async function patchCertificate() { console.log(result); } -patchCertificate().catch(console.error); +async function main() { + patchCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsCreateOrUpdateSample.ts index dfaef18bf1f5..1a2458c7324b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsCreateOrUpdateSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { ContainerApp, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a Container App. * * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateContainerApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateContainerApp.json */ async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testcontainerApp0"; const containerAppEnvelope: ContainerApp = { configuration: { ingress: { external: true, targetPort: 3000 } }, @@ -54,4 +59,8 @@ async function createOrUpdateContainerApp() { console.log(result); } -createOrUpdateContainerApp().catch(console.error); +async function main() { + createOrUpdateContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsDeleteSample.ts index a35dda53d7df..2e367e589fe1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsDeleteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete a Container App. * * @summary Description for Delete a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteContainerApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteContainerApp.json */ async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testWorkerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function deleteContainerApp() { console.log(result); } -deleteContainerApp().catch(console.error); +async function main() { + deleteContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsGetSample.ts index 4df67104b01e..53f5820dd6fa 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsGetSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the properties of a Container App. * * @summary Get the properties of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetContainerApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetContainerApp.json */ async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testcontainerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +32,8 @@ async function getContainerApp() { console.log(result); } -getContainerApp().catch(console.error); +async function main() { + getContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsListByResourceGroupSample.ts index b48bcdc9a867..112643122573 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsListByResourceGroupSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the Container Apps in a given resource group. * * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsByResourceGroup.json */ async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +36,8 @@ async function listContainerAppsByResourceGroup() { console.log(resArray); } -listContainerAppsByResourceGroup().catch(console.error); +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsListBySubscriptionSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsListBySubscriptionSample.ts index f66567943df3..a16c56377452 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsListBySubscriptionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsListBySubscriptionSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the Container Apps in a given subscription. * * @summary Get the Container Apps in a given subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsBySubscription.json */ async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listContainerAppsByResourceGroup() { console.log(resArray); } -listContainerAppsByResourceGroup().catch(console.error); +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsListSecretsSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsListSecretsSample.ts index 649f71d6593c..a8b3196ca30e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsListSecretsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsListSecretsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List secrets for a container app * * @summary List secrets for a container app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppSecrets.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppSecrets.json */ async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "testcontainerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function listContainerAppsSecrets() { console.log(result); } -listContainerAppsSecrets().catch(console.error); +async function main() { + listContainerAppsSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsActivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsActivateRevisionSample.ts index 1dd4ee90c9a2..e70c650b422c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsActivateRevisionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsActivateRevisionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Activates a revision for a Container App * * @summary Activates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ActivateRevision.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ActivateRevision.json */ async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testcontainerApp0"; const name = "testcontainerApp0-pjxhsye"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function activateContainerAppRevision() { console.log(result); } -activateContainerAppRevision().catch(console.error); +async function main() { + activateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts index 5d4bcd195a09..4e8ae11e6b28 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Deactivates a revision for a Container App * * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeactivateRevision.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeactivateRevision.json */ async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testcontainerApp0"; const name = "testcontainerApp0-pjxhsye"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function deactivateContainerAppRevision() { console.log(result); } -deactivateContainerAppRevision().catch(console.error); +async function main() { + deactivateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsGetRevisionSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsGetRevisionSample.ts index 1d7a151ffc1a..b09856b13f67 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsGetRevisionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsGetRevisionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get a revision of a Container App. * * @summary Get a revision of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetRevision.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetRevision.json */ async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testcontainerApp0"; const name = "testcontainerApp0-pjxhsye"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getContainerAppRevision() { console.log(result); } -getContainerAppRevision().catch(console.error); +async function main() { + getContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsListRevisionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsListRevisionsSample.ts index 0fa4a0b7a35e..ed67075ee49b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsListRevisionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsListRevisionsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the Revisions for a given Container App. * * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListRevisions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListRevisions.json */ async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testcontainerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function listContainerAppRevisions() { console.log(resArray); } -listContainerAppRevisions().catch(console.error); +async function main() { + listContainerAppRevisions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsRestartRevisionSample.ts b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsRestartRevisionSample.ts index 663297ced72a..b06d53d8fbf2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsRestartRevisionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/containerAppsRevisionsRestartRevisionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Restarts a revision for a Container App * * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RestartRevision.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestartRevision.json */ async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testStaticSite0"; const name = "testcontainerApp0-pjxhsye"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function restartContainerAppRevision() { console.log(result); } -restartContainerAppRevision().catch(console.error); +async function main() { + restartContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsGetDeletedWebAppByLocationSample.ts b/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsGetDeletedWebAppByLocationSample.ts index 53867240e106..8f558733cb54 100644 --- a/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsGetDeletedWebAppByLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsGetDeletedWebAppByLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription at location. * * @summary Description for Get deleted app for a subscription at location. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppByLocation.json */ async function getDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); @@ -30,4 +35,8 @@ async function getDeletedWebAppByLocation() { console.log(result); } -getDeletedWebAppByLocation().catch(console.error); +async function main() { + getDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsListByLocationSample.ts b/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsListByLocationSample.ts index ced0e45e7206..964957c76d00 100644 --- a/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsListByLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/deletedWebAppsListByLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription at location * * @summary Description for Get all deleted apps for a subscription at location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListDeletedWebAppsByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListDeletedWebAppsByLocation.json */ async function listDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -29,4 +34,8 @@ async function listDeletedWebAppByLocation() { console.log(resArray); } -listDeletedWebAppByLocation().catch(console.error); +async function main() { + listDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSample.ts index c009048641ad..e103753648ae 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Execute Analysis * * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json */ async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "apprestartanalyses"; @@ -34,17 +40,18 @@ async function executeSiteAnalysis() { console.log(result); } -executeSiteAnalysis().catch(console.error); - /** * This sample demonstrates how to Description for Execute Analysis * * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json */ async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "apprestartanalyses"; @@ -59,4 +66,9 @@ async function executeSiteSlotAnalysis() { console.log(result); } -executeSiteSlotAnalysis().catch(console.error); +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSlotSample.ts index bded91e0ec9b..44008363f0de 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteAnalysisSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Execute Analysis * * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json */ async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "apprestartanalyses"; @@ -36,17 +42,18 @@ async function executeSiteAnalysis() { console.log(result); } -executeSiteAnalysis().catch(console.error); - /** * This sample demonstrates how to Description for Execute Analysis * * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json */ async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "apprestartanalyses"; @@ -63,4 +70,9 @@ async function executeSiteSlotAnalysis() { console.log(result); } -executeSiteSlotAnalysis().catch(console.error); +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSample.ts index 57305c0d84a4..9193b07f48b6 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Execute Detector * * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json */ async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "sitecrashes"; const diagnosticCategory = "availability"; @@ -34,17 +40,18 @@ async function executeSiteDetector() { console.log(result); } -executeSiteDetector().catch(console.error); - /** * This sample demonstrates how to Description for Execute Detector * * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json */ async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "sitecrashes"; const diagnosticCategory = "availability"; @@ -59,4 +66,9 @@ async function executeSiteSlotDetector() { console.log(result); } -executeSiteSlotDetector().catch(console.error); +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSlotSample.ts index e9f4345635d7..b40ac8a10a1e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsExecuteSiteDetectorSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Execute Detector * * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json */ async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "sitecrashes"; const diagnosticCategory = "availability"; @@ -36,17 +42,18 @@ async function executeSiteDetector() { console.log(result); } -executeSiteDetector().catch(console.error); - /** * This sample demonstrates how to Description for Execute Detector * * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json */ async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "sitecrashes"; const diagnosticCategory = "availability"; @@ -63,4 +70,9 @@ async function executeSiteSlotDetector() { console.log(result); } -executeSiteSlotDetector().catch(console.error); +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts index 7101af65c759..830503b5703a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Hosting Environment Detector Response * * @summary Description for Get Hosting Environment Detector Response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json */ async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const name = "SampleAppServiceEnvironment"; const detectorName = "runtimeavailability"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getAppServiceEnvironmentDetectorResponses() { console.log(result); } -getAppServiceEnvironmentDetectorResponses().catch(console.error); +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSample.ts index f8d788e342b9..bc35ed7dbcfe 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Site Analysis * * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json */ async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "appanalysis"; @@ -34,17 +40,18 @@ async function getAppAnalysis() { console.log(result); } -getAppAnalysis().catch(console.error); - /** * This sample demonstrates how to Description for Get Site Analysis * * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json */ async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "appanalysis"; @@ -59,4 +66,9 @@ async function getAppSlotAnalysis() { console.log(result); } -getAppSlotAnalysis().catch(console.error); +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSlotSample.ts index f43fe7e64755..286a4f23df49 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteAnalysisSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Site Analysis * * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json */ async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "appanalysis"; @@ -36,17 +42,18 @@ async function getAppAnalysis() { console.log(result); } -getAppAnalysis().catch(console.error); - /** * This sample demonstrates how to Description for Get Site Analysis * * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json */ async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const analysisName = "appanalysis"; @@ -63,4 +70,9 @@ async function getAppSlotAnalysis() { console.log(result); } -getAppSlotAnalysis().catch(console.error); +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSample.ts index 47add308da01..5c496b49cfb8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get site detector response * * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json */ async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "runtimeavailability"; const credential = new DefaultAzureCredential(); @@ -32,17 +38,18 @@ async function getAppDetectorResponse() { console.log(result); } -getAppDetectorResponse().catch(console.error); - /** * This sample demonstrates how to Description for Get site detector response * * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json */ async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "runtimeavailability"; const credential = new DefaultAzureCredential(); @@ -55,4 +62,9 @@ async function getAppSlotDetectorResponse() { console.log(result); } -getAppSlotDetectorResponse().catch(console.error); +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSlotSample.ts index c0541318f24a..64249140317d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorResponseSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get site detector response * * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json */ async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "runtimeavailability"; const slot = "staging"; @@ -34,17 +40,18 @@ async function getAppDetectorResponse() { console.log(result); } -getAppDetectorResponse().catch(console.error); - /** * This sample demonstrates how to Description for Get site detector response * * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json */ async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const detectorName = "runtimeavailability"; const slot = "staging"; @@ -59,4 +66,9 @@ async function getAppSlotDetectorResponse() { console.log(result); } -getAppSlotDetectorResponse().catch(console.error); +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSample.ts index 0c2f9aec5e29..70681221411a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Detector * * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json */ async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const detectorName = "sitecrashes"; @@ -34,17 +40,18 @@ async function getAppDetector() { console.log(result); } -getAppDetector().catch(console.error); - /** * This sample demonstrates how to Description for Get Detector * * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json */ async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const detectorName = "sitecrashes"; @@ -59,4 +66,9 @@ async function getAppSlotDetector() { console.log(result); } -getAppSlotDetector().catch(console.error); +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSlotSample.ts index 766708da352d..adfa8d5fa501 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDetectorSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Detector * * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json */ async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const detectorName = "sitecrashes"; @@ -36,17 +42,18 @@ async function getAppDetector() { console.log(result); } -getAppDetector().catch(console.error); - /** * This sample demonstrates how to Description for Get Detector * * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json */ async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const detectorName = "sitecrashes"; @@ -63,4 +70,9 @@ async function getAppSlotDetector() { console.log(result); } -getAppSlotDetector().catch(console.error); +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySample.ts index 0070c317e483..2d5d10ecabf2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Diagnostics Category * * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json */ async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -32,17 +38,18 @@ async function getAppDiagnosticCategory() { console.log(result); } -getAppDiagnosticCategory().catch(console.error); - /** * This sample demonstrates how to Description for Get Diagnostics Category * * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json */ async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -55,4 +62,9 @@ async function getAppSlotDiagnosticCategory() { console.log(result); } -getAppSlotDiagnosticCategory().catch(console.error); +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySlotSample.ts index a931dc0d8574..8787b6ceaa42 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsGetSiteDiagnosticCategorySlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Diagnostics Category * * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json */ async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "Production"; @@ -34,17 +40,18 @@ async function getAppDiagnosticCategory() { console.log(result); } -getAppDiagnosticCategory().catch(console.error); - /** * This sample demonstrates how to Description for Get Diagnostics Category * * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json */ async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "staging"; @@ -59,4 +66,9 @@ async function getAppSlotDiagnosticCategory() { console.log(result); } -getAppSlotDiagnosticCategory().catch(console.error); +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts index cb13d9e2b40f..11f71e712676 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List Hosting Environment Detector Responses * * @summary Description for List Hosting Environment Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json */ async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const name = "SampleAppServiceEnvironment"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAppServiceEnvironmentDetectorResponses() { console.log(resArray); } -getAppServiceEnvironmentDetectorResponses().catch(console.error); +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSample.ts index a0f99d6643e0..d0bc699ffa9a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Site Analyses * * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json */ async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -35,17 +41,18 @@ async function listAppAnalyses() { console.log(resArray); } -listAppAnalyses().catch(console.error); - /** * This sample demonstrates how to Description for Get Site Analyses * * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json */ async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -61,4 +68,9 @@ async function listAppSlotAnalyses() { console.log(resArray); } -listAppSlotAnalyses().catch(console.error); +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSlotSample.ts index c2c1af3e7720..a70f6cb395ef 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteAnalysesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Site Analyses * * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json */ async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "Production"; @@ -37,17 +43,18 @@ async function listAppAnalyses() { console.log(resArray); } -listAppAnalyses().catch(console.error); - /** * This sample demonstrates how to Description for Get Site Analyses * * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json */ async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "staging"; @@ -65,4 +72,9 @@ async function listAppSlotAnalyses() { console.log(resArray); } -listAppSlotAnalyses().catch(console.error); +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSample.ts index 3eecdbe1735b..ea96e16ddd69 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List Site Detector Responses * * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json */ async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,17 +39,18 @@ async function getAppDetectorResponses() { console.log(resArray); } -getAppDetectorResponses().catch(console.error); - /** * This sample demonstrates how to Description for List Site Detector Responses * * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json */ async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -57,4 +64,9 @@ async function getAppSlotDetectorResponses() { console.log(resArray); } -getAppSlotDetectorResponses().catch(console.error); +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSlotSample.ts index 23cbf60cef97..b8aff47f81e4 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorResponsesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List Site Detector Responses * * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json */ async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -35,17 +41,18 @@ async function getAppDetectorResponses() { console.log(resArray); } -getAppDetectorResponses().catch(console.error); - /** * This sample demonstrates how to Description for List Site Detector Responses * * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json */ async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -61,4 +68,9 @@ async function getAppSlotDetectorResponses() { console.log(resArray); } -getAppSlotDetectorResponses().catch(console.error); +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSample.ts index dede03547811..12f4b3f0bdfa 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Detectors * * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json */ async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -35,17 +41,18 @@ async function listAppDetectors() { console.log(resArray); } -listAppDetectors().catch(console.error); - /** * This sample demonstrates how to Description for Get Detectors * * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json */ async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const credential = new DefaultAzureCredential(); @@ -61,4 +68,9 @@ async function listAppSlotDetectors() { console.log(resArray); } -listAppSlotDetectors().catch(console.error); +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSlotSample.ts index e152da4cb5bb..7cd1926eab3f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDetectorsSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Detectors * * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json */ async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "Production"; @@ -37,17 +43,18 @@ async function listAppDetectors() { console.log(resArray); } -listAppDetectors().catch(console.error); - /** * This sample demonstrates how to Description for Get Detectors * * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json */ async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const diagnosticCategory = "availability"; const slot = "staging"; @@ -65,4 +72,9 @@ async function listAppSlotDetectors() { console.log(resArray); } -listAppSlotDetectors().catch(console.error); +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSample.ts index 7f01863932d7..9644765ebb14 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Diagnostics Categories * * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json */ async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,17 +39,18 @@ async function listAppDiagnosticCategories() { console.log(resArray); } -listAppDiagnosticCategories().catch(console.error); - /** * This sample demonstrates how to Description for Get Diagnostics Categories * * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json */ async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -57,4 +64,9 @@ async function listAppSlotDiagnosticCategories() { console.log(resArray); } -listAppSlotDiagnosticCategories().catch(console.error); +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts index 3e9a1bc56859..d31a2c8c6844 100644 --- a/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get Diagnostics Categories * * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json */ async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -35,17 +41,18 @@ async function listAppDiagnosticCategories() { console.log(resArray); } -listAppDiagnosticCategories().catch(console.error); - /** * This sample demonstrates how to Description for Get Diagnostics Categories * * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json */ async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const siteName = "SampleApp"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -61,4 +68,9 @@ async function listAppSlotDiagnosticCategories() { console.log(resArray); } -listAppSlotDiagnosticCategories().catch(console.error); +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainRegistrationProviderListOperationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainRegistrationProviderListOperationsSample.ts index 3c33da4a6db4..be860901c655 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainRegistrationProviderListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainRegistrationProviderListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsCheckAvailabilitySample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsCheckAvailabilitySample.ts index 55978d0d7819..50d91bfe6203 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsCheckAvailabilitySample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsCheckAvailabilitySample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { NameIdentifier, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Check if a domain is available for registration. * * @summary Description for Check if a domain is available for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CheckDomainAvailability.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CheckDomainAvailability.json */ async function checkDomainAvailability() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const identifier: NameIdentifier = { name: "abcd.com" }; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function checkDomainAvailability() { console.log(result); } -checkDomainAvailability().catch(console.error); +async function main() { + checkDomainAvailability(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateOwnershipIdentifierSample.ts index 7a379e167a39..cc19d3c9a601 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateOwnershipIdentifierSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomainOwnershipIdentifier.json */ async function createAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier: DomainOwnershipIdentifier = { @@ -39,4 +45,8 @@ async function createAppServiceDomainOwnershipIdentifier() { console.log(result); } -createAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + createAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateSample.ts index 23b3e22a553e..f4613b8108c7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsCreateOrUpdateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { Domain, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomain.json */ async function createAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain: Domain = { authCode: "exampleAuthCode", @@ -112,4 +118,8 @@ async function createAppServiceDomain() { console.log(result); } -createAppServiceDomain().catch(console.error); +async function main() { + createAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsDeleteOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsDeleteOwnershipIdentifierSample.ts index 0c14275c33b2..a00779ffc024 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsDeleteOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsDeleteOwnershipIdentifierSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete ownership identifier for domain * * @summary Description for Delete ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json */ async function deleteAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "ownershipIdentifier"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function deleteAppServiceDomainOwnershipIdentifier() { console.log(result); } -deleteAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + deleteAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsDeleteSample.ts index 13fc12599025..0fef1a42c331 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsDeleteSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete a domain. * * @summary Description for Delete a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomain.json */ async function deleteAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const forceHardDeleteDomain = true; const options: DomainsDeleteOptionalParams = { forceHardDeleteDomain }; @@ -36,4 +42,8 @@ async function deleteAppServiceDomain() { console.log(result); } -deleteAppServiceDomain().catch(console.error); +async function main() { + deleteAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsGetControlCenterSsoRequestSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsGetControlCenterSsoRequestSample.ts index a92d0e9d44a7..dba35039e430 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsGetControlCenterSsoRequestSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsGetControlCenterSsoRequestSample.ts @@ -10,19 +10,28 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Generate a single sign-on request for the domain management portal. * * @summary Description for Generate a single sign-on request for the domain management portal. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainControlCenterSsoRequest.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainControlCenterSsoRequest.json */ async function getDomainControlCenterSsoRequest() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const result = await client.domains.getControlCenterSsoRequest(); console.log(result); } -getDomainControlCenterSsoRequest().catch(console.error); +async function main() { + getDomainControlCenterSsoRequest(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsGetOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsGetOwnershipIdentifierSample.ts index 17146b87eea2..e80f6e2e1d16 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsGetOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsGetOwnershipIdentifierSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get ownership identifier for domain * * @summary Description for Get ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainOwnershipIdentifier.json */ async function getDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getDomainOwnershipIdentifier() { console.log(result); } -getDomainOwnershipIdentifier().catch(console.error); +async function main() { + getDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsGetSample.ts index 8406a388e6f4..d94234bc2a1a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get a domain. * * @summary Description for Get a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomain.json */ async function getDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function getDomain() { console.log(result); } -getDomain().catch(console.error); +async function main() { + getDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsListByResourceGroupSample.ts index 629ebd215760..29209e943934 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all domains in a resource group. * * @summary Description for Get all domains in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsByResourceGroup.json */ async function listDomainsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listDomainsByResourceGroup() { console.log(resArray); } -listDomainsByResourceGroup().catch(console.error); +async function main() { + listDomainsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsListOwnershipIdentifiersSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsListOwnershipIdentifiersSample.ts index 3616c1a7555d..5a36373ea533 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsListOwnershipIdentifiersSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsListOwnershipIdentifiersSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Lists domain ownership identifiers. * * @summary Description for Lists domain ownership identifiers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainOwnershipIdentifiers.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainOwnershipIdentifiers.json */ async function listDomainOwnershipIdentifiers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listDomainOwnershipIdentifiers() { console.log(resArray); } -listDomainOwnershipIdentifiers().catch(console.error); +async function main() { + listDomainOwnershipIdentifiers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsListRecommendationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsListRecommendationsSample.ts index 95333b118653..5b83a381ea5c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsListRecommendationsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsListRecommendationsSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get domain name recommendations based on keywords. * * @summary Description for Get domain name recommendations based on keywords. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainRecommendations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainRecommendations.json */ async function listDomainRecommendations() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters: DomainRecommendationSearchParameters = { keywords: "example1", maxDomainRecommendations: 10 @@ -35,4 +40,8 @@ async function listDomainRecommendations() { console.log(resArray); } -listDomainRecommendations().catch(console.error); +async function main() { + listDomainRecommendations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsListSample.ts index b5f3ef2192be..fdb596b8c9b2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all domains in a subscription. * * @summary Description for Get all domains in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsBySubscription.json */ async function listDomainsBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listDomainsBySubscription() { console.log(resArray); } -listDomainsBySubscription().catch(console.error); +async function main() { + listDomainsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsRenewSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsRenewSample.ts index 6a3fcb8b4a0e..5c2d2047a046 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsRenewSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsRenewSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Renew a domain. * * @summary Description for Renew a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/RenewDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/RenewDomain.json */ async function renewAnExistingDomain() { - const subscriptionId = "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; - const resourceGroupName = "RG"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "RG"; const domainName = "example.com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +32,8 @@ async function renewAnExistingDomain() { console.log(result); } -renewAnExistingDomain().catch(console.error); +async function main() { + renewAnExistingDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsTransferOutSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsTransferOutSample.ts index 9d9d197a84eb..e7973f70479c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsTransferOutSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsTransferOutSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Transfer out domain to another registrar * * @summary Transfer out domain to another registrar - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/TransferOutDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/TransferOutDomain.json */ async function transferOutDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function transferOutDomain() { console.log(result); } -transferOutDomain().catch(console.error); +async function main() { + transferOutDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsUpdateOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsUpdateOwnershipIdentifierSample.ts index 50de2f0a0aa2..25a29d725a56 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsUpdateOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsUpdateOwnershipIdentifierSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json */ async function updateAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier: DomainOwnershipIdentifier = { @@ -39,4 +45,8 @@ async function updateAppServiceDomainOwnershipIdentifier() { console.log(result); } -updateAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + updateAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/domainsUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/domainsUpdateSample.ts index 2ab9501f3c02..17116da52fe1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/domainsUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/domainsUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomain.json */ async function updateAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain: DomainPatchResource = { authCode: "exampleAuthCode", @@ -113,4 +119,8 @@ async function updateAppServiceDomain() { console.log(result); } -updateAppServiceDomain().catch(console.error); +async function main() { + updateAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSample.ts b/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSample.ts index ca63723f7a8f..75cf3c2d73ec 100644 --- a/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription. * * @summary Description for Get deleted app for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebApp.json */ async function getDeletedWebApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function getDeletedWebApp() { console.log(result); } -getDeletedWebApp().catch(console.error); +async function main() { + getDeletedWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSnapshotsSample.ts b/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSnapshotsSample.ts index e9bd6a44e324..d11cbfadd5a0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSnapshotsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/globalGetDeletedWebAppSnapshotsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription. * * @summary Description for Get all deleted apps for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppSnapshots.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppSnapshots.json */ async function getDeletedWebAppSnapshots() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function getDeletedWebAppSnapshots() { console.log(result); } -getDeletedWebAppSnapshots().catch(console.error); +async function main() { + getDeletedWebAppSnapshots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/globalGetSubscriptionOperationWithAsyncResponseSample.ts b/sdk/appservice/arm-appservice/samples-dev/globalGetSubscriptionOperationWithAsyncResponseSample.ts index f062faba65d7..651a82031c81 100644 --- a/sdk/appservice/arm-appservice/samples-dev/globalGetSubscriptionOperationWithAsyncResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/globalGetSubscriptionOperationWithAsyncResponseSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets an operation in a subscription and given region * * @summary Description for Gets an operation in a subscription and given region - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSubscriptionOperationWithAsyncResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSubscriptionOperationWithAsyncResponse.json */ async function getsAnOperationInASubscriptionAndGivenRegion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US"; const operationId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab5d5"; const credential = new DefaultAzureCredential(); @@ -30,4 +35,8 @@ async function getsAnOperationInASubscriptionAndGivenRegion() { console.log(result); } -getsAnOperationInASubscriptionAndGivenRegion().catch(console.error); +async function main() { + getsAnOperationInASubscriptionAndGivenRegion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsCreateOrUpdateSample.ts index 0269f48ca761..810a9722591a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsCreateOrUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. * * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_CreateOrUpdate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_CreateOrUpdate.json */ async function createKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const name = "testkubeenv"; const kubeEnvironmentEnvelope: KubeEnvironment = { location: "East US", @@ -38,4 +44,8 @@ async function createKubeEnvironments() { console.log(result); } -createKubeEnvironments().catch(console.error); +async function main() { + createKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsDeleteSample.ts index efdbe8b7341d..be5e24a7ada0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsDeleteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsDeleteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Delete a Kubernetes Environment. * * @summary Description for Delete a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Delete.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Delete.json */ async function deleteKubeEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const name = "examplekenv"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function deleteKubeEnvironmentByName() { console.log(result); } -deleteKubeEnvironmentByName().catch(console.error); +async function main() { + deleteKubeEnvironmentByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsGetSample.ts index 8afd444aeae6..abc4b1c3f278 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get the properties of a Kubernetes Environment. * * @summary Description for Get the properties of a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Get.json */ async function getKubeEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const name = "jlaw-demo1"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function getKubeEnvironmentsByName() { console.log(result); } -getKubeEnvironmentsByName().catch(console.error); +async function main() { + getKubeEnvironmentsByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListByResourceGroupSample.ts index f59a46fe668b..d5ca206af83d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all the Kubernetes Environments in a resource group. * * @summary Description for Get all the Kubernetes Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListByResourceGroup.json */ async function listKubeEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listKubeEnvironmentsByResourceGroup() { console.log(resArray); } -listKubeEnvironmentsByResourceGroup().catch(console.error); +async function main() { + listKubeEnvironmentsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListBySubscriptionSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListBySubscriptionSample.ts index a3e38cac991c..8292fa869cb3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListBySubscriptionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsListBySubscriptionSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all Kubernetes Environments for a subscription. * * @summary Description for Get all Kubernetes Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListBySubscription.json */ async function listKubeEnvironmentsBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listKubeEnvironmentsBySubscription() { console.log(resArray); } -listKubeEnvironmentsBySubscription().catch(console.error); +async function main() { + listKubeEnvironmentsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsUpdateSample.ts index ef4c7118739a..77dd09dfdc03 100644 --- a/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/kubeEnvironmentsUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. * * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Update.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Update.json */ async function updateKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const name = "testkubeenv"; const kubeEnvironmentEnvelope: KubeEnvironmentPatchResource = { staticIp: "1.2.3.4" @@ -37,4 +43,8 @@ async function updateKubeEnvironments() { console.log(result); } -updateKubeEnvironments().catch(console.error); +async function main() { + updateKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/listCustomHostNameSitesSample.ts b/sdk/appservice/arm-appservice/samples-dev/listCustomHostNameSitesSample.ts index fc9e9fac8b4c..01b4c1432574 100644 --- a/sdk/appservice/arm-appservice/samples-dev/listCustomHostNameSitesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/listCustomHostNameSitesSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomHostNameSites.json */ async function getCustomHostnamesUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,16 +36,16 @@ async function getCustomHostnamesUnderSubscription() { console.log(resArray); } -getCustomHostnamesUnderSubscription().catch(console.error); - /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomSpecificHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomSpecificHostNameSites.json */ async function getSpecificCustomHostnameUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const hostname = "www.example.com"; const options: ListCustomHostNameSitesOptionalParams = { hostname }; const credential = new DefaultAzureCredential(); @@ -52,4 +57,9 @@ async function getSpecificCustomHostnameUnderSubscription() { console.log(resArray); } -getSpecificCustomHostnameUnderSubscription().catch(console.error); +async function main() { + getCustomHostnamesUnderSubscription(); + getSpecificCustomHostnameUnderSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksForLocationSample.ts b/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksForLocationSample.ts index 21b629932e40..ffe3ad3e8f4e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksForLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksForLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions for location * * @summary Description for Get available Function app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacksForLocation.json */ async function getLocationsFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -31,4 +36,8 @@ async function getLocationsFunctionAppStacks() { console.log(resArray); } -getLocationsFunctionAppStacks().catch(console.error); +async function main() { + getLocationsFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksSample.ts b/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksSample.ts index 6a107c69ab4f..34ac7f81949e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/providerGetFunctionAppStacksSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions * * @summary Description for Get available Function app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacks.json */ async function getFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getFunctionAppStacks() { console.log(resArray); } -getFunctionAppStacks().catch(console.error); +async function main() { + getFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksForLocationSample.ts b/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksForLocationSample.ts index 5d3ea94b4baf..75b9585d9d96 100644 --- a/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksForLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksForLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions for location * * @summary Description for Get available Web app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacksForLocation.json */ async function getLocationsWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -31,4 +36,8 @@ async function getLocationsWebAppStacks() { console.log(resArray); } -getLocationsWebAppStacks().catch(console.error); +async function main() { + getLocationsWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksSample.ts b/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksSample.ts index e8a1b8a2d0fe..80f97dad8712 100644 --- a/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/providerGetWebAppStacksSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions * * @summary Description for Get available Web app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacks.json */ async function getWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getWebAppStacks() { console.log(resArray); } -getWebAppStacks().catch(console.error); +async function main() { + getWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/providerListOperationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/providerListOperationsSample.ts index cc6b42623e20..afdb759e7631 100644 --- a/sdk/appservice/arm-appservice/samples-dev/providerListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/providerListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions * * @summary Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSample.ts index 3c71fd4d2917..06938bba2a8b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site * * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json */ async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const name = "newsiteinnewASE-NCUS"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function getResourceHealthMetadata() { console.log(result); } -getResourceHealthMetadata().catch(console.error); +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSlotSample.ts index d5671e5dcd25..955e0752da77 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataGetBySiteSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site * * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json */ async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const name = "newsiteinnewASE-NCUS"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getResourceHealthMetadata() { console.log(result); } -getResourceHealthMetadata().catch(console.error); +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListByResourceGroupSample.ts index 90d36520d544..0947d6d95897 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListByResourceGroupSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. * * @summary Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataByResourceGroup.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataByResourceGroup.json */ async function listResourceHealthMetadataForAResourceGroup() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +37,8 @@ async function listResourceHealthMetadataForAResourceGroup() { console.log(resArray); } -listResourceHealthMetadataForAResourceGroup().catch(console.error); +async function main() { + listResourceHealthMetadataForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSample.ts index 2775b9c8c321..156605f0366e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection * * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json */ async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const name = "newsiteinnewASE-NCUS"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listResourceHealthMetadataForASite() { console.log(resArray); } -listResourceHealthMetadataForASite().catch(console.error); +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSlotSample.ts index be93e8a535f8..8921c8eda8d0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListBySiteSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection * * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json */ async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const name = "newsiteinnewASE-NCUS"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listResourceHealthMetadataForASite() { console.log(resArray); } -listResourceHealthMetadataForASite().catch(console.error); +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListSample.ts b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListSample.ts index 86ffdaf0fe46..3230fa63d254 100644 --- a/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/resourceHealthMetadataListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the subscription. * * @summary Description for List all ResourceHealthMetadata for all sites in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySubscription.json */ async function listResourceHealthMetadataForASubscription() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listResourceHealthMetadataForASubscription() { console.log(resArray); } -listResourceHealthMetadataForASubscription().catch(console.error); +async function main() { + listResourceHealthMetadataForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts index 91e1a613676b..8c83fa1b8b53 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -43,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBasicAuthSample.ts new file mode 100644 index 000000000000..beb8d2f42aa8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBasicAuthSample.ts @@ -0,0 +1,54 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StaticSiteBasicAuthPropertiesARMResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Adds or updates basic auth for a static site. + * + * @summary Description for Adds or updates basic auth for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBasicAuth.json + */ +async function createsOrUpdatesBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const basicAuthEnvelope: StaticSiteBasicAuthPropertiesARMResource = { + applicableEnvironmentsMode: "AllEnvironments", + environments: [], + password: "**********************", + secretUrl: undefined + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBasicAuth( + resourceGroupName, + name, + basicAuthName, + basicAuthEnvelope + ); + console.log(result); +} + +async function main() { + createsOrUpdatesBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..2740fd21056f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts @@ -0,0 +1,58 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnection, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnection = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateDatabaseConnectionSample.ts new file mode 100644 index 000000000000..1bfb048ba32c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateDatabaseConnectionSample.ts @@ -0,0 +1,56 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnection, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnection = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts index da399bb0337d..c56b55b2396e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the app settings of a static site. * * @summary Description for Creates or updates the app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteAppSettings.json */ async function createsOrUpdatesTheAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const appSettings: StringDictionary = { properties: { setting1: "someval", setting2: "someval2" } @@ -37,4 +42,8 @@ async function createsOrUpdatesTheAppSettingsOfAStaticSite() { console.log(result); } -createsOrUpdatesTheAppSettingsOfAStaticSite().catch(console.error); +async function main() { + createsOrUpdatesTheAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts index 84ca329fb593..21ce208b5006 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the app settings of a static site build. * * @summary Description for Creates or updates the app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings: StringDictionary = { @@ -39,4 +44,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts index 91884f984044..486596604caf 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the function app settings of a static site build. * * @summary Description for Creates or updates the function app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings: StringDictionary = { @@ -39,4 +44,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts index b5616dfa3585..0bb0c8dfd8e2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site custom domain in an existing resource group and static site. * * @summary Description for Creates a new static site custom domain in an existing resource group and static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteCustomDomain.json */ async function createOrUpdateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource = {}; @@ -37,4 +42,8 @@ async function createOrUpdateACustomDomainForAStaticSite() { console.log(result); } -createOrUpdateACustomDomainForAStaticSite().catch(console.error); +async function main() { + createOrUpdateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts index 2417dfe246cd..73b6586483a3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the function app settings of a static site. * * @summary Description for Creates or updates the function app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const appSettings: StringDictionary = { properties: { setting1: "someval", setting2: "someval2" } @@ -37,4 +42,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSite().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteSample.ts index 3baefc5c97f8..9df209399bef 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateOrUpdateStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSite.json */ async function createOrUpdateAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope: StaticSiteARMResource = { branch: "master", @@ -46,4 +51,8 @@ async function createOrUpdateAStaticSite() { console.log(result); } -createOrUpdateAStaticSite().catch(console.error); +async function main() { + createOrUpdateAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateUserRolesInvitationLinkSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateUserRolesInvitationLinkSample.ts index 7ef564b29a54..cb44ba236eb3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateUserRolesInvitationLinkSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateUserRolesInvitationLinkSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an invitation link for a user with the role * * @summary Description for Creates an invitation link for a user with the role - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateUserRolesInvitationLink.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateUserRolesInvitationLink.json */ async function createAnInvitationLinkForAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteUserRolesInvitationEnvelope: StaticSiteUserInvitationRequestResource = { domain: "happy-sea-15afae3e.azurestaticwebsites.net", @@ -41,4 +46,8 @@ async function createAnInvitationLinkForAUserForAStaticSite() { console.log(result); } -createAnInvitationLinkForAUserForAStaticSite().catch(console.error); +async function main() { + createAnInvitationLinkForAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts index 859d225f3498..a9ce16106706 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deploys zipped content to a specific environment of a static site. * * @summary Description for Deploys zipped content to a specific environment of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteBuildZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteBuildZipDeploy.json */ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource = { @@ -45,6 +50,8 @@ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { console.log(result); } -deployASiteFromAZippedPackageToAParticularStaticSiteBuild().catch( - console.error -); +async function main() { + deployASiteFromAZippedPackageToAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteSample.ts index e908a8022863..961e8f82eed0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesCreateZipDeploymentForStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deploys zipped content to a static site. * * @summary Description for Deploys zipped content to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteZipDeploy.json */ async function deployASiteFromAZippedPackage() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource = { apiZipUrl: @@ -43,4 +48,8 @@ async function deployASiteFromAZippedPackage() { console.log(result); } -deployASiteFromAZippedPackage().catch(console.error); +async function main() { + deployASiteFromAZippedPackage(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..a88760377508 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteBuildDatabaseConnectionSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site build + * + * @summary Delete a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuildDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteDatabaseConnectionSample.ts new file mode 100644 index 000000000000..2f781151e287 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteDatabaseConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site + * + * @summary Delete a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeletePrivateEndpointConnectionSample.ts index e9daff0b660f..dc97c2bae4e5 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeletePrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeletePrivateEndpointConnectionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json */ async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function deleteAPrivateEndpointConnectionForASite() { console.log(result); } -deleteAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteBuildSample.ts index 657fda729848..75d71bcdbb62 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a static site build. * * @summary Description for Deletes a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuild.json */ async function deleteAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function deleteAStaticSiteBuild() { console.log(result); } -deleteAStaticSiteBuild().catch(console.error); +async function main() { + deleteAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteCustomDomainSample.ts index 17f6152db056..25ca3a7d6f9b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteCustomDomainSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteCustomDomainSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a custom domain. * * @summary Description for Deletes a custom domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteCustomDomain.json */ async function deleteACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function deleteACustomDomainForAStaticSite() { console.log(result); } -deleteACustomDomainForAStaticSite().catch(console.error); +async function main() { + deleteACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteSample.ts index 3dee3a98ad22..4dd2e73420d4 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a static site. * * @summary Description for Deletes a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSite.json */ async function deleteAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function deleteAStaticSite() { console.log(result); } -deleteAStaticSite().catch(console.error); +async function main() { + deleteAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteUserSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteUserSample.ts index e139e331ee79..80d87c0eb0dd 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteUserSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDeleteStaticSiteUserSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes the user entry from the static site. * * @summary Description for Deletes the user entry from the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteUser.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteUser.json */ async function deleteAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "aad"; const userid = "1234"; @@ -34,4 +39,8 @@ async function deleteAUserForAStaticSite() { console.log(result); } -deleteAUserForAStaticSite().catch(console.error); +async function main() { + deleteAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachStaticSiteSample.ts index 166cf03e7ecb..e01be5554c61 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Detaches a static site. * * @summary Description for Detaches a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachStaticSite.json */ async function detachAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function detachAStaticSite() { console.log(result); } -detachAStaticSite().catch(console.error); +async function main() { + detachAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts index cb16449dc0de..09130cd984a7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Detach the user provided function app from the static site build * * @summary Description for Detach the user provided function app from the static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json */ async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const functionAppName = "testFunctionApp"; @@ -34,4 +39,8 @@ async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { console.log(result); } -detachTheUserProvidedFunctionAppFromTheStaticSiteBuild().catch(console.error); +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts index 694f599babdc..ddf7070b23b2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Detach the user provided function app from the static site * * @summary Description for Detach the user provided function app from the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json */ async function detachTheUserProvidedFunctionAppFromTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function detachTheUserProvidedFunctionAppFromTheStaticSite() { console.log(result); } -detachTheUserProvidedFunctionAppFromTheStaticSite().catch(console.error); +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBasicAuthSample.ts new file mode 100644 index 000000000000..59383ce2a48d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBasicAuthSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site. + * + * @summary Description for Gets the basic auth properties for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBasicAuth.json + */ +async function getsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBasicAuth( + resourceGroupName, + name, + basicAuthName + ); + console.log(result); +} + +async function main() { + getsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..d5806206d128 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site build by name + * + * @summary Returns overview of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts new file mode 100644 index 000000000000..89ed5a783922 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site build by name + * + * @summary Returns details of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnectionWithDetails( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsSample.ts new file mode 100644 index 000000000000..a708828aa6bc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site build + * + * @summary Returns overviews of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnections( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts new file mode 100644 index 000000000000..89582d796c52 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site build + * + * @summary Returns details of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnectionsWithDetails( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionSample.ts new file mode 100644 index 000000000000..b0afdb68946f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site by name + * + * @summary Returns overview of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionWithDetailsSample.ts new file mode 100644 index 000000000000..7c5e6fd40e8e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionWithDetailsSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site by name + * + * @summary Returns details of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnectionWithDetails( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsSample.ts new file mode 100644 index 000000000000..9c1718e6fbb5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site + * + * @summary Returns overviews of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnections( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsWithDetailsSample.ts new file mode 100644 index 000000000000..46c771b1b976 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetDatabaseConnectionsWithDetailsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site + * + * @summary Returns details of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnectionsWithDetails( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendForBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendForBuildSample.ts index 488a88e58b8e..7f059983a187 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendForBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendForBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Returns the details of a linked backend linked to a static site build by name * * @summary Returns the details of a linked backend linked to a static site build by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSiteBuild.json */ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -34,6 +39,8 @@ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName( console.log(result); } -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName().catch( - console.error -); +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendSample.ts index ab42e3072da1..b684f2eae615 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Returns the details of a linked backend linked to a static site by name * * @summary Returns the details of a linked backend linked to a static site by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSite.json */ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const credential = new DefaultAzureCredential(); @@ -32,6 +37,8 @@ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { console.log(result); } -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName().catch( - console.error -); +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsForBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsForBuildSample.ts index 5b1b895b6f02..e266597c9bd7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsForBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsForBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Returns details of all backends linked to a static site build * * @summary Returns details of all backends linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSiteBuild.json */ async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const credential = new DefaultAzureCredential(); @@ -35,6 +40,8 @@ async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { console.log(resArray); } -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild().catch( - console.error -); +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsSample.ts index a40c43d97698..5a45c17c6e7c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetLinkedBackendsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Returns details of all backends linked to a static site * * @summary Returns details of all backends linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSite.json */ async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { console.log(resArray); } -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite().catch(console.error); +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionListSample.ts index 41b3d33a7abc..72a325374b00 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionListSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the list of private endpoint connections associated with a static site * * @summary Description for Gets the list of private endpoint connections associated with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionList.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionList.json */ async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { console.log(resArray); } -getAListOfPrivateEndpointConnectionsAssociatedWithASite().catch(console.error); +async function main() { + getAListOfPrivateEndpointConnectionsAssociatedWithASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionSample.ts index ec906e97f477..23a59bd9d656 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateEndpointConnectionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a private endpoint connection * * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json */ async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getAPrivateEndpointConnectionForASite() { console.log(result); } -getAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateLinkResourcesSample.ts index 2b79f46f6bd3..ead4c8009b00 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateLinkResourcesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetPrivateLinkResourcesSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the private link resources * * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json */ async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function getPrivateLinkResourcesOfASite() { console.log(result); } -getPrivateLinkResourcesOfASite().catch(console.error); +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildSample.ts index c305cd87ff06..7e5ab3552d2e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of a static site build. * * @summary Description for Gets the details of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuild.json */ async function getAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getAStaticSiteBuild() { console.log(result); } -getAStaticSiteBuild().catch(console.error); +async function main() { + getAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildsSample.ts index f4d880ab0993..74891349da12 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteBuildsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all static site builds for a particular static site. * * @summary Description for Gets all static site builds for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuilds.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuilds.json */ async function getAllBuildsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function getAllBuildsForAStaticSite() { console.log(resArray); } -getAllBuildsForAStaticSite().catch(console.error); +async function main() { + getAllBuildsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteCustomDomainSample.ts index 64066c1f7659..c3a7dbe7810e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteCustomDomainSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteCustomDomainSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets an existing custom domain for a particular static site. * * @summary Description for Gets an existing custom domain for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomain.json */ async function getCustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getCustomDomainForAStaticSite() { console.log(result); } -getCustomDomainForAStaticSite().catch(console.error); +async function main() { + getCustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteSample.ts index 8228305601bc..999ebdcc2bbb 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of a static site. * * @summary Description for Gets the details of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSite.json */ async function getDetailsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function getDetailsForAStaticSite() { console.log(result); } -getDetailsForAStaticSite().catch(console.error); +async function main() { + getDetailsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSitesByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSitesByResourceGroupSample.ts index ac477b205386..8cd43772b855 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSitesByResourceGroupSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetStaticSitesByResourceGroupSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all static sites in the specified resource group. * * @summary Description for Gets all static sites in the specified resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSites.json */ async function getStaticSitesForAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,4 +36,8 @@ async function getStaticSitesForAResourceGroup() { console.log(resArray); } -getStaticSitesForAResourceGroup().catch(console.error); +async function main() { + getStaticSitesForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts index 02b326f484f8..1e9b3b65a5df 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site build * * @summary Description for Gets the details of the user provided function app registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json */ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const functionAppName = "testFunctionApp"; @@ -34,6 +39,8 @@ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBu console.log(result); } -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild().catch( - console.error -); +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts index 2028ad41ad7a..6dd6dc4ccf06 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site * * @summary Description for Gets the details of the user provided function app registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSite.json */ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const credential = new DefaultAzureCredential(); @@ -32,6 +37,8 @@ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() console.log(result); } -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite().catch( - console.error -); +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts index 39b9ca309323..a2e69c095345 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site build * * @summary Description for Gets the details of the user provided function apps registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json */ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const credential = new DefaultAzureCredential(); @@ -35,6 +40,8 @@ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteB console.log(resArray); } -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild().catch( - console.error -); +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts index a2a712afe072..1e973fd45129 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site * * @summary Description for Gets the details of the user provided function apps registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSite.json */ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,6 +38,8 @@ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite( console.log(resArray); } -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite().catch( - console.error -); +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendSample.ts index 3d7d36495cf9..18ee28092997 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Link backend to a static site * * @summary Link backend to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSite.json */ async function linkABackendToAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource = { @@ -41,4 +46,8 @@ async function linkABackendToAStaticSite() { console.log(result); } -linkABackendToAStaticSite().catch(console.error); +async function main() { + linkABackendToAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendToBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendToBuildSample.ts index f437a4367482..e6ee36386ea6 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendToBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesLinkBackendToBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Link backend to a static site build * * @summary Link backend to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSiteBuild.json */ async function linkABackendToAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -43,4 +48,8 @@ async function linkABackendToAStaticSiteBuild() { console.log(result); } -linkABackendToAStaticSiteBuild().catch(console.error); +async function main() { + linkABackendToAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListBasicAuthSample.ts new file mode 100644 index 000000000000..56baa3466ef5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListBasicAuthSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site as a collection. + * + * @summary Description for Gets the basic auth properties for a static site as a collection. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBasicAuth.json + */ +async function listsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBasicAuth( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListSample.ts index 0c3a4059dcf4..6829606f7dea 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all Static Sites for a subscription. * * @summary Description for Get all Static Sites for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAllStaticSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAllStaticSites.json */ async function getAllStaticSitesInASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getAllStaticSitesInASubscription() { console.log(resArray); } -getAllStaticSitesInASubscription().catch(console.error); +async function main() { + getAllStaticSitesInASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteAppSettingsSample.ts index a8983dfe3374..18975d2ffaa4 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteAppSettingsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the application settings of a static site. * * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteAppSettings.json */ async function getAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function getAppSettingsOfAStaticSite() { console.log(result); } -getAppSettingsOfAStaticSite().catch(console.error); +async function main() { + getAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildAppSettingsSample.ts index 0300168ca497..a5e2a149a5bc 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildAppSettingsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the application settings of a static site build. * * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildAppSettings.json */ async function getAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getAppSettingsOfAStaticSiteBuild() { console.log(result); } -getAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + getAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts index 2f7ced124eae..9e87df11e8d0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the application settings of a static site build. * * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctionAppSettings.json */ async function getFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -getFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + getFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionsSample.ts index 9e5143937149..3db0dc1bf14e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteBuildFunctionsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the functions of a particular static site build. * * @summary Description for Gets the functions of a particular static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctions.json */ async function getsTheFunctionsOfAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const credential = new DefaultAzureCredential(); @@ -35,4 +40,8 @@ async function getsTheFunctionsOfAParticularStaticSiteBuild() { console.log(resArray); } -getsTheFunctionsOfAParticularStaticSiteBuild().catch(console.error); +async function main() { + getsTheFunctionsOfAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteConfiguredRolesSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteConfiguredRolesSample.ts index 09fe315e9845..3d4c71461f82 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteConfiguredRolesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteConfiguredRolesSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Lists the roles configured for the static site. * * @summary Description for Lists the roles configured for the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteConfiguredRoles.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteConfiguredRoles.json */ async function listsTheConfiguredRolesForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function listsTheConfiguredRolesForAStaticSite() { console.log(result); } -listsTheConfiguredRolesForAStaticSite().catch(console.error); +async function main() { + listsTheConfiguredRolesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteCustomDomainsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteCustomDomainsSample.ts index 1558a0861c2f..dd7cbc3f8ab3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteCustomDomainsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteCustomDomainsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all static site custom domains for a particular static site. * * @summary Description for Gets all static site custom domains for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomains.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomains.json */ async function listCustomDomainsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function listCustomDomainsForAStaticSite() { console.log(resArray); } -listCustomDomainsForAStaticSite().catch(console.error); +async function main() { + listCustomDomainsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionAppSettingsSample.ts index cc92d1ee132c..6a01fa85688f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionAppSettingsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the application settings of a static site. * * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctionAppSettings.json */ async function getFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function getFunctionAppSettingsOfAStaticSite() { console.log(result); } -getFunctionAppSettingsOfAStaticSite().catch(console.error); +async function main() { + getFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionsSample.ts index a898d27c297e..5d47a36a8990 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteFunctionsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the functions of a static site. * * @summary Description for Gets the functions of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctions.json */ async function getsTheFunctionsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function getsTheFunctionsOfAStaticSite() { console.log(resArray); } -getsTheFunctionsOfAStaticSite().catch(console.error); +async function main() { + getsTheFunctionsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteSecretsSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteSecretsSample.ts index 253337170950..5f474bb78910 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteSecretsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteSecretsSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Lists the secrets for an existing static site. * * @summary Description for Lists the secrets for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteSecrets.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteSecrets.json */ async function listSecretsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function listSecretsForAStaticSite() { console.log(result); } -listSecretsForAStaticSite().catch(console.error); +async function main() { + listSecretsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteUsersSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteUsersSample.ts index 31a9d1b40608..c002846e17a3 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteUsersSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesListStaticSiteUsersSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the list of users of a static site. * * @summary Description for Gets the list of users of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteUsers.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteUsers.json */ async function listUsersForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "all"; const credential = new DefaultAzureCredential(); @@ -35,4 +40,8 @@ async function listUsersForAStaticSite() { console.log(resArray); } -listUsersForAStaticSite().catch(console.error); +async function main() { + listUsersForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesPreviewWorkflowSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesPreviewWorkflowSample.ts index ea592ef44094..cb5936bf915d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesPreviewWorkflowSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesPreviewWorkflowSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Generates a preview workflow file for the static site * * @summary Description for Generates a preview workflow file for the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GenerateStaticSiteWorkflowPreview.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GenerateStaticSiteWorkflowPreview.json */ async function generatesAPreviewWorkflowFileForTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const staticSitesWorkflowPreviewRequest: StaticSitesWorkflowPreviewRequest = { branch: "master", @@ -41,4 +46,8 @@ async function generatesAPreviewWorkflowFileForTheStaticSite() { console.log(result); } -generatesAPreviewWorkflowFileForTheStaticSite().catch(console.error); +async function main() { + generatesAPreviewWorkflowFileForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts index 6b70555ee974..4fc262f2fd71 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts @@ -14,16 +14,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site build * * @summary Description for Register a user provided function app with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json */ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const functionAppName = "testFunctionApp"; @@ -49,4 +54,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSiteBuild().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts index 1fd612b47830..cfd088ec60a1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts @@ -14,16 +14,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site * * @summary Description for Register a user provided function app with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json */ async function registerAUserProvidedFunctionAppWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const isForced = true; @@ -47,4 +52,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSite() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSite().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesResetStaticSiteApiKeySample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesResetStaticSiteApiKeySample.ts index 85324c7ed49d..0f6435fdc45f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesResetStaticSiteApiKeySample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesResetStaticSiteApiKeySample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Resets the api key for an existing static site. * * @summary Description for Resets the api key for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ResetStaticSiteApiKey.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ResetStaticSiteApiKey.json */ async function resetTheApiKeyForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const resetPropertiesEnvelope: StaticSiteResetPropertiesARMResource = { repositoryToken: "repoToken123", @@ -38,4 +43,8 @@ async function resetTheApiKeyForAStaticSite() { console.log(result); } -resetTheApiKeyForAStaticSite().catch(console.error); +async function main() { + resetTheApiKeyForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendFromBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendFromBuildSample.ts index d40e53352709..9eb3eb73b01e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendFromBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendFromBuildSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Unlink a backend from a static site build * * @summary Unlink a backend from a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSiteBuild.json */ async function unlinkABackendFromAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const linkedBackendName = "testBackend"; @@ -34,4 +39,8 @@ async function unlinkABackendFromAStaticSiteBuild() { console.log(result); } -unlinkABackendFromAStaticSiteBuild().catch(console.error); +async function main() { + unlinkABackendFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendSample.ts index 033d6660e289..b84a24a3b76d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUnlinkBackendSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Unlink a backend from a static site * * @summary Unlink a backend from a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSite.json */ async function unlinkABackendFromAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function unlinkABackendFromAStaticSite() { console.log(result); } -unlinkABackendFromAStaticSite().catch(console.error); +async function main() { + unlinkABackendFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..cc1d650ce55d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateBuildDatabaseConnectionSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnectionPatchRequest, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteBuildDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateDatabaseConnectionSample.ts new file mode 100644 index 000000000000..82cf428681ff --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateDatabaseConnectionSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnectionPatchRequest, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteSample.ts index 2cca115e60dd..b39b370fd60a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSite.json */ async function patchAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope: StaticSitePatchResource = {}; const credential = new DefaultAzureCredential(); @@ -35,4 +40,8 @@ async function patchAStaticSite() { console.log(result); } -patchAStaticSite().catch(console.error); +async function main() { + patchAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteUserSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteUserSample.ts index b40fffcfbb0b..efff06972428 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteUserSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesUpdateStaticSiteUserSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates a user entry with the listed roles * * @summary Description for Updates a user entry with the listed roles - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateStaticSiteUser.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateStaticSiteUser.json */ async function createOrUpdateAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "aad"; const userid = "1234"; @@ -41,4 +46,8 @@ async function createOrUpdateAUserForAStaticSite() { console.log(result); } -createOrUpdateAUserForAStaticSite().catch(console.error); +async function main() { + createOrUpdateAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendForBuildSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendForBuildSample.ts index 81bbd89fd34b..a891d41a1703 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendForBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendForBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site build * * @summary Validates that a backend can be linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSiteBuild.json */ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -43,4 +48,8 @@ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSiteBuild().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendSample.ts index a68feb596daf..53e147d740b0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateBackendSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site * * @summary Validates that a backend can be linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSite.json */ async function validateIfBackendCanBeLinkedToStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource = { @@ -41,4 +46,8 @@ async function validateIfBackendCanBeLinkedToStaticSite() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSite().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts index 591d3b4d0cf8..7e77d584d943 100644 --- a/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Validates a particular custom domain can be added to a static site. * * @summary Description for Validates a particular custom domain can be added to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateStaticSiteCustomDomain.json */ async function validateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource = {}; @@ -37,4 +42,8 @@ async function validateACustomDomainForAStaticSite() { console.log(result); } -validateACustomDomainForAStaticSite().catch(console.error); +async function main() { + validateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsGetSample.ts index 3a0c8d33e7bb..a9b1ba3a0de1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsGetSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get details of a top-level domain. * * @summary Description for Get details of a top-level domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetTopLevelDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetTopLevelDomain.json */ async function getTopLevelDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function getTopLevelDomain() { console.log(result); } -getTopLevelDomain().catch(console.error); +async function main() { + getTopLevelDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListAgreementsSample.ts b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListAgreementsSample.ts index f0a47c08a7a3..c7ca45f1b500 100644 --- a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListAgreementsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListAgreementsSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all legal agreements that user needs to accept before purchasing a domain. * * @summary Description for Gets all legal agreements that user needs to accept before purchasing a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomainAgreements.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomainAgreements.json */ async function listTopLevelDomainAgreements() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "in"; const agreementOption: TopLevelDomainAgreementOption = { forTransfer: false, @@ -39,4 +44,8 @@ async function listTopLevelDomainAgreements() { console.log(resArray); } -listTopLevelDomainAgreements().catch(console.error); +async function main() { + listTopLevelDomainAgreements(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListSample.ts index ebbf654f6e8d..5a1601c0c5d5 100644 --- a/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/topLevelDomainsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all top-level domains supported for registration. * * @summary Description for Get all top-level domains supported for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomains.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomains.json */ async function listTopLevelDomains() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listTopLevelDomains() { console.log(resArray); } -listTopLevelDomains().catch(console.error); +async function main() { + listTopLevelDomains(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/verifyHostingEnvironmentVnetSample.ts b/sdk/appservice/arm-appservice/samples-dev/verifyHostingEnvironmentVnetSample.ts index 10cf15881fc2..9476536652f8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/verifyHostingEnvironmentVnetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/verifyHostingEnvironmentVnetSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { VnetParameters, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. * * @summary Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/VerifyHostingEnvironmentVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/VerifyHostingEnvironmentVnet.json */ async function verifyHostingEnvironmentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters: VnetParameters = { vnetName: "vNet123", vnetResourceGroup: "vNet123rg", @@ -30,4 +35,8 @@ async function verifyHostingEnvironmentVnet() { console.log(result); } -verifyHostingEnvironmentVnet().catch(console.error); +async function main() { + verifyHostingEnvironmentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSample.ts new file mode 100644 index 000000000000..bcad087a48dc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostName.json + */ +async function analyzeCustomHostnameForWebapp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostname( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForWebapp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSlotSample.ts new file mode 100644 index 000000000000..0d40d71bb32d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsAnalyzeCustomHostnameSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostNameSlot.json + */ +async function analyzeCustomHostnameForSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostnameSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsApplySlotConfigToProductionSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsApplySlotConfigToProductionSample.ts new file mode 100644 index 000000000000..4e8bd9175b21 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsApplySlotConfigToProductionSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { CsmSlotEntity, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Applies the configuration settings from the target slot onto the current slot. + * + * @summary Description for Applies the configuration settings from the target slot onto the current slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApplySlotConfig.json + */ +async function applyWebAppSlotConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slotSwapEntity: CsmSlotEntity = { + preserveVnet: true, + targetSlot: "staging" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.applySlotConfigToProduction( + resourceGroupName, + name, + slotSwapEntity + ); + console.log(result); +} + +async function main() { + applyWebAppSlotConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts index f4d0ec7095c8..b99f5282fb79 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -43,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts index a8c65aeaa6a0..1ed3bdfe2fd7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -45,4 +50,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsBackupSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsBackupSample.ts new file mode 100644 index 000000000000..8766e5f3d81c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsBackupSample.ts @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { BackupRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a backup of an app. + * + * @summary Description for Creates a backup of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/BackupWebApp.json + */ +async function backupWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const request: BackupRequest = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z") + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.backup(resourceGroupName, name, request); + console.log(result); +} + +async function main() { + backupWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateConfigurationSample.ts new file mode 100644 index 000000000000..14513b3693fe --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateConfigurationSample.ts @@ -0,0 +1,94 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteConfigResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the configuration of an app. + * + * @summary Description for Updates the configuration of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateSiteConfig.json + */ +async function updateSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteConfig: SiteConfigResource = { + acrUseManagedIdentityCreds: false, + alwaysOn: false, + appCommandLine: "", + autoHealEnabled: false, + azureStorageAccounts: {}, + defaultDocuments: [ + "Default.htm", + "Default.html", + "Default.asp", + "index.htm", + "index.html", + "iisstart.htm", + "default.aspx", + "index.php", + "hostingstart.html" + ], + detailedErrorLoggingEnabled: false, + ftpsState: "AllAllowed", + functionAppScaleLimit: 0, + functionsRuntimeScaleMonitoringEnabled: false, + http20Enabled: false, + httpLoggingEnabled: false, + linuxFxVersion: "", + loadBalancing: "LeastRequests", + logsDirectorySizeLimit: 35, + managedPipelineMode: "Integrated", + minTlsVersion: "1.2", + minimumElasticInstanceCount: 0, + netFrameworkVersion: "v4.0", + nodeVersion: "", + numberOfWorkers: 1, + phpVersion: "5.6", + powerShellVersion: "", + pythonVersion: "", + remoteDebuggingEnabled: false, + requestTracingEnabled: false, + scmMinTlsVersion: "1.2", + use32BitWorkerProcess: true, + virtualApplications: [ + { physicalPath: "site\\wwwroot", preloadEnabled: false, virtualPath: "/" } + ], + vnetName: "", + vnetPrivatePortsCount: 0, + vnetRouteAllEnabled: false, + webSocketsEnabled: false + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.createOrUpdateConfiguration( + resourceGroupName, + name, + siteConfig + ); + console.log(result); +} + +async function main() { + updateSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSample.ts new file mode 100644 index 000000000000..25f0711154a9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSample.ts @@ -0,0 +1,90 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { Site, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebApp.json + */ +async function cloneWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: Site = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478", + sourceWebAppLocation: "West Europe" + }, + kind: "app", + location: "East US" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebApp.json + */ +async function createOrUpdateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: Site = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebApp(); + createOrUpdateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSlotSample.ts new file mode 100644 index 000000000000..e562df125ec1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsCreateOrUpdateSlotSample.ts @@ -0,0 +1,94 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { Site, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebAppSlot.json + */ +async function cloneWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: Site = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478/slot/qa", + sourceWebAppLocation: "West Europe" + }, + kind: "app", + location: "East US" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebAppSlot.json + */ +async function createOrUpdateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: Site = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebAppSlot(); + createOrUpdateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteBackupSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteBackupSample.ts new file mode 100644 index 000000000000..e97ea1fff74c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteBackupSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a backup of an app by its ID. + * + * @summary Description for Deletes a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppBackup.json + */ +async function deleteWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteBackup( + resourceGroupName, + name, + backupId + ); + console.log(result); +} + +async function main() { + deleteWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSample.ts index 474484425f17..7586afdecdf0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json */ async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function deleteAPrivateEndpointConnectionForASite() { console.log(result); } -deleteAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSlotSample.ts index 03c6818268e8..74b674a4922a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeletePrivateEndpointConnectionSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnectionSlot.json */ async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -34,4 +39,8 @@ async function deleteAPrivateEndpointConnectionForASite() { console.log(result); } -deleteAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSample.ts new file mode 100644 index 000000000000..1763530f2c50 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebApp.json + */ +async function deleteWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSlotSample.ts new file mode 100644 index 000000000000..47a8f7941adc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeleteSlotSample.ts @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppSlot.json + */ +async function deleteWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + deleteWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSample.ts new file mode 100644 index 000000000000..32c5bce632cf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSample.ts @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkflowArtifacts, + WebAppsDeployWorkflowArtifactsOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteDeployWorkflowArtifacts.json + */ +async function deleteWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts: WorkflowArtifacts = { + filesToDelete: ["test/workflow.json", "test/"] + }; + const options: WebAppsDeployWorkflowArtifactsOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts( + resourceGroupName, + name, + options + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifacts.json + */ +async function deploysWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts: WorkflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=" + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')" + }, + serviceProvider: { id: "/serviceProviders/eventHub" } + } + } + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub" + } + }, + splitOn: "@triggerOutputs()?['body']" + } + } + }, + kind: "Stateful" + } + } + }; + const options: WebAppsDeployWorkflowArtifactsOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + deleteWorkflowArtifacts(); + deploysWorkflowArtifacts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSlotSample.ts new file mode 100644 index 000000000000..bd486e4bb1e7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsDeployWorkflowArtifactsSlotSample.ts @@ -0,0 +1,97 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkflowArtifacts, + WebAppsDeployWorkflowArtifactsSlotOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifactsSlot.json + */ +async function deploysWorkflowArtifactsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "testsSlot"; + const workflowArtifacts: WorkflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=" + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')" + }, + serviceProvider: { id: "/serviceProviders/eventHub" } + } + } + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub" + } + }, + splitOn: "@triggerOutputs()?['body']" + } + } + }, + kind: "Stateful" + } + } + }; + const options: WebAppsDeployWorkflowArtifactsSlotOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifactsSlot( + resourceGroupName, + name, + slot, + options + ); + console.log(result); +} + +async function main() { + deploysWorkflowArtifactsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSample.ts index 43c6377bfe2c..f8808343b15d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the config reference and status of an app * * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSetting.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSetting.json */ async function getAzureKeyVaultAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const appSettingKey = "setting"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getAzureKeyVaultAppSettingReference() { console.log(result); } -getAzureKeyVaultAppSettingReference().catch(console.error); +async function main() { + getAzureKeyVaultAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts index 77629132b010..a6b843cf66e5 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the config reference and status of an app * * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingSlot.json */ async function getAzureKeyVaultSlotAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const appSettingKey = "setting"; const slot = "stage"; @@ -34,4 +40,8 @@ async function getAzureKeyVaultSlotAppSettingReference() { console.log(result); } -getAzureKeyVaultSlotAppSettingReference().catch(console.error); +async function main() { + getAzureKeyVaultSlotAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSample.ts index bf03ee907977..c146fa391434 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the config reference app settings and status of an app * * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettings.json */ async function getAzureKeyVaultReferencesForAppSettings() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function getAzureKeyVaultReferencesForAppSettings() { console.log(resArray); } -getAzureKeyVaultReferencesForAppSettings().catch(console.error); +async function main() { + getAzureKeyVaultReferencesForAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts index 63b0ba791f59..609eaae022e1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the config reference app settings and status of an app * * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json */ async function getAzureKeyVaultReferencesForAppSettingsForSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testc6282"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function getAzureKeyVaultReferencesForAppSettingsForSlot() { console.log(resArray); } -getAzureKeyVaultReferencesForAppSettingsForSlot().catch(console.error); +async function main() { + getAzureKeyVaultReferencesForAppSettingsForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsSample.ts new file mode 100644 index 000000000000..30cbf79d11f6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the Authentication/Authorization settings of an app. + * + * @summary Description for Gets the Authentication/Authorization settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettings.json + */ +async function listAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettings(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2Sample.ts new file mode 100644 index 000000000000..3d2b18bc7686 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2Sample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettingsV2.json + */ +async function listAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2WithoutSecretsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2WithoutSecretsSample.ts new file mode 100644 index 000000000000..5485b12d4540 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetAuthSettingsV2WithoutSecretsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAuthSettingsV2WithoutSecrets.json + */ +async function listAuthSettingsWithoutSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2WithoutSecrets( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAuthSettingsWithoutSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetBackupStatusSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetBackupStatusSample.ts new file mode 100644 index 000000000000..f9978032959f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetBackupStatusSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a backup of an app by its ID. + * + * @summary Description for Gets a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackup.json + */ +async function getWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getBackupStatus( + resourceGroupName, + name, + backupId + ); + console.log(result); +} + +async function main() { + getWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetConfigurationSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetConfigurationSample.ts new file mode 100644 index 000000000000..11959223162a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetConfigurationSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * + * @summary Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteConfig.json + */ +async function getSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getConfiguration(resourceGroupName, name); + console.log(result); +} + +async function main() { + getSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSample.ts index 95c542071cac..0d27d0cdfc14 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. * * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json */ async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +32,8 @@ async function getFtpAllowed() { console.log(result); } -getFtpAllowed().catch(console.error); +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSlotSample.ts index 3abf88b4a297..b1e1180322ad 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetFtpAllowedSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. * * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json */ async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getFtpAllowed() { console.log(result); } -getFtpAllowed().catch(console.error); +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSample.ts index 0f13421a4012..0ce37409ff07 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all scale-out instances of an app. * * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json */ async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "tests346"; const instanceId = "134987120"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getSiteInstanceInfo() { console.log(result); } -getSiteInstanceInfo().catch(console.error); +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSlotSample.ts index ab0318ead477..764af11a164c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceInfoSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all scale-out instances of an app. * * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json */ async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "tests346"; const instanceId = "134987120"; const slot = "staging"; @@ -34,4 +40,8 @@ async function getSiteInstanceInfo() { console.log(result); } -getSiteInstanceInfo().catch(console.error); +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceWorkflowSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceWorkflowSlotSample.ts new file mode 100644 index 000000000000..e95ede26580c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetInstanceWorkflowSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflowSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceWorkflowSlot( + resourceGroupName, + name, + slot, + workflowName + ); + console.log(result); +} + +async function main() { + getAWorkflowSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSample.ts index d5ef3618be27..b2e75d73fe70 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotSample.ts index 89227fd6954a..e72847403828 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +40,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotV2Sample.ts index a8fe0471a22a..8a9d21d3ecb7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotV2Sample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationSlotV2Sample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +40,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationV2Sample.ts index 56f016e0de02..948ae6a5b89c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationV2Sample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTraceOperationV2Sample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSample.ts index c0a161e6aa85..6dae49c4e26d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotSample.ts index 9b75b9938ebb..f742085ed5c8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +40,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotV2Sample.ts index 491f5f70498e..27852fbc531c 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotV2Sample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesSlotV2Sample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +40,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesV2Sample.ts index bd1bbb1b3cca..fbaa9ca745fb 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesV2Sample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetNetworkTracesV2Sample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSample.ts index 2855a5010892..5acdecb49a0e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a private endpoint connection * * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json */ async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getAPrivateEndpointConnectionForASite() { console.log(result); } -getAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSlotSample.ts index e99f60c701f3..da054721f53d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateEndpointConnectionSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets a private endpoint connection * * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionSlot.json */ async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -34,4 +39,8 @@ async function getAPrivateEndpointConnectionForASite() { console.log(result); } -getAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSample.ts index d80f6792533b..15563242f95a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the private link resources * * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json */ async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +35,8 @@ async function getPrivateLinkResourcesOfASite() { console.log(result); } -getPrivateLinkResourcesOfASite().catch(console.error); +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSlotSample.ts index cb198578c43f..b7ba09054e74 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetPrivateLinkResourcesSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets the private link resources * * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResourcesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResourcesSlot.json */ async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getPrivateLinkResourcesOfASite() { console.log(result); } -getPrivateLinkResourcesOfASite().catch(console.error); +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetProductionSiteDeploymentStatusSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetProductionSiteDeploymentStatusSample.ts index 7624f03bd14d..465f2052cfa1 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetProductionSiteDeploymentStatusSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetProductionSiteDeploymentStatusSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). * * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatus.json */ async function getDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getDeploymentStatus() { console.log(result); } -getDeploymentStatus().catch(console.error); +async function main() { + getDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSample.ts new file mode 100644 index 000000000000..68a1cd0a4c9f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebApp.json + */ +async function getWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSample.ts index c8a2f66e93af..7b49cec22078 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. * * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json */ async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +32,8 @@ async function getScmAllowed() { console.log(result); } -getScmAllowed().catch(console.error); +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSlotSample.ts index 6f4fe3b80eab..204e3e40cc6a 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetScmAllowedSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. * * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json */ async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -32,4 +37,8 @@ async function getScmAllowed() { console.log(result); } -getScmAllowed().catch(console.error); +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSample.ts new file mode 100644 index 000000000000..7812d49e5108 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSample.ts @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppSlot.json + */ +async function getWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSiteDeploymentStatusSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSiteDeploymentStatusSlotSample.ts index 325feb5a15ae..ca3166e9be4f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSiteDeploymentStatusSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetSlotSiteDeploymentStatusSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). * * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatusSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatusSlot.json */ async function getDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; @@ -34,4 +39,8 @@ async function getDeploymentStatusSlot() { console.log(result); } -getDeploymentStatusSlot().catch(console.error); +async function main() { + getDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsGetWorkflowSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsGetWorkflowSample.ts new file mode 100644 index 000000000000..fe4f81bc386e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsGetWorkflowSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflow() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getWorkflow( + resourceGroupName, + name, + workflowName + ); + console.log(result); +} + +async function main() { + getAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListApplicationSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListApplicationSettingsSample.ts new file mode 100644 index 000000000000..f4460c03e9f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListApplicationSettingsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of an app. + * + * @summary Description for Gets the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppSettings.json + */ +async function listAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listApplicationSettings( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupStatusSecretsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupStatusSecretsSample.ts new file mode 100644 index 000000000000..cfac0cf36402 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupStatusSecretsSample.ts @@ -0,0 +1,75 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { BackupRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * + * @summary Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackupWithSecrets.json + */ +async function getWebAppBackupWithSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const request: BackupRequest = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z") + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listBackupStatusSecrets( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + getWebAppBackupWithSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupsSample.ts new file mode 100644 index 000000000000..a126c4b34cfd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListBackupsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppBackups.json + */ +async function listWebAppBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listBackups(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSample.ts index b2f1122e2917..f4b061043666 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. * * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPolicies.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPolicies.json */ async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listPublishingCredentialsPolicies() { console.log(resArray); } -listPublishingCredentialsPolicies().catch(console.error); +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts index 64a52c3527e0..6e4216c411a9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. * * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPoliciesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPoliciesSlot.json */ async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsite"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listPublishingCredentialsPolicies() { console.log(resArray); } -listPublishingCredentialsPolicies().catch(console.error); +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListByResourceGroupSample.ts new file mode 100644 index 000000000000..f9268fe26b0d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all web, mobile, and API apps in the specified resource group. + * + * @summary Description for Gets all web, mobile, and API apps in the specified resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppsByResourceGroup.json + */ +async function listWebAppsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListConfigurationsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListConfigurationsSample.ts new file mode 100644 index 000000000000..2b51c9740829 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListConfigurationsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List the configurations of an app + * + * @summary Description for List the configurations of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppConfigurations.json + */ +async function listWebAppConfigurations() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listConfigurations( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppConfigurations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListInstanceWorkflowsSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListInstanceWorkflowsSlotSample.ts new file mode 100644 index 000000000000..713012069ad2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListInstanceWorkflowsSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflowsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listInstanceWorkflowsSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflowsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListProductionSiteDeploymentStatusesSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListProductionSiteDeploymentStatusesSample.ts index ea63e3d7f25d..641410086937 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListProductionSiteDeploymentStatusesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListProductionSiteDeploymentStatusesSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). * * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatus.json */ async function listDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +38,8 @@ async function listDeploymentStatus() { console.log(resArray); } -listDeploymentStatus().catch(console.error); +async function main() { + listDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListSample.ts new file mode 100644 index 000000000000..5417760c9e0e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all apps for a subscription. + * + * @summary Description for Get all apps for a subscription. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebApps.json + */ +async function listWebAppsForSubscription() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.list()) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSample.ts index 6af8660e78e9..c58f857b8ea5 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets existing backups of an app. * * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json */ async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "tests346"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +39,8 @@ async function listBackups() { console.log(resArray); } -listBackups().catch(console.error); +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSlotSample.ts index 2639464b5543..f1299f6aae7b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListSiteBackupsSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets existing backups of an app. * * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json */ async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "tests346"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listBackups() { console.log(resArray); } -listBackups().catch(console.error); +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotSiteDeploymentStatusesSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotSiteDeploymentStatusesSlotSample.ts index 3add9ed3eb6d..abb3eb7b6b2f 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotSiteDeploymentStatusesSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotSiteDeploymentStatusesSlotSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). * * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatusSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatusSlot.json */ async function listDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -35,4 +40,8 @@ async function listDeploymentStatusSlot() { console.log(resArray); } -listDeploymentStatusSlot().catch(console.error); +async function main() { + listDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotsSample.ts new file mode 100644 index 000000000000..0ad04fc540f3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListSlotsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets an app's deployment slots. + * + * @summary Description for Gets an app's deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppSlots.json + */ +async function listWebAppSlots() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSlots(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppSlots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSample.ts new file mode 100644 index 000000000000..8393ca49406b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnections() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnections( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnections(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSlotSample.ts new file mode 100644 index 000000000000..e489da63458f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsConnectionsSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnectionsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnectionsSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnectionsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsSample.ts new file mode 100644 index 000000000000..8efe01d4b0d8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsListWorkflowsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflows() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listWorkflows( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflows(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsRestoreSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsRestoreSample.ts new file mode 100644 index 000000000000..9b9e791b7e29 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsRestoreSample.ts @@ -0,0 +1,68 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { RestoreRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Restores a specific backup to another app (or deployment slot, if specified). + * + * @summary Description for Restores a specific backup to another app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestoreWebAppBackup.json + */ +async function restoreWebAppFromBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "123244"; + const request: RestoreRequest = { + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + overwrite: true, + siteName: "sitef6141", + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginRestoreAndWait( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + restoreWebAppFromBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSample.ts index 9b288dd620b2..3c2810003c98 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const options: WebAppsStartNetworkTraceOptionalParams = { durationInSeconds }; @@ -36,4 +42,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSlotSample.ts index 13e206c3f865..c243fa17bad8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStartNetworkTraceSlotSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const slot = "Production"; @@ -40,4 +46,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSample.ts index 2e1621db3d8e..a88910e0bd30 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const options: WebAppsStartWebSiteNetworkTraceOperationOptionalParams = { @@ -38,4 +44,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts index f3121910fa8c..4c33e968431d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const slot = "Production"; @@ -40,4 +46,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSample.ts index 48db6f796c32..bdf7301821b9 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. * * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json */ async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -27,4 +33,8 @@ async function stopACurrentlyRunningNetworkTraceOperationForASite() { console.log(result); } -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSlotSample.ts index cc5d4dc945dd..f65fa70ce6f0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStopNetworkTraceSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. * * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json */ async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function stopACurrentlyRunningNetworkTraceOperationForASite() { console.log(result); } -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSample.ts index 035ba9dbfdfa..a369cc8ad1bc 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. * * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json */ async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +36,8 @@ async function stopACurrentlyRunningNetworkTraceOperationForASite() { console.log(result); } -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSlotSample.ts index bec7040724c6..48c6decc3458 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsStopWebSiteNetworkTraceSlotSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. * * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json */ async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function stopACurrentlyRunningNetworkTraceOperationForASite() { console.log(result); } -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateApplicationSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateApplicationSettingsSample.ts new file mode 100644 index 000000000000..361478c3641f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateApplicationSettingsSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StringDictionary, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Replaces the application settings of an app. + * + * @summary Description for Replaces the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAppSettings.json + */ +async function updateAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const appSettings: StringDictionary = { + properties: { setting1: "Value1", setting2: "Value2" } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateApplicationSettings( + resourceGroupName, + name, + appSettings + ); + console.log(result); +} + +async function main() { + updateAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsSample.ts new file mode 100644 index 000000000000..656e9145eea4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsSample.ts @@ -0,0 +1,60 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteAuthSettings, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the Authentication / Authorization settings associated with web app. + * + * @summary Description for Updates the Authentication / Authorization settings associated with web app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettings.json + */ +async function updateAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettings: SiteAuthSettings = { + allowedExternalRedirectUrls: [ + "sitef6141.customdomain.net", + "sitef6141.customdomain.info" + ], + clientId: "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + defaultProvider: "Google", + enabled: true, + runtimeVersion: "~1", + tokenRefreshExtensionHours: 120, + tokenStoreEnabled: true, + unauthenticatedClientAction: "RedirectToLoginPage" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettings( + resourceGroupName, + name, + siteAuthSettings + ); + console.log(result); +} + +async function main() { + updateAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsV2Sample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsV2Sample.ts new file mode 100644 index 000000000000..d149b945fecf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAuthSettingsV2Sample.ts @@ -0,0 +1,95 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteAuthSettingsV2, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettingsV2.json + */ +async function updateAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettingsV2: SiteAuthSettingsV2 = { + globalValidation: { + excludedPaths: ["/nosecrets/Path"], + requireAuthentication: true, + unauthenticatedClientAction: "Return403" + }, + httpSettings: { + forwardProxy: { + convention: "Standard", + customHostHeaderName: "authHeader", + customProtoHeaderName: "customProtoHeader" + }, + requireHttps: true, + routes: { apiPrefix: "/authv2/" } + }, + identityProviders: { + google: { + enabled: true, + login: { scopes: ["admin"] }, + registration: { + clientId: + "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + clientSecretSettingName: "ClientSecret" + }, + validation: { allowedAudiences: ["https://example.com"] } + } + }, + login: { + allowedExternalRedirectUrls: ["https://someurl.com"], + cookieExpiration: { + convention: "IdentityProviderDerived", + timeToExpiration: "2022:09-01T00:00Z" + }, + nonce: { validateNonce: true }, + preserveUrlFragmentsForLogins: true, + routes: { logoutEndpoint: "https://app.com/logout" }, + tokenStore: { + enabled: true, + fileSystem: { directory: "/wwwroot/sites/example" }, + tokenRefreshExtensionHours: 96 + } + }, + platform: { + configFilePath: "/auth/config.json", + enabled: true, + runtimeVersion: "~1" + } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettingsV2( + resourceGroupName, + name, + siteAuthSettingsV2 + ); + console.log(result); +} + +async function main() { + updateAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAzureStorageAccountsSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAzureStorageAccountsSample.ts new file mode 100644 index 000000000000..9a3de035d51e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateAzureStorageAccountsSample.ts @@ -0,0 +1,58 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + AzureStoragePropertyDictionaryResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the Azure storage account configurations of an app. + * + * @summary Description for Updates the Azure storage account configurations of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAzureStorageAccounts.json + */ +async function updateAzureStorageAccounts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const azureStorageAccounts: AzureStoragePropertyDictionaryResource = { + properties: { + account1: { + type: "AzureFiles", + accessKey: "26515^%@#*", + accountName: "testsa", + mountPath: "/mounts/a/files", + shareName: "web" + } + } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAzureStorageAccounts( + resourceGroupName, + name, + azureStorageAccounts + ); + console.log(result); +} + +async function main() { + updateAzureStorageAccounts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSample.ts index 13dfbde33aa7..8252da8b5771 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { allow: true @@ -37,4 +42,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSlotSample.ts index 33c958c415c9..2586825e6474 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateFtpAllowedSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { @@ -39,4 +44,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSample.ts new file mode 100644 index 000000000000..8472c85c3e20 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SitePatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebApp.json + */ +async function updateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: SitePatchResource = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.update( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +async function main() { + updateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSample.ts index bf76405702f3..5bfd0d2936c8 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { allow: true @@ -37,4 +42,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSlotSample.ts index 4c68d91a5b6b..124d64cf960b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateScmAllowedSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { @@ -39,4 +44,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSlotSample.ts b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSlotSample.ts new file mode 100644 index 000000000000..3be940d1f3b8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples-dev/webAppsUpdateSlotSample.ts @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SitePatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebAppSlot.json + */ +async function updateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: SitePatchResource = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateSlot( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +async function main() { + updateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsGetSample.ts index 77abc1104ccc..ebbb15619c54 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get a workflow run action repetition. * * @summary Get a workflow run action repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_Get.json */ async function getARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -38,4 +44,8 @@ async function getARepetition() { console.log(result); } -getARepetition().catch(console.error); +async function main() { + getARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListExpressionTracesSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListExpressionTracesSample.ts index 1bfb55d6750d..31e854e91773 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListExpressionTracesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListExpressionTracesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Lists a workflow run expression trace. * * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json */ async function listExpressionTracesForARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -41,4 +47,8 @@ async function listExpressionTracesForARepetition() { console.log(resArray); } -listExpressionTracesForARepetition().catch(console.error); +async function main() { + listExpressionTracesForARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListSample.ts index 407ee0e4fcac..c3a7d4d0b3b0 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get all of a workflow run action repetitions. * * @summary Get all of a workflow run action repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_List.json */ async function listRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +45,8 @@ async function listRepetitions() { console.log(resArray); } -listRepetitions().catch(console.error); +async function main() { + listRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesGetSample.ts index 77c5c8f3a8a1..bc68cf8af1b6 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow run repetition request history. * * @summary Gets a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json */ async function getARepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -40,4 +46,8 @@ async function getARepetitionRequestHistory() { console.log(result); } -getARepetitionRequestHistory().catch(console.error); +async function main() { + getARepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesListSample.ts index 118b70159e15..c3db848d54c6 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionRepetitionsRequestHistoriesListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List a workflow run repetition request history. * * @summary List a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json */ async function listRepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -41,4 +47,8 @@ async function listRepetitionRequestHistory() { console.log(resArray); } -listRepetitionRequestHistory().catch(console.error); +async function main() { + listRepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsGetSample.ts index 1521d4cb4e90..91f523ffaadd 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get a workflow run action scoped repetition. * * @summary Get a workflow run action scoped repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_Get.json */ async function getAScopedRepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -38,4 +44,8 @@ async function getAScopedRepetition() { console.log(result); } -getAScopedRepetition().catch(console.error); +async function main() { + getAScopedRepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsListSample.ts index e1138cf92e28..e0d1e575ee86 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionScopeRepetitionsListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List the workflow run action scoped repetitions. * * @summary List the workflow run action scoped repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_List.json */ async function listTheScopedRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +45,8 @@ async function listTheScopedRepetitions() { console.log(resArray); } -listTheScopedRepetitions().catch(console.error); +async function main() { + listTheScopedRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsGetSample.ts index c66f00252bb9..1738062e556d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow run action. * * @summary Gets a workflow run action. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_Get.json */ async function getAWorkflowRunAction() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586676746934337772206998657CU22"; @@ -36,4 +42,8 @@ async function getAWorkflowRunAction() { console.log(result); } -getAWorkflowRunAction().catch(console.error); +async function main() { + getAWorkflowRunAction(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListExpressionTracesSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListExpressionTracesSample.ts index 3dccaf195666..33f29b1684ba 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListExpressionTracesSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListExpressionTracesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Lists a workflow run expression trace. * * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_ListExpressionTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_ListExpressionTraces.json */ async function listExpressionTraces() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +45,8 @@ async function listExpressionTraces() { console.log(resArray); } -listExpressionTraces().catch(console.error); +async function main() { + listExpressionTraces(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListSample.ts index 3127dd17e1a2..5c0b12b48dae 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunActionsListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a list of workflow run actions. * * @summary Gets a list of workflow run actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_List.json */ async function listAWorkflowRunActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586676746934337772206998657CU22"; @@ -37,4 +43,8 @@ async function listAWorkflowRunActions() { console.log(resArray); } -listAWorkflowRunActions().catch(console.error); +async function main() { + listAWorkflowRunActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunsCancelSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunsCancelSample.ts index eb7119705df9..ccebfe60e65e 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunsCancelSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunsCancelSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Cancels a workflow run. * * @summary Cancels a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Cancel.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Cancel.json */ async function cancelAWorkflowRun() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586676746934337772206998657CU22"; @@ -34,4 +40,8 @@ async function cancelAWorkflowRun() { console.log(result); } -cancelAWorkflowRun().catch(console.error); +async function main() { + cancelAWorkflowRun(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunsGetSample.ts index d9f0d49efa67..1cda67b8be96 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow run. * * @summary Gets a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Get.json */ async function getARunForAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586676746934337772206998657CU22"; @@ -34,4 +40,8 @@ async function getARunForAWorkflow() { console.log(result); } -getARunForAWorkflow().catch(console.error); +async function main() { + getARunForAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowRunsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowRunsListSample.ts index 458deb11a011..7df513a093da 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowRunsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowRunsListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a list of workflow runs. * * @summary Gets a list of workflow runs. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_List.json */ async function listWorkflowRuns() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listWorkflowRuns() { console.log(resArray); } -listWorkflowRuns().catch(console.error); +async function main() { + listWorkflowRuns(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesGetSample.ts index cf210b413129..b9912e821eba 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow trigger history. * * @summary Gets a workflow trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Get.json */ async function getAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const triggerName = "testTriggerName"; @@ -36,4 +42,8 @@ async function getAWorkflowTriggerHistory() { console.log(result); } -getAWorkflowTriggerHistory().catch(console.error); +async function main() { + getAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesListSample.ts index 14a50f6d3bfa..f892c803e743 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a list of workflow trigger histories. * * @summary Gets a list of workflow trigger histories. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_List.json */ async function listAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const triggerName = "testTriggerName"; @@ -37,4 +43,8 @@ async function listAWorkflowTriggerHistory() { console.log(resArray); } -listAWorkflowTriggerHistory().catch(console.error); +async function main() { + listAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesResubmitSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesResubmitSample.ts index 430ebfd2048f..4203051c5e3d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesResubmitSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggerHistoriesResubmitSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Resubmits a workflow run based on the trigger history. * * @summary Resubmits a workflow run based on the trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Resubmit.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Resubmit.json */ async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const triggerName = "testTriggerName"; @@ -36,4 +42,8 @@ async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { console.log(result); } -resubmitAWorkflowRunBasedOnTheTriggerHistory().catch(console.error); +async function main() { + resubmitAWorkflowRunBasedOnTheTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSample.ts index 3600946f36e3..aca17ef14bd7 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow trigger. * * @summary Gets a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Get.json */ async function getAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const triggerName = "manual"; @@ -34,4 +40,8 @@ async function getAWorkflowTrigger() { console.log(result); } -getAWorkflowTrigger().catch(console.error); +async function main() { + getAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSchemaJsonSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSchemaJsonSample.ts index c3a8704a6dbd..c56bfb67bd17 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSchemaJsonSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersGetSchemaJsonSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the trigger schema as JSON. * * @summary Get the trigger schema as JSON. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_GetSchemaJson.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_GetSchemaJson.json */ async function getTriggerSchema() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflow"; const triggerName = "testTrigger"; @@ -34,4 +40,8 @@ async function getTriggerSchema() { console.log(result); } -getTriggerSchema().catch(console.error); +async function main() { + getTriggerSchema(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListCallbackUrlSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListCallbackUrlSample.ts index 4f3a018dd8a1..75b70b3c0906 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListCallbackUrlSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListCallbackUrlSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the callback URL for a workflow trigger. * * @summary Get the callback URL for a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_ListCallbackUrl.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_ListCallbackUrl.json */ async function getTheCallbackUrlForATrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const triggerName = "manual"; @@ -34,4 +40,8 @@ async function getTheCallbackUrlForATrigger() { console.log(result); } -getTheCallbackUrlForATrigger().catch(console.error); +async function main() { + getTheCallbackUrlForATrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListSample.ts index f3b47ae11474..1fedaa176b9d 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a list of workflow triggers. * * @summary Gets a list of workflow triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_List.json */ async function listWorkflowTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listWorkflowTriggers() { console.log(resArray); } -listWorkflowTriggers().catch(console.error); +async function main() { + listWorkflowTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersRunSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersRunSample.ts index d67faf74b122..3b0794be75d2 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowTriggersRunSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowTriggersRunSample.ts @@ -10,19 +10,25 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Runs a workflow trigger. * * @summary Runs a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Run.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Run.json */ async function runAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; - const triggerName = "manual"; + const triggerName = "recurrence"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const result = await client.workflowTriggers.beginRunAndWait( @@ -34,4 +40,8 @@ async function runAWorkflowTrigger() { console.log(result); } -runAWorkflowTrigger().catch(console.error); +async function main() { + runAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowVersionsGetSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowVersionsGetSample.ts index 15e226ec220b..f0b0513f6bec 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowVersionsGetSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowVersionsGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow version. * * @summary Gets a workflow version. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_Get.json */ async function getAWorkflowVersion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const versionId = "08586676824806722526"; @@ -34,4 +40,8 @@ async function getAWorkflowVersion() { console.log(result); } -getAWorkflowVersion().catch(console.error); +async function main() { + getAWorkflowVersion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowVersionsListSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowVersionsListSample.ts index 1d6cd9cfc598..9c470ab2260b 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowVersionsListSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowVersionsListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a list of workflow versions. * * @summary Gets a list of workflow versions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_List.json */ async function listAWorkflowsVersions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const credential = new DefaultAzureCredential(); @@ -35,4 +41,8 @@ async function listAWorkflowsVersions() { console.log(resArray); } -listAWorkflowsVersions().catch(console.error); +async function main() { + listAWorkflowsVersions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowsRegenerateAccessKeySample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowsRegenerateAccessKeySample.ts index 5b5157365a33..8148cfcc98c4 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowsRegenerateAccessKeySample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowsRegenerateAccessKeySample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Regenerates the callback URL access key for request triggers. * * @summary Regenerates the callback URL access key for request triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_RegenerateAccessKey.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_RegenerateAccessKey.json */ async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const keyType: RegenerateActionParameter = { keyType: "Primary" }; @@ -37,4 +43,8 @@ async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { console.log(result); } -regenerateTheCallbackUrlAccessKeyForRequestTriggers().catch(console.error); +async function main() { + regenerateTheCallbackUrlAccessKeyForRequestTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples-dev/workflowsValidateSample.ts b/sdk/appservice/arm-appservice/samples-dev/workflowsValidateSample.ts index f9ba1418ff65..2d583747d680 100644 --- a/sdk/appservice/arm-appservice/samples-dev/workflowsValidateSample.ts +++ b/sdk/appservice/arm-appservice/samples-dev/workflowsValidateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { Workflow, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates the workflow definition. * * @summary Validates the workflow definition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_Validate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_Validate.json */ async function validateAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const validate: Workflow = { @@ -45,4 +51,8 @@ async function validateAWorkflow() { console.log(result); } -validateAWorkflow().catch(console.error); +async function main() { + validateAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/README.md b/sdk/appservice/arm-appservice/samples/v13/javascript/README.md deleted file mode 100644 index 3d8a1ddbac3b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/README.md +++ /dev/null @@ -1,626 +0,0 @@ -# client library samples for JavaScript - -These sample programs show how to use the JavaScript client libraries for in some common scenarios. - -| **File Name** | **Description** | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [appServiceCertificateOrdersCreateOrUpdateCertificateSample.js][appservicecertificateorderscreateorupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificate.json | -| [appServiceCertificateOrdersCreateOrUpdateSample.js][appservicecertificateorderscreateorupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersDeleteCertificateSample.js][appservicecertificateordersdeletecertificatesample] | Description for Delete the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificate.json | -| [appServiceCertificateOrdersDeleteSample.js][appservicecertificateordersdeletesample] | Description for Delete an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersGetCertificateSample.js][appservicecertificateordersgetcertificatesample] | Description for Get the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificate.json | -| [appServiceCertificateOrdersGetSample.js][appservicecertificateordersgetsample] | Description for Get a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersListByResourceGroupSample.js][appservicecertificateorderslistbyresourcegroupsample] | Description for Get certificate orders in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json | -| [appServiceCertificateOrdersListCertificatesSample.js][appservicecertificateorderslistcertificatessample] | Description for List all certificates associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListCertificatesByAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersListSample.js][appservicecertificateorderslistsample] | Description for List all certificate orders in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersBySubscription.json | -| [appServiceCertificateOrdersReissueSample.js][appservicecertificateordersreissuesample] | Description for Reissue an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ReissueAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersRenewSample.js][appservicecertificateordersrenewsample] | Description for Renew an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RenewAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersResendEmailSample.js][appservicecertificateordersresendemailsample] | Description for Resend certificate email. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendAppServiceCertificateOrderEmail.json | -| [appServiceCertificateOrdersResendRequestEmailsSample.js][appservicecertificateordersresendrequestemailssample] | Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendDomainOwnershipVerificationEmail.json | -| [appServiceCertificateOrdersRetrieveCertificateActionsSample.js][appservicecertificateordersretrievecertificateactionssample] | Description for Retrieve the list of certificate actions. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateOrderActions.json | -| [appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js][appservicecertificateordersretrievecertificateemailhistorysample] | Description for Retrieve email history. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateEmailHistory.json | -| [appServiceCertificateOrdersRetrieveSiteSealSample.js][appservicecertificateordersretrievesitesealsample] | This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveSiteSeal.json | -| [appServiceCertificateOrdersUpdateCertificateSample.js][appservicecertificateordersupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificate.json | -| [appServiceCertificateOrdersUpdateSample.js][appservicecertificateordersupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersValidatePurchaseInformationSample.js][appservicecertificateordersvalidatepurchaseinformationsample] | Description for Validate information for a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json | -| [appServiceCertificateOrdersVerifyDomainOwnershipSample.js][appservicecertificateordersverifydomainownershipsample] | Description for Verify domain ownership for this certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/VerifyDomainOwnership.json | -| [appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js][appserviceenvironmentsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json | -| [appServiceEnvironmentsChangeVnetSample.js][appserviceenvironmentschangevnetsample] | Description for Move an App Service Environment to a different VNET. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ChangeVnet.json | -| [appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js][appserviceenvironmentscreateorupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | -| [appServiceEnvironmentsCreateOrUpdateSample.js][appserviceenvironmentscreateorupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdate.json | -| [appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js][appserviceenvironmentscreateorupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | -| [appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample] | Delete Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js][appserviceenvironmentsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json | -| [appServiceEnvironmentsDeleteSample.js][appserviceenvironmentsdeletesample] | Description for Delete an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Delete.json | -| [appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsgetasecustomdnssuffixconfigurationsample] | Get Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js][appserviceenvironmentsgetasev3networkingconfigurationsample] | Description for Get networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json | -| [appServiceEnvironmentsGetDiagnosticsItemSample.js][appserviceenvironmentsgetdiagnosticsitemsample] | Description for Get a diagnostics item for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json | -| [appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js][appserviceenvironmentsgetinboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all inbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetInboundNetworkDependenciesEndpoints.json | -| [appServiceEnvironmentsGetMultiRolePoolSample.js][appserviceenvironmentsgetmultirolepoolsample] | Description for Get properties of a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetMultiRolePool.json | -| [appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js][appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all outbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetOutboundNetworkDependenciesEndpoints.json | -| [appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js][appserviceenvironmentsgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoints associated with a hosting environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json | -| [appServiceEnvironmentsGetPrivateEndpointConnectionSample.js][appserviceenvironmentsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json | -| [appServiceEnvironmentsGetPrivateLinkResourcesSample.js][appserviceenvironmentsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json | -| [appServiceEnvironmentsGetSample.js][appserviceenvironmentsgetsample] | Description for Get the properties of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Get.json | -| [appServiceEnvironmentsGetVipInfoSample.js][appserviceenvironmentsgetvipinfosample] | Description for Get IP addresses assigned to an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetVipInfo.json | -| [appServiceEnvironmentsGetWorkerPoolSample.js][appserviceenvironmentsgetworkerpoolsample] | Description for Get properties of a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetWorkerPool.json | -| [appServiceEnvironmentsListAppServicePlansSample.js][appserviceenvironmentslistappserviceplanssample] | Description for Get all App Service plans in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListAppServicePlans.json | -| [appServiceEnvironmentsListByResourceGroupSample.js][appserviceenvironmentslistbyresourcegroupsample] | Description for Get all App Service Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListByResourceGroup.json | -| [appServiceEnvironmentsListCapacitiesSample.js][appserviceenvironmentslistcapacitiessample] | Description for Get the used, available, and total worker capacity an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListCapacities.json | -| [appServiceEnvironmentsListDiagnosticsSample.js][appserviceenvironmentslistdiagnosticssample] | Description for Get diagnostic information for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListDiagnostics.json | -| [appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js][appserviceenvironmentslistmultirolemetricdefinitionssample] | Description for Get metric definitions for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json | -| [appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js][appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json | -| [appServiceEnvironmentsListMultiRolePoolSkusSample.js][appserviceenvironmentslistmultirolepoolskussample] | Description for Get available SKUs for scaling a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json | -| [appServiceEnvironmentsListMultiRolePoolsSample.js][appserviceenvironmentslistmultirolepoolssample] | Description for Get all multi-role pools. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePools.json | -| [appServiceEnvironmentsListMultiRoleUsagesSample.js][appserviceenvironmentslistmultiroleusagessample] | Description for Get usage metrics for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json | -| [appServiceEnvironmentsListOperationsSample.js][appserviceenvironmentslistoperationssample] | Description for List all currently running operations on the App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListOperations.json | -| [appServiceEnvironmentsListSample.js][appserviceenvironmentslistsample] | Description for Get all App Service Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_List.json | -| [appServiceEnvironmentsListUsagesSample.js][appserviceenvironmentslistusagessample] | Description for Get global usage metrics of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListUsages.json | -| [appServiceEnvironmentsListWebAppsSample.js][appserviceenvironmentslistwebappssample] | Description for Get all apps in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebApps.json | -| [appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js][appserviceenvironmentslistwebworkermetricdefinitionssample] | Description for Get metric definitions for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json | -| [appServiceEnvironmentsListWebWorkerUsagesSample.js][appserviceenvironmentslistwebworkerusagessample] | Description for Get usage metrics for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json | -| [appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js][appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json | -| [appServiceEnvironmentsListWorkerPoolSkusSample.js][appserviceenvironmentslistworkerpoolskussample] | Description for Get available SKUs for scaling a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json | -| [appServiceEnvironmentsListWorkerPoolsSample.js][appserviceenvironmentslistworkerpoolssample] | Description for Get all worker pools of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPools.json | -| [appServiceEnvironmentsRebootSample.js][appserviceenvironmentsrebootsample] | Description for Reboot all machines in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Reboot.json | -| [appServiceEnvironmentsResumeSample.js][appserviceenvironmentsresumesample] | Description for Resume an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Resume.json | -| [appServiceEnvironmentsSuspendSample.js][appserviceenvironmentssuspendsample] | Description for Suspend an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Suspend.json | -| [appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js][appserviceenvironmentstestupgradeavailablenotificationsample] | Send a test notification that an upgrade is available for this App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json | -| [appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample] | Update Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js][appserviceenvironmentsupdateasenetworkingconfigurationsample] | Description for Update networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json | -| [appServiceEnvironmentsUpdateMultiRolePoolSample.js][appserviceenvironmentsupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | -| [appServiceEnvironmentsUpdateSample.js][appserviceenvironmentsupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Update.json | -| [appServiceEnvironmentsUpdateWorkerPoolSample.js][appserviceenvironmentsupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | -| [appServiceEnvironmentsUpgradeSample.js][appserviceenvironmentsupgradesample] | Description for Initiate an upgrade of an App Service Environment if one is available. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Upgrade.json | -| [appServicePlansCreateOrUpdateSample.js][appserviceplanscreateorupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateAppServicePlan.json | -| [appServicePlansDeleteSample.js][appserviceplansdeletesample] | Description for Delete an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAppServicePlan.json | -| [appServicePlansGetSample.js][appserviceplansgetsample] | Description for Get an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAppServicePlan.json | -| [appServicePlansListByResourceGroupSample.js][appserviceplanslistbyresourcegroupsample] | Description for Get all App Service plans in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlansByResourceGroup.json | -| [appServicePlansListSample.js][appserviceplanslistsample] | Description for Get all App Service plans for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlans.json | -| [appServicePlansUpdateSample.js][appserviceplansupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchAppServicePlan.json | -| [certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js][certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json | -| [certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js][certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json | -| [certificateRegistrationProviderListOperationsSample.js][certificateregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListOperations.json | -| [certificatesCreateOrUpdateSample.js][certificatescreateorupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateCertificate.json | -| [certificatesDeleteSample.js][certificatesdeletesample] | Description for Delete a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteCertificate.json | -| [certificatesGetSample.js][certificatesgetsample] | Description for Get a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetCertificate.json | -| [certificatesListByResourceGroupSample.js][certificateslistbyresourcegroupsample] | Description for Get all certificates in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificatesByResourceGroup.json | -| [certificatesListSample.js][certificateslistsample] | Description for Get all certificates for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificates.json | -| [certificatesUpdateSample.js][certificatesupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchCertificate.json | -| [containerAppsCreateOrUpdateSample.js][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateContainerApp.json | -| [containerAppsDeleteSample.js][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteContainerApp.json | -| [containerAppsGetSample.js][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetContainerApp.json | -| [containerAppsListByResourceGroupSample.js][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsByResourceGroup.json | -| [containerAppsListBySubscriptionSample.js][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsBySubscription.json | -| [containerAppsListSecretsSample.js][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppSecrets.json | -| [containerAppsRevisionsActivateRevisionSample.js][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ActivateRevision.json | -| [containerAppsRevisionsDeactivateRevisionSample.js][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeactivateRevision.json | -| [containerAppsRevisionsGetRevisionSample.js][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetRevision.json | -| [containerAppsRevisionsListRevisionsSample.js][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListRevisions.json | -| [containerAppsRevisionsRestartRevisionSample.js][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RestartRevision.json | -| [deletedWebAppsGetDeletedWebAppByLocationSample.js][deletedwebappsgetdeletedwebappbylocationsample] | Description for Get deleted app for a subscription at location. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppByLocation.json | -| [deletedWebAppsListByLocationSample.js][deletedwebappslistbylocationsample] | Description for Get all deleted apps for a subscription at location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListDeletedWebAppsByLocation.json | -| [diagnosticsExecuteSiteAnalysisSample.js][diagnosticsexecutesiteanalysissample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json | -| [diagnosticsExecuteSiteAnalysisSlotSample.js][diagnosticsexecutesiteanalysisslotsample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json | -| [diagnosticsExecuteSiteDetectorSample.js][diagnosticsexecutesitedetectorsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json | -| [diagnosticsExecuteSiteDetectorSlotSample.js][diagnosticsexecutesitedetectorslotsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json | -| [diagnosticsGetHostingEnvironmentDetectorResponseSample.js][diagnosticsgethostingenvironmentdetectorresponsesample] | Description for Get Hosting Environment Detector Response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json | -| [diagnosticsGetSiteAnalysisSample.js][diagnosticsgetsiteanalysissample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json | -| [diagnosticsGetSiteAnalysisSlotSample.js][diagnosticsgetsiteanalysisslotsample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json | -| [diagnosticsGetSiteDetectorResponseSample.js][diagnosticsgetsitedetectorresponsesample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json | -| [diagnosticsGetSiteDetectorResponseSlotSample.js][diagnosticsgetsitedetectorresponseslotsample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json | -| [diagnosticsGetSiteDetectorSample.js][diagnosticsgetsitedetectorsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json | -| [diagnosticsGetSiteDetectorSlotSample.js][diagnosticsgetsitedetectorslotsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json | -| [diagnosticsGetSiteDiagnosticCategorySample.js][diagnosticsgetsitediagnosticcategorysample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | -| [diagnosticsGetSiteDiagnosticCategorySlotSample.js][diagnosticsgetsitediagnosticcategoryslotsample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | -| [diagnosticsListHostingEnvironmentDetectorResponsesSample.js][diagnosticslisthostingenvironmentdetectorresponsessample] | Description for List Hosting Environment Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json | -| [diagnosticsListSiteAnalysesSample.js][diagnosticslistsiteanalysessample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json | -| [diagnosticsListSiteAnalysesSlotSample.js][diagnosticslistsiteanalysesslotsample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json | -| [diagnosticsListSiteDetectorResponsesSample.js][diagnosticslistsitedetectorresponsessample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json | -| [diagnosticsListSiteDetectorResponsesSlotSample.js][diagnosticslistsitedetectorresponsesslotsample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json | -| [diagnosticsListSiteDetectorsSample.js][diagnosticslistsitedetectorssample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json | -| [diagnosticsListSiteDetectorsSlotSample.js][diagnosticslistsitedetectorsslotsample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json | -| [diagnosticsListSiteDiagnosticCategoriesSample.js][diagnosticslistsitediagnosticcategoriessample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | -| [diagnosticsListSiteDiagnosticCategoriesSlotSample.js][diagnosticslistsitediagnosticcategoriesslotsample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | -| [domainRegistrationProviderListOperationsSample.js][domainregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListOperations.json | -| [domainsCheckAvailabilitySample.js][domainscheckavailabilitysample] | Description for Check if a domain is available for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CheckDomainAvailability.json | -| [domainsCreateOrUpdateOwnershipIdentifierSample.js][domainscreateorupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomainOwnershipIdentifier.json | -| [domainsCreateOrUpdateSample.js][domainscreateorupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomain.json | -| [domainsDeleteOwnershipIdentifierSample.js][domainsdeleteownershipidentifiersample] | Description for Delete ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json | -| [domainsDeleteSample.js][domainsdeletesample] | Description for Delete a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomain.json | -| [domainsGetControlCenterSsoRequestSample.js][domainsgetcontrolcenterssorequestsample] | Description for Generate a single sign-on request for the domain management portal. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainControlCenterSsoRequest.json | -| [domainsGetOwnershipIdentifierSample.js][domainsgetownershipidentifiersample] | Description for Get ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainOwnershipIdentifier.json | -| [domainsGetSample.js][domainsgetsample] | Description for Get a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomain.json | -| [domainsListByResourceGroupSample.js][domainslistbyresourcegroupsample] | Description for Get all domains in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsByResourceGroup.json | -| [domainsListOwnershipIdentifiersSample.js][domainslistownershipidentifierssample] | Description for Lists domain ownership identifiers. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainOwnershipIdentifiers.json | -| [domainsListRecommendationsSample.js][domainslistrecommendationssample] | Description for Get domain name recommendations based on keywords. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainRecommendations.json | -| [domainsListSample.js][domainslistsample] | Description for Get all domains in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsBySubscription.json | -| [domainsRenewSample.js][domainsrenewsample] | Description for Renew a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/RenewDomain.json | -| [domainsTransferOutSample.js][domainstransferoutsample] | Transfer out domain to another registrar x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/TransferOutDomain.json | -| [domainsUpdateOwnershipIdentifierSample.js][domainsupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json | -| [domainsUpdateSample.js][domainsupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomain.json | -| [globalGetDeletedWebAppSample.js][globalgetdeletedwebappsample] | Description for Get deleted app for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebApp.json | -| [globalGetDeletedWebAppSnapshotsSample.js][globalgetdeletedwebappsnapshotssample] | Description for Get all deleted apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppSnapshots.json | -| [globalGetSubscriptionOperationWithAsyncResponseSample.js][globalgetsubscriptionoperationwithasyncresponsesample] | Description for Gets an operation in a subscription and given region x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSubscriptionOperationWithAsyncResponse.json | -| [kubeEnvironmentsCreateOrUpdateSample.js][kubeenvironmentscreateorupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_CreateOrUpdate.json | -| [kubeEnvironmentsDeleteSample.js][kubeenvironmentsdeletesample] | Description for Delete a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Delete.json | -| [kubeEnvironmentsGetSample.js][kubeenvironmentsgetsample] | Description for Get the properties of a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Get.json | -| [kubeEnvironmentsListByResourceGroupSample.js][kubeenvironmentslistbyresourcegroupsample] | Description for Get all the Kubernetes Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListByResourceGroup.json | -| [kubeEnvironmentsListBySubscriptionSample.js][kubeenvironmentslistbysubscriptionsample] | Description for Get all Kubernetes Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListBySubscription.json | -| [kubeEnvironmentsUpdateSample.js][kubeenvironmentsupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Update.json | -| [listCustomHostNameSitesSample.js][listcustomhostnamesitessample] | Get custom hostnames under this subscription x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomHostNameSites.json | -| [providerGetFunctionAppStacksForLocationSample.js][providergetfunctionappstacksforlocationsample] | Description for Get available Function app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacksForLocation.json | -| [providerGetFunctionAppStacksSample.js][providergetfunctionappstackssample] | Description for Get available Function app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacks.json | -| [providerGetWebAppStacksForLocationSample.js][providergetwebappstacksforlocationsample] | Description for Get available Web app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacksForLocation.json | -| [providerGetWebAppStacksSample.js][providergetwebappstackssample] | Description for Get available Web app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacks.json | -| [providerListOperationsSample.js][providerlistoperationssample] | Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListOperations.json | -| [resourceHealthMetadataGetBySiteSample.js][resourcehealthmetadatagetbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json | -| [resourceHealthMetadataGetBySiteSlotSample.js][resourcehealthmetadatagetbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListByResourceGroupSample.js][resourcehealthmetadatalistbyresourcegroupsample] | Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataByResourceGroup.json | -| [resourceHealthMetadataListBySiteSample.js][resourcehealthmetadatalistbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListBySiteSlotSample.js][resourcehealthmetadatalistbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListSample.js][resourcehealthmetadatalistsample] | Description for List all ResourceHealthMetadata for all sites in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySubscription.json | -| [staticSitesApproveOrRejectPrivateEndpointConnectionSample.js][staticsitesapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json | -| [staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js][staticsitescreateorupdatestaticsiteappsettingssample] | Description for Creates or updates the app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js][staticsitescreateorupdatestaticsitebuildappsettingssample] | Description for Creates or updates the app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js][staticsitescreateorupdatestaticsitebuildfunctionappsettingssample] | Description for Creates or updates the function app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js][staticsitescreateorupdatestaticsitecustomdomainsample] | Description for Creates a new static site custom domain in an existing resource group and static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteCustomDomain.json | -| [staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js][staticsitescreateorupdatestaticsitefunctionappsettingssample] | Description for Creates or updates the function app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteSample.js][staticsitescreateorupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSite.json | -| [staticSitesCreateUserRolesInvitationLinkSample.js][staticsitescreateuserrolesinvitationlinksample] | Description for Creates an invitation link for a user with the role x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateUserRolesInvitationLink.json | -| [staticSitesCreateZipDeploymentForStaticSiteBuildSample.js][staticsitescreatezipdeploymentforstaticsitebuildsample] | Description for Deploys zipped content to a specific environment of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteBuildZipDeploy.json | -| [staticSitesCreateZipDeploymentForStaticSiteSample.js][staticsitescreatezipdeploymentforstaticsitesample] | Description for Deploys zipped content to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteZipDeploy.json | -| [staticSitesDeletePrivateEndpointConnectionSample.js][staticsitesdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json | -| [staticSitesDeleteStaticSiteBuildSample.js][staticsitesdeletestaticsitebuildsample] | Description for Deletes a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteBuild.json | -| [staticSitesDeleteStaticSiteCustomDomainSample.js][staticsitesdeletestaticsitecustomdomainsample] | Description for Deletes a custom domain. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteCustomDomain.json | -| [staticSitesDeleteStaticSiteSample.js][staticsitesdeletestaticsitesample] | Description for Deletes a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSite.json | -| [staticSitesDeleteStaticSiteUserSample.js][staticsitesdeletestaticsiteusersample] | Description for Deletes the user entry from the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteUser.json | -| [staticSitesDetachStaticSiteSample.js][staticsitesdetachstaticsitesample] | Description for Detaches a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachStaticSite.json | -| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js][staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample] | Description for Detach the user provided function app from the static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json | -| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js][staticsitesdetachuserprovidedfunctionappfromstaticsitesample] | Description for Detach the user provided function app from the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json | -| [staticSitesGetLinkedBackendForBuildSample.js][staticsitesgetlinkedbackendforbuildsample] | Returns the details of a linked backend linked to a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSiteBuild.json | -| [staticSitesGetLinkedBackendSample.js][staticsitesgetlinkedbackendsample] | Returns the details of a linked backend linked to a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSite.json | -| [staticSitesGetLinkedBackendsForBuildSample.js][staticsitesgetlinkedbackendsforbuildsample] | Returns details of all backends linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSiteBuild.json | -| [staticSitesGetLinkedBackendsSample.js][staticsitesgetlinkedbackendssample] | Returns details of all backends linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSite.json | -| [staticSitesGetPrivateEndpointConnectionListSample.js][staticsitesgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoint connections associated with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionList.json | -| [staticSitesGetPrivateEndpointConnectionSample.js][staticsitesgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json | -| [staticSitesGetPrivateLinkResourcesSample.js][staticsitesgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json | -| [staticSitesGetStaticSiteBuildSample.js][staticsitesgetstaticsitebuildsample] | Description for Gets the details of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuild.json | -| [staticSitesGetStaticSiteBuildsSample.js][staticsitesgetstaticsitebuildssample] | Description for Gets all static site builds for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuilds.json | -| [staticSitesGetStaticSiteCustomDomainSample.js][staticsitesgetstaticsitecustomdomainsample] | Description for Gets an existing custom domain for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomain.json | -| [staticSitesGetStaticSiteSample.js][staticsitesgetstaticsitesample] | Description for Gets the details of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSite.json | -| [staticSitesGetStaticSitesByResourceGroupSample.js][staticsitesgetstaticsitesbyresourcegroupsample] | Description for Gets all static sites in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSites.json | -| [staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js][staticsitesgetuserprovidedfunctionappforstaticsitebuildsample] | Description for Gets the details of the user provided function app registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json | -| [staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js][staticsitesgetuserprovidedfunctionappforstaticsitesample] | Description for Gets the details of the user provided function app registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSite.json | -| [staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js][staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample] | Description for Gets the details of the user provided function apps registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json | -| [staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js][staticsitesgetuserprovidedfunctionappsforstaticsitesample] | Description for Gets the details of the user provided function apps registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSite.json | -| [staticSitesLinkBackendSample.js][staticsiteslinkbackendsample] | Link backend to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSite.json | -| [staticSitesLinkBackendToBuildSample.js][staticsiteslinkbackendtobuildsample] | Link backend to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSiteBuild.json | -| [staticSitesListSample.js][staticsiteslistsample] | Description for Get all Static Sites for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAllStaticSites.json | -| [staticSitesListStaticSiteAppSettingsSample.js][staticsitesliststaticsiteappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteAppSettings.json | -| [staticSitesListStaticSiteBuildAppSettingsSample.js][staticsitesliststaticsitebuildappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildAppSettings.json | -| [staticSitesListStaticSiteBuildFunctionAppSettingsSample.js][staticsitesliststaticsitebuildfunctionappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctionAppSettings.json | -| [staticSitesListStaticSiteBuildFunctionsSample.js][staticsitesliststaticsitebuildfunctionssample] | Description for Gets the functions of a particular static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctions.json | -| [staticSitesListStaticSiteConfiguredRolesSample.js][staticsitesliststaticsiteconfiguredrolessample] | Description for Lists the roles configured for the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteConfiguredRoles.json | -| [staticSitesListStaticSiteCustomDomainsSample.js][staticsitesliststaticsitecustomdomainssample] | Description for Gets all static site custom domains for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomains.json | -| [staticSitesListStaticSiteFunctionAppSettingsSample.js][staticsitesliststaticsitefunctionappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctionAppSettings.json | -| [staticSitesListStaticSiteFunctionsSample.js][staticsitesliststaticsitefunctionssample] | Description for Gets the functions of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctions.json | -| [staticSitesListStaticSiteSecretsSample.js][staticsitesliststaticsitesecretssample] | Description for Lists the secrets for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteSecrets.json | -| [staticSitesListStaticSiteUsersSample.js][staticsitesliststaticsiteuserssample] | Description for Gets the list of users of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteUsers.json | -| [staticSitesPreviewWorkflowSample.js][staticsitespreviewworkflowsample] | Description for Generates a preview workflow file for the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GenerateStaticSiteWorkflowPreview.json | -| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js][staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample] | Description for Register a user provided function app with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json | -| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js][staticsitesregisteruserprovidedfunctionappwithstaticsitesample] | Description for Register a user provided function app with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json | -| [staticSitesResetStaticSiteApiKeySample.js][staticsitesresetstaticsiteapikeysample] | Description for Resets the api key for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ResetStaticSiteApiKey.json | -| [staticSitesUnlinkBackendFromBuildSample.js][staticsitesunlinkbackendfrombuildsample] | Unlink a backend from a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSiteBuild.json | -| [staticSitesUnlinkBackendSample.js][staticsitesunlinkbackendsample] | Unlink a backend from a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSite.json | -| [staticSitesUpdateStaticSiteSample.js][staticsitesupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchStaticSite.json | -| [staticSitesUpdateStaticSiteUserSample.js][staticsitesupdatestaticsiteusersample] | Description for Updates a user entry with the listed roles x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateStaticSiteUser.json | -| [staticSitesValidateBackendForBuildSample.js][staticsitesvalidatebackendforbuildsample] | Validates that a backend can be linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSiteBuild.json | -| [staticSitesValidateBackendSample.js][staticsitesvalidatebackendsample] | Validates that a backend can be linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSite.json | -| [staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js][staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample] | Description for Validates a particular custom domain can be added to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateStaticSiteCustomDomain.json | -| [topLevelDomainsGetSample.js][topleveldomainsgetsample] | Description for Get details of a top-level domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetTopLevelDomain.json | -| [topLevelDomainsListAgreementsSample.js][topleveldomainslistagreementssample] | Description for Gets all legal agreements that user needs to accept before purchasing a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomainAgreements.json | -| [topLevelDomainsListSample.js][topleveldomainslistsample] | Description for Get all top-level domains supported for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomains.json | -| [verifyHostingEnvironmentVnetSample.js][verifyhostingenvironmentvnetsample] | Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/VerifyHostingEnvironmentVnet.json | -| [webAppsApproveOrRejectPrivateEndpointConnectionSample.js][webappsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json | -| [webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js][webappsapproveorrejectprivateendpointconnectionslotsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json | -| [webAppsDeletePrivateEndpointConnectionSample.js][webappsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json | -| [webAppsDeletePrivateEndpointConnectionSlotSample.js][webappsdeleteprivateendpointconnectionslotsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnectionSlot.json | -| [webAppsGetAppSettingKeyVaultReferenceSample.js][webappsgetappsettingkeyvaultreferencesample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSetting.json | -| [webAppsGetAppSettingKeyVaultReferenceSlotSample.js][webappsgetappsettingkeyvaultreferenceslotsample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingSlot.json | -| [webAppsGetAppSettingsKeyVaultReferencesSample.js][webappsgetappsettingskeyvaultreferencessample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettings.json | -| [webAppsGetAppSettingsKeyVaultReferencesSlotSample.js][webappsgetappsettingskeyvaultreferencesslotsample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json | -| [webAppsGetFtpAllowedSample.js][webappsgetftpallowedsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json | -| [webAppsGetFtpAllowedSlotSample.js][webappsgetftpallowedslotsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json | -| [webAppsGetInstanceInfoSample.js][webappsgetinstanceinfosample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json | -| [webAppsGetInstanceInfoSlotSample.js][webappsgetinstanceinfoslotsample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json | -| [webAppsGetNetworkTraceOperationSample.js][webappsgetnetworktraceoperationsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationSlotSample.js][webappsgetnetworktraceoperationslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationSlotV2Sample.js][webappsgetnetworktraceoperationslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationV2Sample.js][webappsgetnetworktraceoperationv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTracesSample.js][webappsgetnetworktracessample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesSlotSample.js][webappsgetnetworktracesslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesSlotV2Sample.js][webappsgetnetworktracesslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesV2Sample.js][webappsgetnetworktracesv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetPrivateEndpointConnectionSample.js][webappsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json | -| [webAppsGetPrivateEndpointConnectionSlotSample.js][webappsgetprivateendpointconnectionslotsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionSlot.json | -| [webAppsGetPrivateLinkResourcesSample.js][webappsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json | -| [webAppsGetPrivateLinkResourcesSlotSample.js][webappsgetprivatelinkresourcesslotsample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResourcesSlot.json | -| [webAppsGetProductionSiteDeploymentStatusSample.js][webappsgetproductionsitedeploymentstatussample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatus.json | -| [webAppsGetScmAllowedSample.js][webappsgetscmallowedsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json | -| [webAppsGetScmAllowedSlotSample.js][webappsgetscmallowedslotsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json | -| [webAppsGetSlotSiteDeploymentStatusSlotSample.js][webappsgetslotsitedeploymentstatusslotsample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatusSlot.json | -| [webAppsListBasicPublishingCredentialsPoliciesSample.js][webappslistbasicpublishingcredentialspoliciessample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPolicies.json | -| [webAppsListBasicPublishingCredentialsPoliciesSlotSample.js][webappslistbasicpublishingcredentialspoliciesslotsample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPoliciesSlot.json | -| [webAppsListProductionSiteDeploymentStatusesSample.js][webappslistproductionsitedeploymentstatusessample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatus.json | -| [webAppsListSiteBackupsSample.js][webappslistsitebackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json | -| [webAppsListSiteBackupsSlotSample.js][webappslistsitebackupsslotsample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json | -| [webAppsListSlotSiteDeploymentStatusesSlotSample.js][webappslistslotsitedeploymentstatusesslotsample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatusSlot.json | -| [webAppsStartNetworkTraceSample.js][webappsstartnetworktracesample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartNetworkTraceSlotSample.js][webappsstartnetworktraceslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartWebSiteNetworkTraceOperationSample.js][webappsstartwebsitenetworktraceoperationsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartWebSiteNetworkTraceOperationSlotSample.js][webappsstartwebsitenetworktraceoperationslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStopNetworkTraceSample.js][webappsstopnetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopNetworkTraceSlotSample.js][webappsstopnetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopWebSiteNetworkTraceSample.js][webappsstopwebsitenetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopWebSiteNetworkTraceSlotSample.js][webappsstopwebsitenetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsUpdateFtpAllowedSample.js][webappsupdateftpallowedsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json | -| [webAppsUpdateFtpAllowedSlotSample.js][webappsupdateftpallowedslotsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json | -| [webAppsUpdateScmAllowedSample.js][webappsupdatescmallowedsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json | -| [webAppsUpdateScmAllowedSlotSample.js][webappsupdatescmallowedslotsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json | -| [workflowRunActionRepetitionsGetSample.js][workflowrunactionrepetitionsgetsample] | Get a workflow run action repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_Get.json | -| [workflowRunActionRepetitionsListExpressionTracesSample.js][workflowrunactionrepetitionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json | -| [workflowRunActionRepetitionsListSample.js][workflowrunactionrepetitionslistsample] | Get all of a workflow run action repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_List.json | -| [workflowRunActionRepetitionsRequestHistoriesGetSample.js][workflowrunactionrepetitionsrequesthistoriesgetsample] | Gets a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json | -| [workflowRunActionRepetitionsRequestHistoriesListSample.js][workflowrunactionrepetitionsrequesthistorieslistsample] | List a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json | -| [workflowRunActionScopeRepetitionsGetSample.js][workflowrunactionscoperepetitionsgetsample] | Get a workflow run action scoped repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_Get.json | -| [workflowRunActionScopeRepetitionsListSample.js][workflowrunactionscoperepetitionslistsample] | List the workflow run action scoped repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_List.json | -| [workflowRunActionsGetSample.js][workflowrunactionsgetsample] | Gets a workflow run action. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_Get.json | -| [workflowRunActionsListExpressionTracesSample.js][workflowrunactionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_ListExpressionTraces.json | -| [workflowRunActionsListSample.js][workflowrunactionslistsample] | Gets a list of workflow run actions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_List.json | -| [workflowRunsCancelSample.js][workflowrunscancelsample] | Cancels a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Cancel.json | -| [workflowRunsGetSample.js][workflowrunsgetsample] | Gets a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Get.json | -| [workflowRunsListSample.js][workflowrunslistsample] | Gets a list of workflow runs. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_List.json | -| [workflowTriggerHistoriesGetSample.js][workflowtriggerhistoriesgetsample] | Gets a workflow trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Get.json | -| [workflowTriggerHistoriesListSample.js][workflowtriggerhistorieslistsample] | Gets a list of workflow trigger histories. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_List.json | -| [workflowTriggerHistoriesResubmitSample.js][workflowtriggerhistoriesresubmitsample] | Resubmits a workflow run based on the trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Resubmit.json | -| [workflowTriggersGetSample.js][workflowtriggersgetsample] | Gets a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Get.json | -| [workflowTriggersGetSchemaJsonSample.js][workflowtriggersgetschemajsonsample] | Get the trigger schema as JSON. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_GetSchemaJson.json | -| [workflowTriggersListCallbackUrlSample.js][workflowtriggerslistcallbackurlsample] | Get the callback URL for a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_ListCallbackUrl.json | -| [workflowTriggersListSample.js][workflowtriggerslistsample] | Gets a list of workflow triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_List.json | -| [workflowTriggersRunSample.js][workflowtriggersrunsample] | Runs a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Run.json | -| [workflowVersionsGetSample.js][workflowversionsgetsample] | Gets a workflow version. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_Get.json | -| [workflowVersionsListSample.js][workflowversionslistsample] | Gets a list of workflow versions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_List.json | -| [workflowsRegenerateAccessKeySample.js][workflowsregenerateaccesskeysample] | Regenerates the callback URL access key for request triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_RegenerateAccessKey.json | -| [workflowsValidateSample.js][workflowsvalidatesample] | Validates the workflow definition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_Validate.json | - -## Prerequisites - -The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule). - -You need [an Azure subscription][freesub] to run these sample programs. - -Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function. - -Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package]. - -## Setup - -To run the samples using the published version of the package: - -1. Install the dependencies using `npm`: - -```bash -npm install -``` - -2. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically. - -3. Run whichever samples you like (note that some samples may require additional setup, see the table above): - -```bash -node appServiceCertificateOrdersCreateOrUpdateCertificateSample.js -``` - -Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): - -```bash -npx cross-env node appServiceCertificateOrdersCreateOrUpdateCertificateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[appservicecertificateorderscreateorupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js -[appservicecertificateorderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js -[appservicecertificateordersdeletecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteCertificateSample.js -[appservicecertificateordersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteSample.js -[appservicecertificateordersgetcertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetCertificateSample.js -[appservicecertificateordersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetSample.js -[appservicecertificateorderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListByResourceGroupSample.js -[appservicecertificateorderslistcertificatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListCertificatesSample.js -[appservicecertificateorderslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListSample.js -[appservicecertificateordersreissuesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersReissueSample.js -[appservicecertificateordersrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRenewSample.js -[appservicecertificateordersresendemailsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendEmailSample.js -[appservicecertificateordersresendrequestemailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js -[appservicecertificateordersretrievecertificateactionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js -[appservicecertificateordersretrievecertificateemailhistorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js -[appservicecertificateordersretrievesitesealsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js -[appservicecertificateordersupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateCertificateSample.js -[appservicecertificateordersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateSample.js -[appservicecertificateordersvalidatepurchaseinformationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js -[appservicecertificateordersverifydomainownershipsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js -[appserviceenvironmentsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js -[appserviceenvironmentschangevnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsChangeVnetSample.js -[appserviceenvironmentscreateorupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js -[appserviceenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateSample.js -[appserviceenvironmentscreateorupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js -[appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js -[appserviceenvironmentsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js -[appserviceenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteSample.js -[appserviceenvironmentsgetasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js -[appserviceenvironmentsgetasev3networkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js -[appserviceenvironmentsgetdiagnosticsitemsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js -[appserviceenvironmentsgetinboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js -[appserviceenvironmentsgetmultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js -[appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js -[appserviceenvironmentsgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js -[appserviceenvironmentsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js -[appserviceenvironmentsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js -[appserviceenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetSample.js -[appserviceenvironmentsgetvipinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetVipInfoSample.js -[appserviceenvironmentsgetworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetWorkerPoolSample.js -[appserviceenvironmentslistappserviceplanssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListAppServicePlansSample.js -[appserviceenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListByResourceGroupSample.js -[appserviceenvironmentslistcapacitiessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListCapacitiesSample.js -[appserviceenvironmentslistdiagnosticssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListDiagnosticsSample.js -[appserviceenvironmentslistmultirolemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js -[appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js -[appserviceenvironmentslistmultirolepoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js -[appserviceenvironmentslistmultirolepoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js -[appserviceenvironmentslistmultiroleusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js -[appserviceenvironmentslistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListOperationsSample.js -[appserviceenvironmentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListSample.js -[appserviceenvironmentslistusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListUsagesSample.js -[appserviceenvironmentslistwebappssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebAppsSample.js -[appserviceenvironmentslistwebworkermetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js -[appserviceenvironmentslistwebworkerusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js -[appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js -[appserviceenvironmentslistworkerpoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js -[appserviceenvironmentslistworkerpoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolsSample.js -[appserviceenvironmentsrebootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsRebootSample.js -[appserviceenvironmentsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsResumeSample.js -[appserviceenvironmentssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsSuspendSample.js -[appserviceenvironmentstestupgradeavailablenotificationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js -[appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js -[appserviceenvironmentsupdateasenetworkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js -[appserviceenvironmentsupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js -[appserviceenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateSample.js -[appserviceenvironmentsupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js -[appserviceenvironmentsupgradesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpgradeSample.js -[appserviceplanscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansCreateOrUpdateSample.js -[appserviceplansdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansDeleteSample.js -[appserviceplansgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansGetSample.js -[appserviceplanslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListByResourceGroupSample.js -[appserviceplanslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListSample.js -[appserviceplansupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansUpdateSample.js -[certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js -[certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js -[certificateregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificateRegistrationProviderListOperationsSample.js -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesCreateOrUpdateSample.js -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesDeleteSample.js -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesGetSample.js -[certificateslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListByResourceGroupSample.js -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListSample.js -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesUpdateSample.js -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsCreateOrUpdateSample.js -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsDeleteSample.js -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsGetSample.js -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListByResourceGroupSample.js -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListBySubscriptionSample.js -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListSecretsSample.js -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsActivateRevisionSample.js -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsDeactivateRevisionSample.js -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsGetRevisionSample.js -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsListRevisionsSample.js -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsRestartRevisionSample.js -[deletedwebappsgetdeletedwebappbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js -[deletedwebappslistbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsListByLocationSample.js -[diagnosticsexecutesiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSample.js -[diagnosticsexecutesiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js -[diagnosticsexecutesitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSample.js -[diagnosticsexecutesitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSlotSample.js -[diagnosticsgethostingenvironmentdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js -[diagnosticsgetsiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSample.js -[diagnosticsgetsiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSlotSample.js -[diagnosticsgetsitedetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSample.js -[diagnosticsgetsitedetectorresponseslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js -[diagnosticsgetsitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSample.js -[diagnosticsgetsitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSlotSample.js -[diagnosticsgetsitediagnosticcategorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySample.js -[diagnosticsgetsitediagnosticcategoryslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js -[diagnosticslisthostingenvironmentdetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js -[diagnosticslistsiteanalysessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSample.js -[diagnosticslistsiteanalysesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSlotSample.js -[diagnosticslistsitedetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSample.js -[diagnosticslistsitedetectorresponsesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js -[diagnosticslistsitedetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSample.js -[diagnosticslistsitedetectorsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSlotSample.js -[diagnosticslistsitediagnosticcategoriessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js -[diagnosticslistsitediagnosticcategoriesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js -[domainregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainRegistrationProviderListOperationsSample.js -[domainscheckavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCheckAvailabilitySample.js -[domainscreateorupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js -[domainscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateSample.js -[domainsdeleteownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteOwnershipIdentifierSample.js -[domainsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteSample.js -[domainsgetcontrolcenterssorequestsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetControlCenterSsoRequestSample.js -[domainsgetownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetOwnershipIdentifierSample.js -[domainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetSample.js -[domainslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListByResourceGroupSample.js -[domainslistownershipidentifierssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListOwnershipIdentifiersSample.js -[domainslistrecommendationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListRecommendationsSample.js -[domainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListSample.js -[domainsrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsRenewSample.js -[domainstransferoutsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsTransferOutSample.js -[domainsupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateOwnershipIdentifierSample.js -[domainsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateSample.js -[globalgetdeletedwebappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSample.js -[globalgetdeletedwebappsnapshotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSnapshotsSample.js -[globalgetsubscriptionoperationwithasyncresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js -[kubeenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsCreateOrUpdateSample.js -[kubeenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsDeleteSample.js -[kubeenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsGetSample.js -[kubeenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListByResourceGroupSample.js -[kubeenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListBySubscriptionSample.js -[kubeenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsUpdateSample.js -[listcustomhostnamesitessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/listCustomHostNameSitesSample.js -[providergetfunctionappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksForLocationSample.js -[providergetfunctionappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksSample.js -[providergetwebappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksForLocationSample.js -[providergetwebappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksSample.js -[providerlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/providerListOperationsSample.js -[resourcehealthmetadatagetbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSample.js -[resourcehealthmetadatagetbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSlotSample.js -[resourcehealthmetadatalistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListByResourceGroupSample.js -[resourcehealthmetadatalistbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSample.js -[resourcehealthmetadatalistbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSlotSample.js -[resourcehealthmetadatalistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListSample.js -[staticsitesapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js -[staticsitescreateorupdatestaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js -[staticsitescreateorupdatestaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js -[staticsitescreateorupdatestaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js -[staticsitescreateorupdatestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js -[staticsitescreateorupdatestaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js -[staticsitescreateorupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteSample.js -[staticsitescreateuserrolesinvitationlinksample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateUserRolesInvitationLinkSample.js -[staticsitescreatezipdeploymentforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js -[staticsitescreatezipdeploymentforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js -[staticsitesdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeletePrivateEndpointConnectionSample.js -[staticsitesdeletestaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteBuildSample.js -[staticsitesdeletestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js -[staticsitesdeletestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteSample.js -[staticsitesdeletestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteUserSample.js -[staticsitesdetachstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachStaticSiteSample.js -[staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js -[staticsitesdetachuserprovidedfunctionappfromstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js -[staticsitesgetlinkedbackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendForBuildSample.js -[staticsitesgetlinkedbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendSample.js -[staticsitesgetlinkedbackendsforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsForBuildSample.js -[staticsitesgetlinkedbackendssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsSample.js -[staticsitesgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionListSample.js -[staticsitesgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionSample.js -[staticsitesgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateLinkResourcesSample.js -[staticsitesgetstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildSample.js -[staticsitesgetstaticsitebuildssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildsSample.js -[staticsitesgetstaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteCustomDomainSample.js -[staticsitesgetstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteSample.js -[staticsitesgetstaticsitesbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSitesByResourceGroupSample.js -[staticsitesgetuserprovidedfunctionappforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js -[staticsitesgetuserprovidedfunctionappforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js -[staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js -[staticsitesgetuserprovidedfunctionappsforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js -[staticsiteslinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendSample.js -[staticsiteslinkbackendtobuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendToBuildSample.js -[staticsiteslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListSample.js -[staticsitesliststaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteAppSettingsSample.js -[staticsitesliststaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js -[staticsitesliststaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js -[staticsitesliststaticsitebuildfunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionsSample.js -[staticsitesliststaticsiteconfiguredrolessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteConfiguredRolesSample.js -[staticsitesliststaticsitecustomdomainssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteCustomDomainsSample.js -[staticsitesliststaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js -[staticsitesliststaticsitefunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionsSample.js -[staticsitesliststaticsitesecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteSecretsSample.js -[staticsitesliststaticsiteuserssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteUsersSample.js -[staticsitespreviewworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesPreviewWorkflowSample.js -[staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js -[staticsitesregisteruserprovidedfunctionappwithstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js -[staticsitesresetstaticsiteapikeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesResetStaticSiteApiKeySample.js -[staticsitesunlinkbackendfrombuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendFromBuildSample.js -[staticsitesunlinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendSample.js -[staticsitesupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteSample.js -[staticsitesupdatestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteUserSample.js -[staticsitesvalidatebackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendForBuildSample.js -[staticsitesvalidatebackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendSample.js -[staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js -[topleveldomainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsGetSample.js -[topleveldomainslistagreementssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListAgreementsSample.js -[topleveldomainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListSample.js -[verifyhostingenvironmentvnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/verifyHostingEnvironmentVnetSample.js -[webappsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js -[webappsapproveorrejectprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js -[webappsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSample.js -[webappsdeleteprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js -[webappsgetappsettingkeyvaultreferencesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js -[webappsgetappsettingkeyvaultreferenceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js -[webappsgetappsettingskeyvaultreferencessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js -[webappsgetappsettingskeyvaultreferencesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js -[webappsgetftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSample.js -[webappsgetftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSlotSample.js -[webappsgetinstanceinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSample.js -[webappsgetinstanceinfoslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSlotSample.js -[webappsgetnetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSample.js -[webappsgetnetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotSample.js -[webappsgetnetworktraceoperationslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js -[webappsgetnetworktraceoperationv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationV2Sample.js -[webappsgetnetworktracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSample.js -[webappsgetnetworktracesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotSample.js -[webappsgetnetworktracesslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotV2Sample.js -[webappsgetnetworktracesv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesV2Sample.js -[webappsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSample.js -[webappsgetprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js -[webappsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSample.js -[webappsgetprivatelinkresourcesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSlotSample.js -[webappsgetproductionsitedeploymentstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetProductionSiteDeploymentStatusSample.js -[webappsgetscmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSample.js -[webappsgetscmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSlotSample.js -[webappsgetslotsitedeploymentstatusslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js -[webappslistbasicpublishingcredentialspoliciessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js -[webappslistbasicpublishingcredentialspoliciesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js -[webappslistproductionsitedeploymentstatusessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListProductionSiteDeploymentStatusesSample.js -[webappslistsitebackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSample.js -[webappslistsitebackupsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSlotSample.js -[webappslistslotsitedeploymentstatusesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js -[webappsstartnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSample.js -[webappsstartnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSlotSample.js -[webappsstartwebsitenetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js -[webappsstartwebsitenetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js -[webappsstopnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSample.js -[webappsstopnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSlotSample.js -[webappsstopwebsitenetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSample.js -[webappsstopwebsitenetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js -[webappsupdateftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSample.js -[webappsupdateftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSlotSample.js -[webappsupdatescmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSample.js -[webappsupdatescmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSlotSample.js -[workflowrunactionrepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsGetSample.js -[workflowrunactionrepetitionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js -[workflowrunactionrepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListSample.js -[workflowrunactionrepetitionsrequesthistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js -[workflowrunactionrepetitionsrequesthistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js -[workflowrunactionscoperepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsGetSample.js -[workflowrunactionscoperepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsListSample.js -[workflowrunactionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsGetSample.js -[workflowrunactionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListExpressionTracesSample.js -[workflowrunactionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListSample.js -[workflowrunscancelsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsCancelSample.js -[workflowrunsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsGetSample.js -[workflowrunslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsListSample.js -[workflowtriggerhistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesGetSample.js -[workflowtriggerhistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesListSample.js -[workflowtriggerhistoriesresubmitsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesResubmitSample.js -[workflowtriggersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSample.js -[workflowtriggersgetschemajsonsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSchemaJsonSample.js -[workflowtriggerslistcallbackurlsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListCallbackUrlSample.js -[workflowtriggerslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListSample.js -[workflowtriggersrunsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersRunSample.js -[workflowversionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsGetSample.js -[workflowversionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsListSample.js -[workflowsregenerateaccesskeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsRegenerateAccessKeySample.js -[workflowsvalidatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsValidateSample.js -[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-appservice?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice/README.md diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteSample.js deleted file mode 100644 index e800c7f65aa9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete an existing certificate order. - * - * @summary Description for Delete an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificateOrder.json - */ -async function deleteAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.delete( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -deleteAppServiceCertificateOrder().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetSample.js deleted file mode 100644 index 112a70765add..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get a certificate order. - * - * @summary Description for Get a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificateOrder.json - */ -async function getAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.get( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -getAppServiceCertificateOrder().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListByResourceGroupSample.js deleted file mode 100644 index f544d3725f86..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListByResourceGroupSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get certificate orders in a resource group. - * - * @summary Description for Get certificate orders in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json - */ -async function listAppServiceCertificateOrdersByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceCertificateOrders.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppServiceCertificateOrdersByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendEmailSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendEmailSample.js deleted file mode 100644 index c5d259571b1f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendEmailSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Resend certificate email. - * - * @summary Description for Resend certificate email. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendAppServiceCertificateOrderEmail.json - */ -async function resendAppServiceCertificateOrderEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.resendEmail( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -resendAppServiceCertificateOrderEmail().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js deleted file mode 100644 index fdfa5055fa36..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Retrieve the list of certificate actions. - * - * @summary Description for Retrieve the list of certificate actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateOrderActions.json - */ -async function retrieveCertificateOrderActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleCertOrder"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.retrieveCertificateActions( - resourceGroupName, - name - ); - console.log(result); -} - -retrieveCertificateOrderActions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js deleted file mode 100644 index 163a079d1e55..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Retrieve email history. - * - * @summary Description for Retrieve email history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateEmailHistory.json - */ -async function retrieveCertificateEmailHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleCertOrder"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.retrieveCertificateEmailHistory( - resourceGroupName, - name - ); - console.log(result); -} - -retrieveCertificateEmailHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js deleted file mode 100644 index 56f3d9102136..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Verify domain ownership for this certificate order. - * - * @summary Description for Verify domain ownership for this certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/VerifyDomainOwnership.json - */ -async function verifyDomainOwnership() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.verifyDomainOwnership( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -verifyDomainOwnership().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js deleted file mode 100644 index b95b94fa2453..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Delete Custom Dns Suffix configuration of an App Service Environment - * - * @summary Delete Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAseCustomDnsSuffixConfiguration.json - */ -async function deleteAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.deleteAseCustomDnsSuffixConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -deleteAseCustomDnsSuffixConfiguration().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteSample.js deleted file mode 100644 index c1fdf622688f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete an App Service Environment. - * - * @summary Description for Delete an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Delete.json - */ -async function deleteAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginDeleteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js deleted file mode 100644 index 555a506e009a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get Custom Dns Suffix configuration of an App Service Environment - * - * @summary Get Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAseCustomDnsSuffixConfiguration.json - */ -async function getAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getAseCustomDnsSuffixConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -getAseCustomDnsSuffixConfiguration().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js deleted file mode 100644 index d89a05835cb1..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get networking configuration of an App Service Environment - * - * @summary Description for Get networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json - */ -async function getNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getAseV3NetworkingConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -getNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js deleted file mode 100644 index ecc82c048efb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get a diagnostics item for an App Service Environment. - * - * @summary Description for Get a diagnostics item for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json - */ -async function getADiagnosticsItemForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const diagnosticsName = "test-diagnostic"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getDiagnosticsItem( - resourceGroupName, - name, - diagnosticsName - ); - console.log(result); -} - -getADiagnosticsItemForAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js deleted file mode 100644 index 4b3154f36726..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get the network endpoints of all inbound dependencies of an App Service Environment. - * - * @summary Description for Get the network endpoints of all inbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetInboundNetworkDependenciesEndpoints.json - */ -async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAse"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listInboundNetworkDependenciesEndpoints( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js deleted file mode 100644 index f6efa44473d5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get properties of a multi-role pool. - * - * @summary Description for Get properties of a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetMultiRolePool.json - */ -async function getPropertiesOfAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getMultiRolePool(resourceGroupName, name); - console.log(result); -} - -getPropertiesOfAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js deleted file mode 100644 index 8e5e878da318..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get the network endpoints of all outbound dependencies of an App Service Environment. - * - * @summary Description for Get the network endpoints of all outbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetOutboundNetworkDependenciesEndpoints.json - */ -async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAse"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listOutboundNetworkDependenciesEndpoints( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js deleted file mode 100644 index 62ad96de4fe0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the list of private endpoints associated with a hosting environment - * - * @summary Description for Gets the list of private endpoints associated with a hosting environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json - */ -async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listPrivateEndpointConnectionList( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js deleted file mode 100644 index a6b21293dfcd..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json - */ -async function getsThePrivateLinkResources() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getPrivateLinkResources( - resourceGroupName, - name - ); - console.log(result); -} - -getsThePrivateLinkResources().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetSample.js deleted file mode 100644 index 53a680e84019..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get the properties of an App Service Environment. - * - * @summary Description for Get the properties of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Get.json - */ -async function getThePropertiesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getThePropertiesOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetVipInfoSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetVipInfoSample.js deleted file mode 100644 index 4381fcad75e1..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetVipInfoSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get IP addresses assigned to an App Service Environment. - * - * @summary Description for Get IP addresses assigned to an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetVipInfo.json - */ -async function getIPAddressesAssignedToAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getVipInfo(resourceGroupName, name); - console.log(result); -} - -getIPAddressesAssignedToAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetWorkerPoolSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetWorkerPoolSample.js deleted file mode 100644 index f2b6f51e07cc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetWorkerPoolSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get properties of a worker pool. - * - * @summary Description for Get properties of a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetWorkerPool.json - */ -async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "workerPool1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getWorkerPool( - resourceGroupName, - name, - workerPoolName - ); - console.log(result); -} - -getPropertiesOfAWorkerPool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListAppServicePlansSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListAppServicePlansSample.js deleted file mode 100644 index 963f08e759e0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListAppServicePlansSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all App Service plans in an App Service Environment. - * - * @summary Description for Get all App Service plans in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListAppServicePlans.json - */ -async function getAllAppServicePlansInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listAppServicePlans( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppServicePlansInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListByResourceGroupSample.js deleted file mode 100644 index 359a70f06629..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all App Service Environments in a resource group. - * - * @summary Description for Get all App Service Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListByResourceGroup.json - */ -async function getAllAppServiceEnvironmentsInAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppServiceEnvironmentsInAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListCapacitiesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListCapacitiesSample.js deleted file mode 100644 index a1cc787823df..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListCapacitiesSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get the used, available, and total worker capacity an App Service Environment. - * - * @summary Description for Get the used, available, and total worker capacity an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListCapacities.json - */ -async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listCapacities(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListDiagnosticsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListDiagnosticsSample.js deleted file mode 100644 index 2a6d20b0f8de..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListDiagnosticsSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get diagnostic information for an App Service Environment. - * - * @summary Description for Get diagnostic information for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListDiagnostics.json - */ -async function getDiagnosticInformationForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.listDiagnostics(resourceGroupName, name); - console.log(result); -} - -getDiagnosticInformationForAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js deleted file mode 100644 index d0c5e8b3a3c7..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get metric definitions for a multi-role pool of an App Service Environment. - * - * @summary Description for Get metric definitions for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json - */ -async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRoleMetricDefinitions( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js deleted file mode 100644 index f3356f963b6e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get available SKUs for scaling a multi-role pool. - * - * @summary Description for Get available SKUs for scaling a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json - */ -async function getAvailableSkUsForScalingAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRolePoolSkus( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAvailableSkUsForScalingAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js deleted file mode 100644 index 6165e0e64f90..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all multi-role pools. - * - * @summary Description for Get all multi-role pools. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePools.json - */ -async function getAllMultiRolePools() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRolePools( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllMultiRolePools().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js deleted file mode 100644 index 4497d6eb69ee..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get usage metrics for a multi-role pool of an App Service Environment. - * - * @summary Description for Get usage metrics for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json - */ -async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRoleUsages( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListOperationsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListOperationsSample.js deleted file mode 100644 index 96b019d02162..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListOperationsSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for List all currently running operations on the App Service Environment. - * - * @summary Description for List all currently running operations on the App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListOperations.json - */ -async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.listOperations(resourceGroupName, name); - console.log(result); -} - -listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListUsagesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListUsagesSample.js deleted file mode 100644 index 7a0f2aa8b132..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListUsagesSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get global usage metrics of an App Service Environment. - * - * @summary Description for Get global usage metrics of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListUsages.json - */ -async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listUsages(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getGlobalUsageMetricsOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebAppsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebAppsSample.js deleted file mode 100644 index 022dce74b2ec..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebAppsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all apps in an App Service Environment. - * - * @summary Description for Get all apps in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebApps.json - */ -async function getAllAppsInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWebApps(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppsInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolsSample.js deleted file mode 100644 index f44c9f24d4dd..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all worker pools of an App Service Environment. - * - * @summary Description for Get all worker pools of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPools.json - */ -async function getAllWorkerPoolsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWorkerPools(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getAllWorkerPoolsOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsRebootSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsRebootSample.js deleted file mode 100644 index 63e2c9726aaf..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsRebootSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Reboot all machines in an App Service Environment. - * - * @summary Description for Reboot all machines in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Reboot.json - */ -async function rebootAllMachinesInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.reboot(resourceGroupName, name); - console.log(result); -} - -rebootAllMachinesInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsResumeSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsResumeSample.js deleted file mode 100644 index f9732ba3dd4c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsResumeSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Resume an App Service Environment. - * - * @summary Description for Resume an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Resume.json - */ -async function resumeAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.beginListResumeAndWait( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -resumeAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsSuspendSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsSuspendSample.js deleted file mode 100644 index 651ec1814cf8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsSuspendSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Suspend an App Service Environment. - * - * @summary Description for Suspend an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Suspend.json - */ -async function suspendAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.beginListSuspendAndWait( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -suspendAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js deleted file mode 100644 index 6fd631c44e10..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Send a test notification that an upgrade is available for this App Service Environment. - * - * @summary Send a test notification that an upgrade is available for this App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json - */ -async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "SampleHostingEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.testUpgradeAvailableNotification( - resourceGroupName, - name - ); - console.log(result); -} - -sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpgradeSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpgradeSample.js deleted file mode 100644 index 065193af67cf..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpgradeSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Initiate an upgrade of an App Service Environment if one is available. - * - * @summary Description for Initiate an upgrade of an App Service Environment if one is available. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Upgrade.json - */ -async function initiateAnUpgradeOnAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "SampleHostingEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginUpgradeAndWait(resourceGroupName, name); - console.log(result); -} - -initiateAnUpgradeOnAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansDeleteSample.js deleted file mode 100644 index 46609008579d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete an App Service plan. - * - * @summary Description for Delete an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAppServicePlan.json - */ -async function deleteAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.delete(resourceGroupName, name); - console.log(result); -} - -deleteAppServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansGetSample.js deleted file mode 100644 index 215f4fc244aa..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get an App Service plan. - * - * @summary Description for Get an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAppServicePlan.json - */ -async function getAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.get(resourceGroupName, name); - console.log(result); -} - -getAppServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListByResourceGroupSample.js deleted file mode 100644 index 3eb6cbf415cf..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all App Service plans in a resource group. - * - * @summary Description for Get all App Service plans in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlansByResourceGroup.json - */ -async function listAppServicePlansByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServicePlans.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -listAppServicePlansByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansUpdateSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansUpdateSample.js deleted file mode 100644 index cd66f3ccc862..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansUpdateSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Creates or updates an App Service Plan. - * - * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchAppServicePlan.json - */ -async function patchServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const appServicePlan = { kind: "app" }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.update(resourceGroupName, name, appServicePlan); - console.log(result); -} - -patchServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesCreateOrUpdateSample.js deleted file mode 100644 index 230cd368b40c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesCreateOrUpdateSample.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Create or update a certificate. - * - * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateCertificate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const certificateEnvelope = { - hostNames: ["ServerCert"], - location: "East US", - password: "", - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - name, - certificateEnvelope - ); - console.log(result); -} - -createOrUpdateCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesDeleteSample.js deleted file mode 100644 index e54dd2f72f50..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a certificate. - * - * @summary Description for Delete a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteCertificate.json - */ -async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.delete(resourceGroupName, name); - console.log(result); -} - -deleteCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesGetSample.js deleted file mode 100644 index a4d81fe225bc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get a certificate. - * - * @summary Description for Get a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetCertificate.json - */ -async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.get(resourceGroupName, name); - console.log(result); -} - -getCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListByResourceGroupSample.js deleted file mode 100644 index 633df02b6011..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all certificates in a resource group. - * - * @summary Description for Get all certificates in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificatesByResourceGroup.json - */ -async function listCertificatesByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesUpdateSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesUpdateSample.js deleted file mode 100644 index f2738b91227f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesUpdateSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Create or update a certificate. - * - * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchCertificate.json - */ -async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const certificateEnvelope = { - password: "", - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.update(resourceGroupName, name, certificateEnvelope); - console.log(result); -} - -patchCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsDeleteSample.js deleted file mode 100644 index 268d418e66ea..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a Container App. - * - * @summary Description for Delete a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteContainerApp.json - */ -async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteContainerApp().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsGetSample.js deleted file mode 100644 index b2d91efa590b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the properties of a Container App. - * - * @summary Get the properties of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetContainerApp.json - */ -async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, name); - console.log(result); -} - -getContainerApp().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListByResourceGroupSample.js deleted file mode 100644 index d5174bfe2aa6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the Container Apps in a given resource group. - * - * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerApps.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -listContainerAppsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsActivateRevisionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsActivateRevisionSample.js deleted file mode 100644 index 0d390706cef6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsActivateRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Activates a revision for a Container App - * - * @summary Activates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ActivateRevision.json - */ -async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -activateContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsDeactivateRevisionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsDeactivateRevisionSample.js deleted file mode 100644 index 47561bcecf43..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsDeactivateRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Deactivates a revision for a Container App - * - * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeactivateRevision.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deactivateContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsGetRevisionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsGetRevisionSample.js deleted file mode 100644 index b29eb549387d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsGetRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get a revision of a Container App. - * - * @summary Get a revision of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetRevision.json - */ -async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsRestartRevisionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsRestartRevisionSample.js deleted file mode 100644 index 7eea6f70a12f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsRestartRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Restarts a revision for a Container App - * - * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RestartRevision.json - */ -async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testStaticSite0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -restartContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSample.js deleted file mode 100644 index 11581e3597fc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json - */ -async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -executeSiteAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json - */ -async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -executeSiteSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js deleted file mode 100644 index 422681a35c14..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json - */ -async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -executeSiteAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json - */ -async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -executeSiteSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSample.js deleted file mode 100644 index f8936ddcd0b0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json - */ -async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetector( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory - ); - console.log(result); -} - -executeSiteDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json - */ -async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetector( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory - ); - console.log(result); -} - -executeSiteSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSlotSample.js deleted file mode 100644 index a9546ad22f88..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsExecuteSiteDetectorSlotSample.js +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json - */ -async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetectorSlot( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory, - slot - ); - console.log(result); -} - -executeSiteDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json - */ -async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetectorSlot( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory, - slot - ); - console.log(result); -} - -executeSiteSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js deleted file mode 100644 index e05ca3b06ff0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Hosting Environment Detector Response - * - * @summary Description for Get Hosting Environment Detector Response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json - */ -async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAppServiceEnvironment"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getHostingEnvironmentDetectorResponse( - resourceGroupName, - name, - detectorName - ); - console.log(result); -} - -getAppServiceEnvironmentDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSample.js deleted file mode 100644 index d1b87119b172..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json - */ -async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -getAppAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json - */ -async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -getAppSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSlotSample.js deleted file mode 100644 index 8f081f21664b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteAnalysisSlotSample.js +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json - */ -async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -getAppAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json - */ -async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -getAppSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSample.js deleted file mode 100644 index d51cd07496d2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSample.js +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json - */ -async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponse( - resourceGroupName, - siteName, - detectorName - ); - console.log(result); -} - -getAppDetectorResponse().catch(console.error); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json - */ -async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponse( - resourceGroupName, - siteName, - detectorName - ); - console.log(result); -} - -getAppSlotDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js deleted file mode 100644 index 5fae21da0547..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json - */ -async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponseSlot( - resourceGroupName, - siteName, - detectorName, - slot - ); - console.log(result); -} - -getAppDetectorResponse().catch(console.error); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json - */ -async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponseSlot( - resourceGroupName, - siteName, - detectorName, - slot - ); - console.log(result); -} - -getAppSlotDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSample.js deleted file mode 100644 index 8a6ecbaf0e2a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json - */ -async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetector( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName - ); - console.log(result); -} - -getAppDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json - */ -async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetector( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName - ); - console.log(result); -} - -getAppSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSlotSample.js deleted file mode 100644 index 4c61cbe3cbda..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDetectorSlotSample.js +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json - */ -async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorSlot( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName, - slot - ); - console.log(result); -} - -getAppDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json - */ -async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorSlot( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName, - slot - ); - console.log(result); -} - -getAppSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySample.js deleted file mode 100644 index 7a832ba55b2d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySample.js +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json - */ -async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategory( - resourceGroupName, - siteName, - diagnosticCategory - ); - console.log(result); -} - -getAppDiagnosticCategory().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json - */ -async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategory( - resourceGroupName, - siteName, - diagnosticCategory - ); - console.log(result); -} - -getAppSlotDiagnosticCategory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js deleted file mode 100644 index a866eb2a6f71..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json - */ -async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategorySlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - ); - console.log(result); -} - -getAppDiagnosticCategory().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json - */ -async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategorySlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - ); - console.log(result); -} - -getAppSlotDiagnosticCategory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js deleted file mode 100644 index 9806a2ef6d27..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for List Hosting Environment Detector Responses - * - * @summary Description for List Hosting Environment Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json - */ -async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAppServiceEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listHostingEnvironmentDetectorResponses( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppServiceEnvironmentDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSample.js deleted file mode 100644 index eea2ef87b4ab..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSample.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json - */ -async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalyses( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppAnalyses().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json - */ -async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalyses( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotAnalyses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSlotSample.js deleted file mode 100644 index ad7fe10537c9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteAnalysesSlotSample.js +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json - */ -async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalysesSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppAnalyses().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json - */ -async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalysesSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotAnalyses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSample.js deleted file mode 100644 index bef931b05139..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSample.js +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json - */ -async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponses( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppDetectorResponses().catch(console.error); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json - */ -async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponses( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppSlotDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js deleted file mode 100644 index 2630ddfa72bc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json - */ -async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppDetectorResponses().catch(console.error); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json - */ -async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppSlotDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSample.js deleted file mode 100644 index 3152037d4068..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSample.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json - */ -async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectors( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDetectors().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json - */ -async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectors( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDetectors().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSlotSample.js deleted file mode 100644 index d60b68e01e88..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDetectorsSlotSample.js +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json - */ -async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorsSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDetectors().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json - */ -async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorsSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDetectors().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js deleted file mode 100644 index 4cafcb8dedcc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json - */ -async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategories( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDiagnosticCategories().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json - */ -async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategories( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDiagnosticCategories().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js deleted file mode 100644 index 7e141a4c7383..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json - */ -async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDiagnosticCategories().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json - */ -async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDiagnosticCategories().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteOwnershipIdentifierSample.js deleted file mode 100644 index 34bb407a09d0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteOwnershipIdentifierSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete ownership identifier for domain - * - * @summary Description for Delete ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json - */ -async function deleteAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const name = "ownershipIdentifier"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.deleteOwnershipIdentifier( - resourceGroupName, - domainName, - name - ); - console.log(result); -} - -deleteAppServiceDomainOwnershipIdentifier().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteSample.js deleted file mode 100644 index 8af376464bda..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsDeleteSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a domain. - * - * @summary Description for Delete a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomain.json - */ -async function deleteAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const forceHardDeleteDomain = true; - const options = { forceHardDeleteDomain }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.delete(resourceGroupName, domainName, options); - console.log(result); -} - -deleteAppServiceDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetOwnershipIdentifierSample.js deleted file mode 100644 index fd534a01e6cf..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetOwnershipIdentifierSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get ownership identifier for domain - * - * @summary Description for Get ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainOwnershipIdentifier.json - */ -async function getDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const name = "SampleOwnershipId"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.getOwnershipIdentifier(resourceGroupName, domainName, name); - console.log(result); -} - -getDomainOwnershipIdentifier().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetSample.js deleted file mode 100644 index 254adea2e2f3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get a domain. - * - * @summary Description for Get a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomain.json - */ -async function getDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.get(resourceGroupName, domainName); - console.log(result); -} - -getDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListByResourceGroupSample.js deleted file mode 100644 index 9199a8098b56..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all domains in a resource group. - * - * @summary Description for Get all domains in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsByResourceGroup.json - */ -async function listDomainsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.domains.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -listDomainsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListOwnershipIdentifiersSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListOwnershipIdentifiersSample.js deleted file mode 100644 index a842fa26f7d4..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListOwnershipIdentifiersSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Lists domain ownership identifiers. - * - * @summary Description for Lists domain ownership identifiers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainOwnershipIdentifiers.json - */ -async function listDomainOwnershipIdentifiers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.domains.listOwnershipIdentifiers(resourceGroupName, domainName)) { - resArray.push(item); - } - console.log(resArray); -} - -listDomainOwnershipIdentifiers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsRenewSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsRenewSample.js deleted file mode 100644 index 35c61a2652da..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsRenewSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Renew a domain. - * - * @summary Description for Renew a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/RenewDomain.json - */ -async function renewAnExistingDomain() { - const subscriptionId = "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; - const resourceGroupName = "RG"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.renew(resourceGroupName, domainName); - console.log(result); -} - -renewAnExistingDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsTransferOutSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/domainsTransferOutSample.js deleted file mode 100644 index 9dd6a68e6569..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsTransferOutSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Transfer out domain to another registrar - * - * @summary Transfer out domain to another registrar - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/TransferOutDomain.json - */ -async function transferOutDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.transferOut(resourceGroupName, domainName); - console.log(result); -} - -transferOutDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsDeleteSample.js deleted file mode 100644 index d86254a60b8c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a Kubernetes Environment. - * - * @summary Description for Delete a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Delete.json - */ -async function deleteKubeEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.beginDeleteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteKubeEnvironmentByName().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsGetSample.js deleted file mode 100644 index 4b5e35e35519..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get the properties of a Kubernetes Environment. - * - * @summary Description for Get the properties of a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Get.json - */ -async function getKubeEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getKubeEnvironmentsByName().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListByResourceGroupSample.js deleted file mode 100644 index 98cb5a06d5db..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Get all the Kubernetes Environments in a resource group. - * - * @summary Description for Get all the Kubernetes Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListByResourceGroup.json - */ -async function listKubeEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.kubeEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -listKubeEnvironmentsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsUpdateSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsUpdateSample.js deleted file mode 100644 index d426e5d29751..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsUpdateSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. - * - * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Update.json - */ -async function updateKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testkubeenv"; - const kubeEnvironmentEnvelope = { - staticIp: "1.2.3.4", - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.update( - resourceGroupName, - name, - kubeEnvironmentEnvelope - ); - console.log(result); -} - -updateKubeEnvironments().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSample.js deleted file mode 100644 index 95b345df8b57..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json - */ -async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.resourceHealthMetadataOperations.getBySite(resourceGroupName, name); - console.log(result); -} - -getResourceHealthMetadata().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSlotSample.js deleted file mode 100644 index dbb30da24e22..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataGetBySiteSlotSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json - */ -async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.resourceHealthMetadataOperations.getBySiteSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -getResourceHealthMetadata().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListByResourceGroupSample.js deleted file mode 100644 index 5e6d615d1c82..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListByResourceGroupSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. - * - * @summary Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataByResourceGroup.json - */ -async function listResourceHealthMetadataForAResourceGroup() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.resourceHealthMetadataOperations.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listResourceHealthMetadataForAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSample.js deleted file mode 100644 index 7835b2d2033a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json - */ -async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.resourceHealthMetadataOperations.listBySite( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listResourceHealthMetadataForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeletePrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeletePrivateEndpointConnectionSample.js deleted file mode 100644 index db974fd3df34..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeletePrivateEndpointConnectionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json - */ -async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeletePrivateEndpointConnectionAndWait( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -deleteAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteBuildSample.js deleted file mode 100644 index 45a5b5bd412e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteBuildSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Deletes a static site build. - * - * @summary Description for Deletes a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteBuild.json - */ -async function deleteAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteBuildAndWait( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -deleteAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js deleted file mode 100644 index 3eeea039f2f5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Deletes a custom domain. - * - * @summary Description for Deletes a custom domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteCustomDomain.json - */ -async function deleteACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const domainName = "custom.domain.net"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteCustomDomainAndWait( - resourceGroupName, - name, - domainName - ); - console.log(result); -} - -deleteACustomDomainForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteSample.js deleted file mode 100644 index 4a6c8c6618e5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Deletes a static site. - * - * @summary Description for Deletes a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSite.json - */ -async function deleteAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachStaticSiteSample.js deleted file mode 100644 index 54c2396ce361..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachStaticSiteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Detaches a static site. - * - * @summary Description for Detaches a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachStaticSite.json - */ -async function detachAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDetachStaticSiteAndWait(resourceGroupName, name); - console.log(result); -} - -detachAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js deleted file mode 100644 index 7a9529103ebb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Detach the user provided function app from the static site - * - * @summary Description for Detach the user provided function app from the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json - */ -async function detachTheUserProvidedFunctionAppFromTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const functionAppName = "testFunctionApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSite( - resourceGroupName, - name, - functionAppName - ); - console.log(result); -} - -detachTheUserProvidedFunctionAppFromTheStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendSample.js deleted file mode 100644 index 952d5326a742..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Returns the details of a linked backend linked to a static site by name - * - * @summary Returns the details of a linked backend linked to a static site by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSite.json - */ -async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getLinkedBackend( - resourceGroupName, - name, - linkedBackendName - ); - console.log(result); -} - -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsForBuildSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsForBuildSample.js deleted file mode 100644 index d93b282d858f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsForBuildSample.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Returns details of all backends linked to a static site build - * - * @summary Returns details of all backends linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSiteBuild.json - */ -async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listLinkedBackendsForBuild( - resourceGroupName, - name, - environmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsSample.js deleted file mode 100644 index 06f2045ea017..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Returns details of all backends linked to a static site - * - * @summary Returns details of all backends linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSite.json - */ -async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listLinkedBackends(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionSample.js deleted file mode 100644 index 55c4d913b66f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getPrivateEndpointConnection( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateLinkResourcesSample.js deleted file mode 100644 index f47a90378220..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateLinkResourcesSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getPrivateLinkResources(resourceGroupName, name); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildSample.js deleted file mode 100644 index 28fcd723228c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the details of a static site build. - * - * @summary Description for Gets the details of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuild.json - */ -async function getAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSiteBuild( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildsSample.js deleted file mode 100644 index a39e06bb2519..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteBuildsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets all static site builds for a particular static site. - * - * @summary Description for Gets all static site builds for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuilds.json - */ -async function getAllBuildsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteBuilds(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getAllBuildsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteCustomDomainSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteCustomDomainSample.js deleted file mode 100644 index 9ad867b62d05..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteCustomDomainSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets an existing custom domain for a particular static site. - * - * @summary Description for Gets an existing custom domain for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomain.json - */ -async function getCustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const domainName = "custom.domain.net"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSiteCustomDomain( - resourceGroupName, - name, - domainName - ); - console.log(result); -} - -getCustomDomainForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteSample.js deleted file mode 100644 index 39d2b07d30b0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSiteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the details of a static site. - * - * @summary Description for Gets the details of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSite.json - */ -async function getDetailsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSite(resourceGroupName, name); - console.log(result); -} - -getDetailsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSitesByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSitesByResourceGroupSample.js deleted file mode 100644 index 7ca231eeb14b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetStaticSitesByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets all static sites in the specified resource group. - * - * @summary Description for Gets all static sites in the specified resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSites.json - */ -async function getStaticSitesForAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSitesByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -getStaticSitesForAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteAppSettingsSample.js deleted file mode 100644 index 429ff5424928..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteAppSettingsSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site. - * - * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteAppSettings.json - */ -async function getAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteAppSettings(resourceGroupName, name); - console.log(result); -} - -getAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js deleted file mode 100644 index b7e4de64bd5a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site build. - * - * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildAppSettings.json - */ -async function getAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteBuildAppSettings( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getAppSettingsOfAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js deleted file mode 100644 index e97574a88c8b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site build. - * - * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctionAppSettings.json - */ -async function getFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteBuildFunctionAppSettings( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteConfiguredRolesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteConfiguredRolesSample.js deleted file mode 100644 index 64dad3e40b56..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteConfiguredRolesSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Lists the roles configured for the static site. - * - * @summary Description for Lists the roles configured for the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteConfiguredRoles.json - */ -async function listsTheConfiguredRolesForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteConfiguredRoles(resourceGroupName, name); - console.log(result); -} - -listsTheConfiguredRolesForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js deleted file mode 100644 index d1c6e592e734..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site. - * - * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctionAppSettings.json - */ -async function getFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteFunctionAppSettings( - resourceGroupName, - name - ); - console.log(result); -} - -getFunctionAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionsSample.js deleted file mode 100644 index 503d435b59d5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteFunctionsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the functions of a static site. - * - * @summary Description for Gets the functions of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctions.json - */ -async function getsTheFunctionsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteFunctions(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -getsTheFunctionsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteSecretsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteSecretsSample.js deleted file mode 100644 index c940c87812d5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteSecretsSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Lists the secrets for an existing static site. - * - * @summary Description for Lists the secrets for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteSecrets.json - */ -async function listSecretsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteSecrets(resourceGroupName, name); - console.log(result); -} - -listSecretsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendFromBuildSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendFromBuildSample.js deleted file mode 100644 index a03383c6f9e6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendFromBuildSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Unlink a backend from a static site build - * - * @summary Unlink a backend from a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSiteBuild.json - */ -async function unlinkABackendFromAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.unlinkBackendFromBuild( - resourceGroupName, - name, - environmentName, - linkedBackendName - ); - console.log(result); -} - -unlinkABackendFromAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendSample.js deleted file mode 100644 index dabeb13457a0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUnlinkBackendSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Unlink a backend from a static site - * - * @summary Unlink a backend from a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSite.json - */ -async function unlinkABackendFromAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.unlinkBackend(resourceGroupName, name, linkedBackendName); - console.log(result); -} - -unlinkABackendFromAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSample.js deleted file mode 100644 index c21c1e5b9b1e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json - */ -async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginDeletePrivateEndpointConnectionAndWait( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -deleteAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js deleted file mode 100644 index 6f57b013799b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the config reference and status of an app - * - * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSetting.json - */ -async function getAzureKeyVaultAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const appSettingKey = "setting"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getAppSettingKeyVaultReference( - resourceGroupName, - name, - appSettingKey - ); - console.log(result); -} - -getAzureKeyVaultAppSettingReference().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js deleted file mode 100644 index 65f80e02f816..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the config reference and status of an app - * - * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingSlot.json - */ -async function getAzureKeyVaultSlotAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const appSettingKey = "setting"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getAppSettingKeyVaultReferenceSlot( - resourceGroupName, - name, - appSettingKey, - slot - ); - console.log(result); -} - -getAzureKeyVaultSlotAppSettingReference().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js deleted file mode 100644 index 6cc45d2e5db2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the config reference app settings and status of an app - * - * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettings.json - */ -async function getAzureKeyVaultReferencesForAppSettings() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listAppSettingsKeyVaultReferences( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAzureKeyVaultReferencesForAppSettings().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js deleted file mode 100644 index c67ddf7349ec..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the config reference app settings and status of an app - * - * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json - */ -async function getAzureKeyVaultReferencesForAppSettingsForSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listAppSettingsKeyVaultReferencesSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAzureKeyVaultReferencesForAppSettingsForSlot().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSample.js deleted file mode 100644 index 6bebf66edcc3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. - * - * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json - */ -async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getFtpAllowed(resourceGroupName, name); - console.log(result); -} - -getFtpAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSlotSample.js deleted file mode 100644 index 673291b8a7b4..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetFtpAllowedSlotSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. - * - * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json - */ -async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getFtpAllowedSlot(resourceGroupName, name, slot); - console.log(result); -} - -getFtpAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSample.js deleted file mode 100644 index 4fe27abc2de9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets all scale-out instances of an app. - * - * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json - */ -async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const instanceId = "134987120"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getInstanceInfo(resourceGroupName, name, instanceId); - console.log(result); -} - -getSiteInstanceInfo().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSlotSample.js deleted file mode 100644 index be5f8185ad1e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetInstanceInfoSlotSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets all scale-out instances of an app. - * - * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json - */ -async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const instanceId = "134987120"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getInstanceInfoSlot( - resourceGroupName, - name, - instanceId, - slot - ); - console.log(result); -} - -getSiteInstanceInfo().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSample.js deleted file mode 100644 index 36e639f981ed..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateEndpointConnection( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js deleted file mode 100644 index d3422f92adf7..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionSlot.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateEndpointConnectionSlot( - resourceGroupName, - name, - privateEndpointConnectionName, - slot - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSample.js deleted file mode 100644 index 4045d3b0cf3a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateLinkResources(resourceGroupName, name); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSlotSample.js deleted file mode 100644 index 77ddf4dfc8a3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetPrivateLinkResourcesSlotSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResourcesSlot.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateLinkResourcesSlot(resourceGroupName, name, slot); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSample.js deleted file mode 100644 index 57aade88e31b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. - * - * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json - */ -async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getScmAllowed(resourceGroupName, name); - console.log(result); -} - -getScmAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSlotSample.js deleted file mode 100644 index 647ef6644c20..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetScmAllowedSlotSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. - * - * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json - */ -async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getScmAllowedSlot(resourceGroupName, name, slot); - console.log(result); -} - -getScmAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSample.js deleted file mode 100644 index d3dbad0f7809..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets existing backups of an app. - * - * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json - */ -async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listSiteBackups(resourceGroupName, name)) { - resArray.push(item); - } - console.log(resArray); -} - -listBackups().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSlotSample.js deleted file mode 100644 index 2931001999be..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSiteBackupsSlotSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Gets existing backups of an app. - * - * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json - */ -async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listSiteBackupsSlot(resourceGroupName, name, slot)) { - resArray.push(item); - } - console.log(resArray); -} - -listBackups().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSample.js deleted file mode 100644 index a3363c51f8c5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSample.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Start capturing network packets for the site. - * - * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json - */ -async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const durationInSeconds = 60; - const options = { durationInSeconds }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginStartNetworkTraceAndWait( - resourceGroupName, - name, - options - ); - console.log(result); -} - -startANewNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js deleted file mode 100644 index c1de92c75ea0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Start capturing network packets for the site. - * - * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json - */ -async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const durationInSeconds = 60; - const options = { - durationInSeconds, - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginStartWebSiteNetworkTraceOperationAndWait( - resourceGroupName, - name, - options - ); - console.log(result); -} - -startANewNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSample.js deleted file mode 100644 index ec9da159e8f6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopNetworkTrace(resourceGroupName, name); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSlotSample.js deleted file mode 100644 index 366145231d83..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopNetworkTraceSlotSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopNetworkTraceSlot(resourceGroupName, name, slot); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSample.js deleted file mode 100644 index eb1e0ff7af8b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopWebSiteNetworkTrace(resourceGroupName, name); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js deleted file mode 100644 index 4447f8aa2d00..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopWebSiteNetworkTraceSlot(resourceGroupName, name, slot); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsGetSample.js deleted file mode 100644 index 0ed6a5f686c3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsGetSample.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a workflow run action. - * - * @summary Gets a workflow run action. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_Get.json - */ -async function getAWorkflowRunAction() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const actionName = "HTTP"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRunActions.get( - resourceGroupName, - name, - workflowName, - runName, - actionName - ); - console.log(result); -} - -getAWorkflowRunAction().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListSample.js deleted file mode 100644 index d23c52ab59b0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListSample.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a list of workflow run actions. - * - * @summary Gets a list of workflow run actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_List.json - */ -async function listAWorkflowRunActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRunActions.list( - resourceGroupName, - name, - workflowName, - runName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAWorkflowRunActions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsCancelSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsCancelSample.js deleted file mode 100644 index 97f6214b1dcb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsCancelSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Cancels a workflow run. - * - * @summary Cancels a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Cancel.json - */ -async function cancelAWorkflowRun() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRuns.cancel(resourceGroupName, name, workflowName, runName); - console.log(result); -} - -cancelAWorkflowRun().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsGetSample.js deleted file mode 100644 index 0ea3c35b79f8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsGetSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a workflow run. - * - * @summary Gets a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Get.json - */ -async function getARunForAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRuns.get(resourceGroupName, name, workflowName, runName); - console.log(result); -} - -getARunForAWorkflow().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsListSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsListSample.js deleted file mode 100644 index 87d2dfa54118..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunsListSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a list of workflow runs. - * - * @summary Gets a list of workflow runs. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_List.json - */ -async function listWorkflowRuns() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRuns.list(resourceGroupName, name, workflowName)) { - resArray.push(item); - } - console.log(resArray); -} - -listWorkflowRuns().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesGetSample.js deleted file mode 100644 index f89b70f5e643..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesGetSample.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a workflow trigger history. - * - * @summary Gets a workflow trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Get.json - */ -async function getAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const triggerName = "testTriggerName"; - const historyName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggerHistories.get( - resourceGroupName, - name, - workflowName, - triggerName, - historyName - ); - console.log(result); -} - -getAWorkflowTriggerHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSample.js deleted file mode 100644 index a148060acdc8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a workflow trigger. - * - * @summary Gets a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Get.json - */ -async function getAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.get( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getAWorkflowTrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSchemaJsonSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSchemaJsonSample.js deleted file mode 100644 index ca764a319477..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersGetSchemaJsonSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the trigger schema as JSON. - * - * @summary Get the trigger schema as JSON. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_GetSchemaJson.json - */ -async function getTriggerSchema() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflow"; - const triggerName = "testTrigger"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.getSchemaJson( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getTriggerSchema().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListCallbackUrlSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListCallbackUrlSample.js deleted file mode 100644 index 9bbcabbe082b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListCallbackUrlSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the callback URL for a workflow trigger. - * - * @summary Get the callback URL for a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_ListCallbackUrl.json - */ -async function getTheCallbackUrlForATrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.listCallbackUrl( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getTheCallbackUrlForATrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListSample.js deleted file mode 100644 index b3e4cb8955d0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersListSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a list of workflow triggers. - * - * @summary Gets a list of workflow triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_List.json - */ -async function listWorkflowTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowTriggers.list(resourceGroupName, name, workflowName)) { - resArray.push(item); - } - console.log(resArray); -} - -listWorkflowTriggers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersRunSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersRunSample.js deleted file mode 100644 index cc18ee0da3a3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggersRunSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Runs a workflow trigger. - * - * @summary Runs a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Run.json - */ -async function runAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.beginRunAndWait( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -runAWorkflowTrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsGetSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsGetSample.js deleted file mode 100644 index 41548c5cb142..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsGetSample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a workflow version. - * - * @summary Gets a workflow version. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_Get.json - */ -async function getAWorkflowVersion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const versionId = "08586676824806722526"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowVersions.get( - resourceGroupName, - name, - workflowName, - versionId - ); - console.log(result); -} - -getAWorkflowVersion().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsListSample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsListSample.js deleted file mode 100644 index 2a5a22170197..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowVersionsListSample.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Gets a list of workflow versions. - * - * @summary Gets a list of workflow versions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_List.json - */ -async function listAWorkflowsVersions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowVersions.list(resourceGroupName, name, workflowName)) { - resArray.push(item); - } - console.log(resArray); -} - -listAWorkflowsVersions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsRegenerateAccessKeySample.js b/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsRegenerateAccessKeySample.js deleted file mode 100644 index 6298f3f2da08..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsRegenerateAccessKeySample.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { WebSiteManagementClient } = require("@azure/arm-appservice"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Regenerates the callback URL access key for request triggers. - * - * @summary Regenerates the callback URL access key for request triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_RegenerateAccessKey.json - */ -async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const keyType = { keyType: "Primary" }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflows.regenerateAccessKey( - resourceGroupName, - name, - workflowName, - keyType - ); - console.log(result); -} - -regenerateTheCallbackUrlAccessKeyForRequestTriggers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/README.md b/sdk/appservice/arm-appservice/samples/v13/typescript/README.md deleted file mode 100644 index 85562e920627..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/README.md +++ /dev/null @@ -1,639 +0,0 @@ -# client library samples for TypeScript - -These sample programs show how to use the TypeScript client libraries for in some common scenarios. - -| **File Name** | **Description** | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts][appservicecertificateorderscreateorupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificate.json | -| [appServiceCertificateOrdersCreateOrUpdateSample.ts][appservicecertificateorderscreateorupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersDeleteCertificateSample.ts][appservicecertificateordersdeletecertificatesample] | Description for Delete the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificate.json | -| [appServiceCertificateOrdersDeleteSample.ts][appservicecertificateordersdeletesample] | Description for Delete an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersGetCertificateSample.ts][appservicecertificateordersgetcertificatesample] | Description for Get the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificate.json | -| [appServiceCertificateOrdersGetSample.ts][appservicecertificateordersgetsample] | Description for Get a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersListByResourceGroupSample.ts][appservicecertificateorderslistbyresourcegroupsample] | Description for Get certificate orders in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json | -| [appServiceCertificateOrdersListCertificatesSample.ts][appservicecertificateorderslistcertificatessample] | Description for List all certificates associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListCertificatesByAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersListSample.ts][appservicecertificateorderslistsample] | Description for List all certificate orders in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersBySubscription.json | -| [appServiceCertificateOrdersReissueSample.ts][appservicecertificateordersreissuesample] | Description for Reissue an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ReissueAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersRenewSample.ts][appservicecertificateordersrenewsample] | Description for Renew an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RenewAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersResendEmailSample.ts][appservicecertificateordersresendemailsample] | Description for Resend certificate email. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendAppServiceCertificateOrderEmail.json | -| [appServiceCertificateOrdersResendRequestEmailsSample.ts][appservicecertificateordersresendrequestemailssample] | Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendDomainOwnershipVerificationEmail.json | -| [appServiceCertificateOrdersRetrieveCertificateActionsSample.ts][appservicecertificateordersretrievecertificateactionssample] | Description for Retrieve the list of certificate actions. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateOrderActions.json | -| [appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts][appservicecertificateordersretrievecertificateemailhistorysample] | Description for Retrieve email history. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateEmailHistory.json | -| [appServiceCertificateOrdersRetrieveSiteSealSample.ts][appservicecertificateordersretrievesitesealsample] | This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveSiteSeal.json | -| [appServiceCertificateOrdersUpdateCertificateSample.ts][appservicecertificateordersupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificate.json | -| [appServiceCertificateOrdersUpdateSample.ts][appservicecertificateordersupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificateOrder.json | -| [appServiceCertificateOrdersValidatePurchaseInformationSample.ts][appservicecertificateordersvalidatepurchaseinformationsample] | Description for Validate information for a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json | -| [appServiceCertificateOrdersVerifyDomainOwnershipSample.ts][appservicecertificateordersverifydomainownershipsample] | Description for Verify domain ownership for this certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/VerifyDomainOwnership.json | -| [appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts][appserviceenvironmentsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json | -| [appServiceEnvironmentsChangeVnetSample.ts][appserviceenvironmentschangevnetsample] | Description for Move an App Service Environment to a different VNET. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ChangeVnet.json | -| [appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts][appserviceenvironmentscreateorupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | -| [appServiceEnvironmentsCreateOrUpdateSample.ts][appserviceenvironmentscreateorupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdate.json | -| [appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts][appserviceenvironmentscreateorupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | -| [appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample] | Delete Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts][appserviceenvironmentsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json | -| [appServiceEnvironmentsDeleteSample.ts][appserviceenvironmentsdeletesample] | Description for Delete an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Delete.json | -| [appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsgetasecustomdnssuffixconfigurationsample] | Get Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts][appserviceenvironmentsgetasev3networkingconfigurationsample] | Description for Get networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json | -| [appServiceEnvironmentsGetDiagnosticsItemSample.ts][appserviceenvironmentsgetdiagnosticsitemsample] | Description for Get a diagnostics item for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json | -| [appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts][appserviceenvironmentsgetinboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all inbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetInboundNetworkDependenciesEndpoints.json | -| [appServiceEnvironmentsGetMultiRolePoolSample.ts][appserviceenvironmentsgetmultirolepoolsample] | Description for Get properties of a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetMultiRolePool.json | -| [appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts][appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all outbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetOutboundNetworkDependenciesEndpoints.json | -| [appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts][appserviceenvironmentsgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoints associated with a hosting environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json | -| [appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts][appserviceenvironmentsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json | -| [appServiceEnvironmentsGetPrivateLinkResourcesSample.ts][appserviceenvironmentsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json | -| [appServiceEnvironmentsGetSample.ts][appserviceenvironmentsgetsample] | Description for Get the properties of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Get.json | -| [appServiceEnvironmentsGetVipInfoSample.ts][appserviceenvironmentsgetvipinfosample] | Description for Get IP addresses assigned to an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetVipInfo.json | -| [appServiceEnvironmentsGetWorkerPoolSample.ts][appserviceenvironmentsgetworkerpoolsample] | Description for Get properties of a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetWorkerPool.json | -| [appServiceEnvironmentsListAppServicePlansSample.ts][appserviceenvironmentslistappserviceplanssample] | Description for Get all App Service plans in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListAppServicePlans.json | -| [appServiceEnvironmentsListByResourceGroupSample.ts][appserviceenvironmentslistbyresourcegroupsample] | Description for Get all App Service Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListByResourceGroup.json | -| [appServiceEnvironmentsListCapacitiesSample.ts][appserviceenvironmentslistcapacitiessample] | Description for Get the used, available, and total worker capacity an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListCapacities.json | -| [appServiceEnvironmentsListDiagnosticsSample.ts][appserviceenvironmentslistdiagnosticssample] | Description for Get diagnostic information for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListDiagnostics.json | -| [appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts][appserviceenvironmentslistmultirolemetricdefinitionssample] | Description for Get metric definitions for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json | -| [appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts][appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json | -| [appServiceEnvironmentsListMultiRolePoolSkusSample.ts][appserviceenvironmentslistmultirolepoolskussample] | Description for Get available SKUs for scaling a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json | -| [appServiceEnvironmentsListMultiRolePoolsSample.ts][appserviceenvironmentslistmultirolepoolssample] | Description for Get all multi-role pools. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePools.json | -| [appServiceEnvironmentsListMultiRoleUsagesSample.ts][appserviceenvironmentslistmultiroleusagessample] | Description for Get usage metrics for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json | -| [appServiceEnvironmentsListOperationsSample.ts][appserviceenvironmentslistoperationssample] | Description for List all currently running operations on the App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListOperations.json | -| [appServiceEnvironmentsListSample.ts][appserviceenvironmentslistsample] | Description for Get all App Service Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_List.json | -| [appServiceEnvironmentsListUsagesSample.ts][appserviceenvironmentslistusagessample] | Description for Get global usage metrics of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListUsages.json | -| [appServiceEnvironmentsListWebAppsSample.ts][appserviceenvironmentslistwebappssample] | Description for Get all apps in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebApps.json | -| [appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts][appserviceenvironmentslistwebworkermetricdefinitionssample] | Description for Get metric definitions for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json | -| [appServiceEnvironmentsListWebWorkerUsagesSample.ts][appserviceenvironmentslistwebworkerusagessample] | Description for Get usage metrics for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json | -| [appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts][appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json | -| [appServiceEnvironmentsListWorkerPoolSkusSample.ts][appserviceenvironmentslistworkerpoolskussample] | Description for Get available SKUs for scaling a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json | -| [appServiceEnvironmentsListWorkerPoolsSample.ts][appserviceenvironmentslistworkerpoolssample] | Description for Get all worker pools of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPools.json | -| [appServiceEnvironmentsRebootSample.ts][appserviceenvironmentsrebootsample] | Description for Reboot all machines in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Reboot.json | -| [appServiceEnvironmentsResumeSample.ts][appserviceenvironmentsresumesample] | Description for Resume an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Resume.json | -| [appServiceEnvironmentsSuspendSample.ts][appserviceenvironmentssuspendsample] | Description for Suspend an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Suspend.json | -| [appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts][appserviceenvironmentstestupgradeavailablenotificationsample] | Send a test notification that an upgrade is available for this App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json | -| [appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample] | Update Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateAseCustomDnsSuffixConfiguration.json | -| [appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts][appserviceenvironmentsupdateasenetworkingconfigurationsample] | Description for Update networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json | -| [appServiceEnvironmentsUpdateMultiRolePoolSample.ts][appserviceenvironmentsupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | -| [appServiceEnvironmentsUpdateSample.ts][appserviceenvironmentsupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Update.json | -| [appServiceEnvironmentsUpdateWorkerPoolSample.ts][appserviceenvironmentsupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | -| [appServiceEnvironmentsUpgradeSample.ts][appserviceenvironmentsupgradesample] | Description for Initiate an upgrade of an App Service Environment if one is available. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Upgrade.json | -| [appServicePlansCreateOrUpdateSample.ts][appserviceplanscreateorupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateAppServicePlan.json | -| [appServicePlansDeleteSample.ts][appserviceplansdeletesample] | Description for Delete an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAppServicePlan.json | -| [appServicePlansGetSample.ts][appserviceplansgetsample] | Description for Get an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAppServicePlan.json | -| [appServicePlansListByResourceGroupSample.ts][appserviceplanslistbyresourcegroupsample] | Description for Get all App Service plans in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlansByResourceGroup.json | -| [appServicePlansListSample.ts][appserviceplanslistsample] | Description for Get all App Service plans for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlans.json | -| [appServicePlansUpdateSample.ts][appserviceplansupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchAppServicePlan.json | -| [certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts][certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json | -| [certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts][certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json | -| [certificateRegistrationProviderListOperationsSample.ts][certificateregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListOperations.json | -| [certificatesCreateOrUpdateSample.ts][certificatescreateorupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateCertificate.json | -| [certificatesDeleteSample.ts][certificatesdeletesample] | Description for Delete a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteCertificate.json | -| [certificatesGetSample.ts][certificatesgetsample] | Description for Get a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetCertificate.json | -| [certificatesListByResourceGroupSample.ts][certificateslistbyresourcegroupsample] | Description for Get all certificates in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificatesByResourceGroup.json | -| [certificatesListSample.ts][certificateslistsample] | Description for Get all certificates for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificates.json | -| [certificatesUpdateSample.ts][certificatesupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchCertificate.json | -| [containerAppsCreateOrUpdateSample.ts][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateContainerApp.json | -| [containerAppsDeleteSample.ts][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteContainerApp.json | -| [containerAppsGetSample.ts][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetContainerApp.json | -| [containerAppsListByResourceGroupSample.ts][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsByResourceGroup.json | -| [containerAppsListBySubscriptionSample.ts][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsBySubscription.json | -| [containerAppsListSecretsSample.ts][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppSecrets.json | -| [containerAppsRevisionsActivateRevisionSample.ts][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ActivateRevision.json | -| [containerAppsRevisionsDeactivateRevisionSample.ts][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeactivateRevision.json | -| [containerAppsRevisionsGetRevisionSample.ts][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetRevision.json | -| [containerAppsRevisionsListRevisionsSample.ts][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListRevisions.json | -| [containerAppsRevisionsRestartRevisionSample.ts][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RestartRevision.json | -| [deletedWebAppsGetDeletedWebAppByLocationSample.ts][deletedwebappsgetdeletedwebappbylocationsample] | Description for Get deleted app for a subscription at location. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppByLocation.json | -| [deletedWebAppsListByLocationSample.ts][deletedwebappslistbylocationsample] | Description for Get all deleted apps for a subscription at location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListDeletedWebAppsByLocation.json | -| [diagnosticsExecuteSiteAnalysisSample.ts][diagnosticsexecutesiteanalysissample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json | -| [diagnosticsExecuteSiteAnalysisSlotSample.ts][diagnosticsexecutesiteanalysisslotsample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json | -| [diagnosticsExecuteSiteDetectorSample.ts][diagnosticsexecutesitedetectorsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json | -| [diagnosticsExecuteSiteDetectorSlotSample.ts][diagnosticsexecutesitedetectorslotsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json | -| [diagnosticsGetHostingEnvironmentDetectorResponseSample.ts][diagnosticsgethostingenvironmentdetectorresponsesample] | Description for Get Hosting Environment Detector Response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json | -| [diagnosticsGetSiteAnalysisSample.ts][diagnosticsgetsiteanalysissample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json | -| [diagnosticsGetSiteAnalysisSlotSample.ts][diagnosticsgetsiteanalysisslotsample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json | -| [diagnosticsGetSiteDetectorResponseSample.ts][diagnosticsgetsitedetectorresponsesample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json | -| [diagnosticsGetSiteDetectorResponseSlotSample.ts][diagnosticsgetsitedetectorresponseslotsample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json | -| [diagnosticsGetSiteDetectorSample.ts][diagnosticsgetsitedetectorsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json | -| [diagnosticsGetSiteDetectorSlotSample.ts][diagnosticsgetsitedetectorslotsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json | -| [diagnosticsGetSiteDiagnosticCategorySample.ts][diagnosticsgetsitediagnosticcategorysample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | -| [diagnosticsGetSiteDiagnosticCategorySlotSample.ts][diagnosticsgetsitediagnosticcategoryslotsample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | -| [diagnosticsListHostingEnvironmentDetectorResponsesSample.ts][diagnosticslisthostingenvironmentdetectorresponsessample] | Description for List Hosting Environment Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json | -| [diagnosticsListSiteAnalysesSample.ts][diagnosticslistsiteanalysessample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json | -| [diagnosticsListSiteAnalysesSlotSample.ts][diagnosticslistsiteanalysesslotsample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json | -| [diagnosticsListSiteDetectorResponsesSample.ts][diagnosticslistsitedetectorresponsessample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json | -| [diagnosticsListSiteDetectorResponsesSlotSample.ts][diagnosticslistsitedetectorresponsesslotsample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json | -| [diagnosticsListSiteDetectorsSample.ts][diagnosticslistsitedetectorssample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json | -| [diagnosticsListSiteDetectorsSlotSample.ts][diagnosticslistsitedetectorsslotsample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json | -| [diagnosticsListSiteDiagnosticCategoriesSample.ts][diagnosticslistsitediagnosticcategoriessample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | -| [diagnosticsListSiteDiagnosticCategoriesSlotSample.ts][diagnosticslistsitediagnosticcategoriesslotsample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | -| [domainRegistrationProviderListOperationsSample.ts][domainregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListOperations.json | -| [domainsCheckAvailabilitySample.ts][domainscheckavailabilitysample] | Description for Check if a domain is available for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CheckDomainAvailability.json | -| [domainsCreateOrUpdateOwnershipIdentifierSample.ts][domainscreateorupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomainOwnershipIdentifier.json | -| [domainsCreateOrUpdateSample.ts][domainscreateorupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomain.json | -| [domainsDeleteOwnershipIdentifierSample.ts][domainsdeleteownershipidentifiersample] | Description for Delete ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json | -| [domainsDeleteSample.ts][domainsdeletesample] | Description for Delete a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomain.json | -| [domainsGetControlCenterSsoRequestSample.ts][domainsgetcontrolcenterssorequestsample] | Description for Generate a single sign-on request for the domain management portal. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainControlCenterSsoRequest.json | -| [domainsGetOwnershipIdentifierSample.ts][domainsgetownershipidentifiersample] | Description for Get ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainOwnershipIdentifier.json | -| [domainsGetSample.ts][domainsgetsample] | Description for Get a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomain.json | -| [domainsListByResourceGroupSample.ts][domainslistbyresourcegroupsample] | Description for Get all domains in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsByResourceGroup.json | -| [domainsListOwnershipIdentifiersSample.ts][domainslistownershipidentifierssample] | Description for Lists domain ownership identifiers. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainOwnershipIdentifiers.json | -| [domainsListRecommendationsSample.ts][domainslistrecommendationssample] | Description for Get domain name recommendations based on keywords. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainRecommendations.json | -| [domainsListSample.ts][domainslistsample] | Description for Get all domains in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsBySubscription.json | -| [domainsRenewSample.ts][domainsrenewsample] | Description for Renew a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/RenewDomain.json | -| [domainsTransferOutSample.ts][domainstransferoutsample] | Transfer out domain to another registrar x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/TransferOutDomain.json | -| [domainsUpdateOwnershipIdentifierSample.ts][domainsupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json | -| [domainsUpdateSample.ts][domainsupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomain.json | -| [globalGetDeletedWebAppSample.ts][globalgetdeletedwebappsample] | Description for Get deleted app for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebApp.json | -| [globalGetDeletedWebAppSnapshotsSample.ts][globalgetdeletedwebappsnapshotssample] | Description for Get all deleted apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppSnapshots.json | -| [globalGetSubscriptionOperationWithAsyncResponseSample.ts][globalgetsubscriptionoperationwithasyncresponsesample] | Description for Gets an operation in a subscription and given region x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSubscriptionOperationWithAsyncResponse.json | -| [kubeEnvironmentsCreateOrUpdateSample.ts][kubeenvironmentscreateorupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_CreateOrUpdate.json | -| [kubeEnvironmentsDeleteSample.ts][kubeenvironmentsdeletesample] | Description for Delete a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Delete.json | -| [kubeEnvironmentsGetSample.ts][kubeenvironmentsgetsample] | Description for Get the properties of a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Get.json | -| [kubeEnvironmentsListByResourceGroupSample.ts][kubeenvironmentslistbyresourcegroupsample] | Description for Get all the Kubernetes Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListByResourceGroup.json | -| [kubeEnvironmentsListBySubscriptionSample.ts][kubeenvironmentslistbysubscriptionsample] | Description for Get all Kubernetes Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListBySubscription.json | -| [kubeEnvironmentsUpdateSample.ts][kubeenvironmentsupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Update.json | -| [listCustomHostNameSitesSample.ts][listcustomhostnamesitessample] | Get custom hostnames under this subscription x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomHostNameSites.json | -| [providerGetFunctionAppStacksForLocationSample.ts][providergetfunctionappstacksforlocationsample] | Description for Get available Function app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacksForLocation.json | -| [providerGetFunctionAppStacksSample.ts][providergetfunctionappstackssample] | Description for Get available Function app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacks.json | -| [providerGetWebAppStacksForLocationSample.ts][providergetwebappstacksforlocationsample] | Description for Get available Web app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacksForLocation.json | -| [providerGetWebAppStacksSample.ts][providergetwebappstackssample] | Description for Get available Web app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacks.json | -| [providerListOperationsSample.ts][providerlistoperationssample] | Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListOperations.json | -| [resourceHealthMetadataGetBySiteSample.ts][resourcehealthmetadatagetbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json | -| [resourceHealthMetadataGetBySiteSlotSample.ts][resourcehealthmetadatagetbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListByResourceGroupSample.ts][resourcehealthmetadatalistbyresourcegroupsample] | Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataByResourceGroup.json | -| [resourceHealthMetadataListBySiteSample.ts][resourcehealthmetadatalistbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListBySiteSlotSample.ts][resourcehealthmetadatalistbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json | -| [resourceHealthMetadataListSample.ts][resourcehealthmetadatalistsample] | Description for List all ResourceHealthMetadata for all sites in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySubscription.json | -| [staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts][staticsitesapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json | -| [staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts][staticsitescreateorupdatestaticsiteappsettingssample] | Description for Creates or updates the app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts][staticsitescreateorupdatestaticsitebuildappsettingssample] | Description for Creates or updates the app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts][staticsitescreateorupdatestaticsitebuildfunctionappsettingssample] | Description for Creates or updates the function app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts][staticsitescreateorupdatestaticsitecustomdomainsample] | Description for Creates a new static site custom domain in an existing resource group and static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteCustomDomain.json | -| [staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts][staticsitescreateorupdatestaticsitefunctionappsettingssample] | Description for Creates or updates the function app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json | -| [staticSitesCreateOrUpdateStaticSiteSample.ts][staticsitescreateorupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSite.json | -| [staticSitesCreateUserRolesInvitationLinkSample.ts][staticsitescreateuserrolesinvitationlinksample] | Description for Creates an invitation link for a user with the role x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateUserRolesInvitationLink.json | -| [staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts][staticsitescreatezipdeploymentforstaticsitebuildsample] | Description for Deploys zipped content to a specific environment of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteBuildZipDeploy.json | -| [staticSitesCreateZipDeploymentForStaticSiteSample.ts][staticsitescreatezipdeploymentforstaticsitesample] | Description for Deploys zipped content to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteZipDeploy.json | -| [staticSitesDeletePrivateEndpointConnectionSample.ts][staticsitesdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json | -| [staticSitesDeleteStaticSiteBuildSample.ts][staticsitesdeletestaticsitebuildsample] | Description for Deletes a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteBuild.json | -| [staticSitesDeleteStaticSiteCustomDomainSample.ts][staticsitesdeletestaticsitecustomdomainsample] | Description for Deletes a custom domain. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteCustomDomain.json | -| [staticSitesDeleteStaticSiteSample.ts][staticsitesdeletestaticsitesample] | Description for Deletes a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSite.json | -| [staticSitesDeleteStaticSiteUserSample.ts][staticsitesdeletestaticsiteusersample] | Description for Deletes the user entry from the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteUser.json | -| [staticSitesDetachStaticSiteSample.ts][staticsitesdetachstaticsitesample] | Description for Detaches a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachStaticSite.json | -| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts][staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample] | Description for Detach the user provided function app from the static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json | -| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts][staticsitesdetachuserprovidedfunctionappfromstaticsitesample] | Description for Detach the user provided function app from the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json | -| [staticSitesGetLinkedBackendForBuildSample.ts][staticsitesgetlinkedbackendforbuildsample] | Returns the details of a linked backend linked to a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSiteBuild.json | -| [staticSitesGetLinkedBackendSample.ts][staticsitesgetlinkedbackendsample] | Returns the details of a linked backend linked to a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSite.json | -| [staticSitesGetLinkedBackendsForBuildSample.ts][staticsitesgetlinkedbackendsforbuildsample] | Returns details of all backends linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSiteBuild.json | -| [staticSitesGetLinkedBackendsSample.ts][staticsitesgetlinkedbackendssample] | Returns details of all backends linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSite.json | -| [staticSitesGetPrivateEndpointConnectionListSample.ts][staticsitesgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoint connections associated with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionList.json | -| [staticSitesGetPrivateEndpointConnectionSample.ts][staticsitesgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json | -| [staticSitesGetPrivateLinkResourcesSample.ts][staticsitesgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json | -| [staticSitesGetStaticSiteBuildSample.ts][staticsitesgetstaticsitebuildsample] | Description for Gets the details of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuild.json | -| [staticSitesGetStaticSiteBuildsSample.ts][staticsitesgetstaticsitebuildssample] | Description for Gets all static site builds for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuilds.json | -| [staticSitesGetStaticSiteCustomDomainSample.ts][staticsitesgetstaticsitecustomdomainsample] | Description for Gets an existing custom domain for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomain.json | -| [staticSitesGetStaticSiteSample.ts][staticsitesgetstaticsitesample] | Description for Gets the details of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSite.json | -| [staticSitesGetStaticSitesByResourceGroupSample.ts][staticsitesgetstaticsitesbyresourcegroupsample] | Description for Gets all static sites in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSites.json | -| [staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts][staticsitesgetuserprovidedfunctionappforstaticsitebuildsample] | Description for Gets the details of the user provided function app registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json | -| [staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts][staticsitesgetuserprovidedfunctionappforstaticsitesample] | Description for Gets the details of the user provided function app registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSite.json | -| [staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts][staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample] | Description for Gets the details of the user provided function apps registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json | -| [staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts][staticsitesgetuserprovidedfunctionappsforstaticsitesample] | Description for Gets the details of the user provided function apps registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSite.json | -| [staticSitesLinkBackendSample.ts][staticsiteslinkbackendsample] | Link backend to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSite.json | -| [staticSitesLinkBackendToBuildSample.ts][staticsiteslinkbackendtobuildsample] | Link backend to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSiteBuild.json | -| [staticSitesListSample.ts][staticsiteslistsample] | Description for Get all Static Sites for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAllStaticSites.json | -| [staticSitesListStaticSiteAppSettingsSample.ts][staticsitesliststaticsiteappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteAppSettings.json | -| [staticSitesListStaticSiteBuildAppSettingsSample.ts][staticsitesliststaticsitebuildappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildAppSettings.json | -| [staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts][staticsitesliststaticsitebuildfunctionappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctionAppSettings.json | -| [staticSitesListStaticSiteBuildFunctionsSample.ts][staticsitesliststaticsitebuildfunctionssample] | Description for Gets the functions of a particular static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctions.json | -| [staticSitesListStaticSiteConfiguredRolesSample.ts][staticsitesliststaticsiteconfiguredrolessample] | Description for Lists the roles configured for the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteConfiguredRoles.json | -| [staticSitesListStaticSiteCustomDomainsSample.ts][staticsitesliststaticsitecustomdomainssample] | Description for Gets all static site custom domains for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomains.json | -| [staticSitesListStaticSiteFunctionAppSettingsSample.ts][staticsitesliststaticsitefunctionappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctionAppSettings.json | -| [staticSitesListStaticSiteFunctionsSample.ts][staticsitesliststaticsitefunctionssample] | Description for Gets the functions of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctions.json | -| [staticSitesListStaticSiteSecretsSample.ts][staticsitesliststaticsitesecretssample] | Description for Lists the secrets for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteSecrets.json | -| [staticSitesListStaticSiteUsersSample.ts][staticsitesliststaticsiteuserssample] | Description for Gets the list of users of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteUsers.json | -| [staticSitesPreviewWorkflowSample.ts][staticsitespreviewworkflowsample] | Description for Generates a preview workflow file for the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GenerateStaticSiteWorkflowPreview.json | -| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts][staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample] | Description for Register a user provided function app with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json | -| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts][staticsitesregisteruserprovidedfunctionappwithstaticsitesample] | Description for Register a user provided function app with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json | -| [staticSitesResetStaticSiteApiKeySample.ts][staticsitesresetstaticsiteapikeysample] | Description for Resets the api key for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ResetStaticSiteApiKey.json | -| [staticSitesUnlinkBackendFromBuildSample.ts][staticsitesunlinkbackendfrombuildsample] | Unlink a backend from a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSiteBuild.json | -| [staticSitesUnlinkBackendSample.ts][staticsitesunlinkbackendsample] | Unlink a backend from a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSite.json | -| [staticSitesUpdateStaticSiteSample.ts][staticsitesupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchStaticSite.json | -| [staticSitesUpdateStaticSiteUserSample.ts][staticsitesupdatestaticsiteusersample] | Description for Updates a user entry with the listed roles x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateStaticSiteUser.json | -| [staticSitesValidateBackendForBuildSample.ts][staticsitesvalidatebackendforbuildsample] | Validates that a backend can be linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSiteBuild.json | -| [staticSitesValidateBackendSample.ts][staticsitesvalidatebackendsample] | Validates that a backend can be linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSite.json | -| [staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts][staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample] | Description for Validates a particular custom domain can be added to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateStaticSiteCustomDomain.json | -| [topLevelDomainsGetSample.ts][topleveldomainsgetsample] | Description for Get details of a top-level domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetTopLevelDomain.json | -| [topLevelDomainsListAgreementsSample.ts][topleveldomainslistagreementssample] | Description for Gets all legal agreements that user needs to accept before purchasing a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomainAgreements.json | -| [topLevelDomainsListSample.ts][topleveldomainslistsample] | Description for Get all top-level domains supported for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomains.json | -| [verifyHostingEnvironmentVnetSample.ts][verifyhostingenvironmentvnetsample] | Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/VerifyHostingEnvironmentVnet.json | -| [webAppsApproveOrRejectPrivateEndpointConnectionSample.ts][webappsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json | -| [webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts][webappsapproveorrejectprivateendpointconnectionslotsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json | -| [webAppsDeletePrivateEndpointConnectionSample.ts][webappsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json | -| [webAppsDeletePrivateEndpointConnectionSlotSample.ts][webappsdeleteprivateendpointconnectionslotsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnectionSlot.json | -| [webAppsGetAppSettingKeyVaultReferenceSample.ts][webappsgetappsettingkeyvaultreferencesample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSetting.json | -| [webAppsGetAppSettingKeyVaultReferenceSlotSample.ts][webappsgetappsettingkeyvaultreferenceslotsample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingSlot.json | -| [webAppsGetAppSettingsKeyVaultReferencesSample.ts][webappsgetappsettingskeyvaultreferencessample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettings.json | -| [webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts][webappsgetappsettingskeyvaultreferencesslotsample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json | -| [webAppsGetFtpAllowedSample.ts][webappsgetftpallowedsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json | -| [webAppsGetFtpAllowedSlotSample.ts][webappsgetftpallowedslotsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json | -| [webAppsGetInstanceInfoSample.ts][webappsgetinstanceinfosample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json | -| [webAppsGetInstanceInfoSlotSample.ts][webappsgetinstanceinfoslotsample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json | -| [webAppsGetNetworkTraceOperationSample.ts][webappsgetnetworktraceoperationsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationSlotSample.ts][webappsgetnetworktraceoperationslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationSlotV2Sample.ts][webappsgetnetworktraceoperationslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTraceOperationV2Sample.ts][webappsgetnetworktraceoperationv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json | -| [webAppsGetNetworkTracesSample.ts][webappsgetnetworktracessample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesSlotSample.ts][webappsgetnetworktracesslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesSlotV2Sample.ts][webappsgetnetworktracesslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetNetworkTracesV2Sample.ts][webappsgetnetworktracesv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json | -| [webAppsGetPrivateEndpointConnectionSample.ts][webappsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json | -| [webAppsGetPrivateEndpointConnectionSlotSample.ts][webappsgetprivateendpointconnectionslotsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionSlot.json | -| [webAppsGetPrivateLinkResourcesSample.ts][webappsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json | -| [webAppsGetPrivateLinkResourcesSlotSample.ts][webappsgetprivatelinkresourcesslotsample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResourcesSlot.json | -| [webAppsGetProductionSiteDeploymentStatusSample.ts][webappsgetproductionsitedeploymentstatussample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatus.json | -| [webAppsGetScmAllowedSample.ts][webappsgetscmallowedsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json | -| [webAppsGetScmAllowedSlotSample.ts][webappsgetscmallowedslotsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json | -| [webAppsGetSlotSiteDeploymentStatusSlotSample.ts][webappsgetslotsitedeploymentstatusslotsample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatusSlot.json | -| [webAppsListBasicPublishingCredentialsPoliciesSample.ts][webappslistbasicpublishingcredentialspoliciessample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPolicies.json | -| [webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts][webappslistbasicpublishingcredentialspoliciesslotsample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPoliciesSlot.json | -| [webAppsListProductionSiteDeploymentStatusesSample.ts][webappslistproductionsitedeploymentstatusessample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatus.json | -| [webAppsListSiteBackupsSample.ts][webappslistsitebackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json | -| [webAppsListSiteBackupsSlotSample.ts][webappslistsitebackupsslotsample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json | -| [webAppsListSlotSiteDeploymentStatusesSlotSample.ts][webappslistslotsitedeploymentstatusesslotsample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatusSlot.json | -| [webAppsStartNetworkTraceSample.ts][webappsstartnetworktracesample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartNetworkTraceSlotSample.ts][webappsstartnetworktraceslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartWebSiteNetworkTraceOperationSample.ts][webappsstartwebsitenetworktraceoperationsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStartWebSiteNetworkTraceOperationSlotSample.ts][webappsstartwebsitenetworktraceoperationslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json | -| [webAppsStopNetworkTraceSample.ts][webappsstopnetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopNetworkTraceSlotSample.ts][webappsstopnetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopWebSiteNetworkTraceSample.ts][webappsstopwebsitenetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsStopWebSiteNetworkTraceSlotSample.ts][webappsstopwebsitenetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json | -| [webAppsUpdateFtpAllowedSample.ts][webappsupdateftpallowedsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json | -| [webAppsUpdateFtpAllowedSlotSample.ts][webappsupdateftpallowedslotsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json | -| [webAppsUpdateScmAllowedSample.ts][webappsupdatescmallowedsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json | -| [webAppsUpdateScmAllowedSlotSample.ts][webappsupdatescmallowedslotsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json | -| [workflowRunActionRepetitionsGetSample.ts][workflowrunactionrepetitionsgetsample] | Get a workflow run action repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_Get.json | -| [workflowRunActionRepetitionsListExpressionTracesSample.ts][workflowrunactionrepetitionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json | -| [workflowRunActionRepetitionsListSample.ts][workflowrunactionrepetitionslistsample] | Get all of a workflow run action repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_List.json | -| [workflowRunActionRepetitionsRequestHistoriesGetSample.ts][workflowrunactionrepetitionsrequesthistoriesgetsample] | Gets a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json | -| [workflowRunActionRepetitionsRequestHistoriesListSample.ts][workflowrunactionrepetitionsrequesthistorieslistsample] | List a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json | -| [workflowRunActionScopeRepetitionsGetSample.ts][workflowrunactionscoperepetitionsgetsample] | Get a workflow run action scoped repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_Get.json | -| [workflowRunActionScopeRepetitionsListSample.ts][workflowrunactionscoperepetitionslistsample] | List the workflow run action scoped repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_List.json | -| [workflowRunActionsGetSample.ts][workflowrunactionsgetsample] | Gets a workflow run action. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_Get.json | -| [workflowRunActionsListExpressionTracesSample.ts][workflowrunactionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_ListExpressionTraces.json | -| [workflowRunActionsListSample.ts][workflowrunactionslistsample] | Gets a list of workflow run actions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_List.json | -| [workflowRunsCancelSample.ts][workflowrunscancelsample] | Cancels a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Cancel.json | -| [workflowRunsGetSample.ts][workflowrunsgetsample] | Gets a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Get.json | -| [workflowRunsListSample.ts][workflowrunslistsample] | Gets a list of workflow runs. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_List.json | -| [workflowTriggerHistoriesGetSample.ts][workflowtriggerhistoriesgetsample] | Gets a workflow trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Get.json | -| [workflowTriggerHistoriesListSample.ts][workflowtriggerhistorieslistsample] | Gets a list of workflow trigger histories. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_List.json | -| [workflowTriggerHistoriesResubmitSample.ts][workflowtriggerhistoriesresubmitsample] | Resubmits a workflow run based on the trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Resubmit.json | -| [workflowTriggersGetSample.ts][workflowtriggersgetsample] | Gets a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Get.json | -| [workflowTriggersGetSchemaJsonSample.ts][workflowtriggersgetschemajsonsample] | Get the trigger schema as JSON. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_GetSchemaJson.json | -| [workflowTriggersListCallbackUrlSample.ts][workflowtriggerslistcallbackurlsample] | Get the callback URL for a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_ListCallbackUrl.json | -| [workflowTriggersListSample.ts][workflowtriggerslistsample] | Gets a list of workflow triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_List.json | -| [workflowTriggersRunSample.ts][workflowtriggersrunsample] | Runs a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Run.json | -| [workflowVersionsGetSample.ts][workflowversionsgetsample] | Gets a workflow version. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_Get.json | -| [workflowVersionsListSample.ts][workflowversionslistsample] | Gets a list of workflow versions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_List.json | -| [workflowsRegenerateAccessKeySample.ts][workflowsregenerateaccesskeysample] | Regenerates the callback URL access key for request triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_RegenerateAccessKey.json | -| [workflowsValidateSample.ts][workflowsvalidatesample] | Validates the workflow definition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_Validate.json | - -## Prerequisites - -The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule). - -Before running the samples in Node, they must be compiled to JavaScript using the TypeScript compiler. For more information on TypeScript, see the [TypeScript documentation][typescript]. Install the TypeScript compiler using: - -```bash -npm install -g typescript -``` - -You need [an Azure subscription][freesub] to run these sample programs. - -Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function. - -Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package]. - -## Setup - -To run the samples using the published version of the package: - -1. Install the dependencies using `npm`: - -```bash -npm install -``` - -2. Compile the samples: - -```bash -npm run build -``` - -3. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically. - -4. Run whichever samples you like (note that some samples may require additional setup, see the table above): - -```bash -node dist/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js -``` - -Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): - -```bash -npx cross-env node dist/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[appservicecertificateorderscreateorupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts -[appservicecertificateorderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts -[appservicecertificateordersdeletecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts -[appservicecertificateordersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteSample.ts -[appservicecertificateordersgetcertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts -[appservicecertificateordersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetSample.ts -[appservicecertificateorderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts -[appservicecertificateorderslistcertificatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts -[appservicecertificateorderslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListSample.ts -[appservicecertificateordersreissuesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersReissueSample.ts -[appservicecertificateordersrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRenewSample.ts -[appservicecertificateordersresendemailsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendEmailSample.ts -[appservicecertificateordersresendrequestemailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts -[appservicecertificateordersretrievecertificateactionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts -[appservicecertificateordersretrievecertificateemailhistorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts -[appservicecertificateordersretrievesitesealsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts -[appservicecertificateordersupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts -[appservicecertificateordersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateSample.ts -[appservicecertificateordersvalidatepurchaseinformationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts -[appservicecertificateordersverifydomainownershipsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts -[appserviceenvironmentsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts -[appserviceenvironmentschangevnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsChangeVnetSample.ts -[appserviceenvironmentscreateorupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts -[appserviceenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts -[appserviceenvironmentscreateorupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts -[appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts -[appserviceenvironmentsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts -[appserviceenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteSample.ts -[appserviceenvironmentsgetasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts -[appserviceenvironmentsgetasev3networkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts -[appserviceenvironmentsgetdiagnosticsitemsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts -[appserviceenvironmentsgetinboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts -[appserviceenvironmentsgetmultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts -[appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts -[appserviceenvironmentsgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts -[appserviceenvironmentsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts -[appserviceenvironmentsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts -[appserviceenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetSample.ts -[appserviceenvironmentsgetvipinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts -[appserviceenvironmentsgetworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts -[appserviceenvironmentslistappserviceplanssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts -[appserviceenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts -[appserviceenvironmentslistcapacitiessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts -[appserviceenvironmentslistdiagnosticssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts -[appserviceenvironmentslistmultirolemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts -[appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts -[appserviceenvironmentslistmultirolepoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts -[appserviceenvironmentslistmultirolepoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts -[appserviceenvironmentslistmultiroleusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts -[appserviceenvironmentslistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListOperationsSample.ts -[appserviceenvironmentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListSample.ts -[appserviceenvironmentslistusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListUsagesSample.ts -[appserviceenvironmentslistwebappssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebAppsSample.ts -[appserviceenvironmentslistwebworkermetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts -[appserviceenvironmentslistwebworkerusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts -[appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts -[appserviceenvironmentslistworkerpoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts -[appserviceenvironmentslistworkerpoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts -[appserviceenvironmentsrebootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsRebootSample.ts -[appserviceenvironmentsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsResumeSample.ts -[appserviceenvironmentssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsSuspendSample.ts -[appserviceenvironmentstestupgradeavailablenotificationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts -[appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts -[appserviceenvironmentsupdateasenetworkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts -[appserviceenvironmentsupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts -[appserviceenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateSample.ts -[appserviceenvironmentsupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts -[appserviceenvironmentsupgradesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpgradeSample.ts -[appserviceplanscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansCreateOrUpdateSample.ts -[appserviceplansdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansDeleteSample.ts -[appserviceplansgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansGetSample.ts -[appserviceplanslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListByResourceGroupSample.ts -[appserviceplanslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListSample.ts -[appserviceplansupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansUpdateSample.ts -[certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts -[certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts -[certificateregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateRegistrationProviderListOperationsSample.ts -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesCreateOrUpdateSample.ts -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesDeleteSample.ts -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesGetSample.ts -[certificateslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListByResourceGroupSample.ts -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListSample.ts -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesUpdateSample.ts -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsCreateOrUpdateSample.ts -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsDeleteSample.ts -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsGetSample.ts -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListByResourceGroupSample.ts -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListBySubscriptionSample.ts -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListSecretsSample.ts -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsActivateRevisionSample.ts -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsGetRevisionSample.ts -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsListRevisionsSample.ts -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsRestartRevisionSample.ts -[deletedwebappsgetdeletedwebappbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts -[deletedwebappslistbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsListByLocationSample.ts -[diagnosticsexecutesiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts -[diagnosticsexecutesiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts -[diagnosticsexecutesitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSample.ts -[diagnosticsexecutesitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts -[diagnosticsgethostingenvironmentdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts -[diagnosticsgetsiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSample.ts -[diagnosticsgetsiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts -[diagnosticsgetsitedetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts -[diagnosticsgetsitedetectorresponseslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts -[diagnosticsgetsitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSample.ts -[diagnosticsgetsitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts -[diagnosticsgetsitediagnosticcategorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts -[diagnosticsgetsitediagnosticcategoryslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts -[diagnosticslisthostingenvironmentdetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts -[diagnosticslistsiteanalysessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSample.ts -[diagnosticslistsiteanalysesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts -[diagnosticslistsitedetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts -[diagnosticslistsitedetectorresponsesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts -[diagnosticslistsitedetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSample.ts -[diagnosticslistsitedetectorsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts -[diagnosticslistsitediagnosticcategoriessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts -[diagnosticslistsitediagnosticcategoriesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts -[domainregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainRegistrationProviderListOperationsSample.ts -[domainscheckavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCheckAvailabilitySample.ts -[domainscreateorupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts -[domainscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateSample.ts -[domainsdeleteownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteOwnershipIdentifierSample.ts -[domainsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteSample.ts -[domainsgetcontrolcenterssorequestsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetControlCenterSsoRequestSample.ts -[domainsgetownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetOwnershipIdentifierSample.ts -[domainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetSample.ts -[domainslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListByResourceGroupSample.ts -[domainslistownershipidentifierssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListOwnershipIdentifiersSample.ts -[domainslistrecommendationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListRecommendationsSample.ts -[domainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListSample.ts -[domainsrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsRenewSample.ts -[domainstransferoutsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsTransferOutSample.ts -[domainsupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateOwnershipIdentifierSample.ts -[domainsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateSample.ts -[globalgetdeletedwebappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSample.ts -[globalgetdeletedwebappsnapshotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts -[globalgetsubscriptionoperationwithasyncresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts -[kubeenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts -[kubeenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsDeleteSample.ts -[kubeenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsGetSample.ts -[kubeenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts -[kubeenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts -[kubeenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsUpdateSample.ts -[listcustomhostnamesitessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/listCustomHostNameSitesSample.ts -[providergetfunctionappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksForLocationSample.ts -[providergetfunctionappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksSample.ts -[providergetwebappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksForLocationSample.ts -[providergetwebappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksSample.ts -[providerlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerListOperationsSample.ts -[resourcehealthmetadatagetbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSample.ts -[resourcehealthmetadatagetbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts -[resourcehealthmetadatalistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts -[resourcehealthmetadatalistbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSample.ts -[resourcehealthmetadatalistbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts -[resourcehealthmetadatalistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListSample.ts -[staticsitesapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts -[staticsitescreateorupdatestaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts -[staticsitescreateorupdatestaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts -[staticsitescreateorupdatestaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts -[staticsitescreateorupdatestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts -[staticsitescreateorupdatestaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts -[staticsitescreateorupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts -[staticsitescreateuserrolesinvitationlinksample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts -[staticsitescreatezipdeploymentforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts -[staticsitescreatezipdeploymentforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts -[staticsitesdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts -[staticsitesdeletestaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts -[staticsitesdeletestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts -[staticsitesdeletestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteSample.ts -[staticsitesdeletestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteUserSample.ts -[staticsitesdetachstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachStaticSiteSample.ts -[staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts -[staticsitesdetachuserprovidedfunctionappfromstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts -[staticsitesgetlinkedbackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts -[staticsitesgetlinkedbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendSample.ts -[staticsitesgetlinkedbackendsforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts -[staticsitesgetlinkedbackendssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsSample.ts -[staticsitesgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts -[staticsitesgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts -[staticsitesgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts -[staticsitesgetstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildSample.ts -[staticsitesgetstaticsitebuildssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildsSample.ts -[staticsitesgetstaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts -[staticsitesgetstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteSample.ts -[staticsitesgetstaticsitesbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts -[staticsitesgetuserprovidedfunctionappforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts -[staticsitesgetuserprovidedfunctionappforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts -[staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts -[staticsitesgetuserprovidedfunctionappsforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts -[staticsiteslinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendSample.ts -[staticsiteslinkbackendtobuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendToBuildSample.ts -[staticsiteslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListSample.ts -[staticsitesliststaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts -[staticsitesliststaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts -[staticsitesliststaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts -[staticsitesliststaticsitebuildfunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts -[staticsitesliststaticsiteconfiguredrolessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts -[staticsitesliststaticsitecustomdomainssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts -[staticsitesliststaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts -[staticsitesliststaticsitefunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionsSample.ts -[staticsitesliststaticsitesecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteSecretsSample.ts -[staticsitesliststaticsiteuserssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteUsersSample.ts -[staticsitespreviewworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesPreviewWorkflowSample.ts -[staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts -[staticsitesregisteruserprovidedfunctionappwithstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts -[staticsitesresetstaticsiteapikeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesResetStaticSiteApiKeySample.ts -[staticsitesunlinkbackendfrombuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts -[staticsitesunlinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendSample.ts -[staticsitesupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteSample.ts -[staticsitesupdatestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteUserSample.ts -[staticsitesvalidatebackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendForBuildSample.ts -[staticsitesvalidatebackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendSample.ts -[staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts -[topleveldomainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsGetSample.ts -[topleveldomainslistagreementssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListAgreementsSample.ts -[topleveldomainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListSample.ts -[verifyhostingenvironmentvnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/verifyHostingEnvironmentVnetSample.ts -[webappsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts -[webappsapproveorrejectprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts -[webappsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts -[webappsdeleteprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts -[webappsgetappsettingkeyvaultreferencesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts -[webappsgetappsettingkeyvaultreferenceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts -[webappsgetappsettingskeyvaultreferencessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts -[webappsgetappsettingskeyvaultreferencesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts -[webappsgetftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSample.ts -[webappsgetftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSlotSample.ts -[webappsgetinstanceinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSample.ts -[webappsgetinstanceinfoslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSlotSample.ts -[webappsgetnetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSample.ts -[webappsgetnetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts -[webappsgetnetworktraceoperationslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts -[webappsgetnetworktraceoperationv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts -[webappsgetnetworktracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSample.ts -[webappsgetnetworktracesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotSample.ts -[webappsgetnetworktracesslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts -[webappsgetnetworktracesv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesV2Sample.ts -[webappsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts -[webappsgetprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts -[webappsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSample.ts -[webappsgetprivatelinkresourcesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts -[webappsgetproductionsitedeploymentstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts -[webappsgetscmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSample.ts -[webappsgetscmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSlotSample.ts -[webappsgetslotsitedeploymentstatusslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts -[webappslistbasicpublishingcredentialspoliciessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts -[webappslistbasicpublishingcredentialspoliciesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts -[webappslistproductionsitedeploymentstatusessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts -[webappslistsitebackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSample.ts -[webappslistsitebackupsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSlotSample.ts -[webappslistslotsitedeploymentstatusesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts -[webappsstartnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSample.ts -[webappsstartnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSlotSample.ts -[webappsstartwebsitenetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts -[webappsstartwebsitenetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts -[webappsstopnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSample.ts -[webappsstopnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSlotSample.ts -[webappsstopwebsitenetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts -[webappsstopwebsitenetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts -[webappsupdateftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSample.ts -[webappsupdateftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts -[webappsupdatescmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSample.ts -[webappsupdatescmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSlotSample.ts -[workflowrunactionrepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsGetSample.ts -[workflowrunactionrepetitionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts -[workflowrunactionrepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListSample.ts -[workflowrunactionrepetitionsrequesthistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts -[workflowrunactionrepetitionsrequesthistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts -[workflowrunactionscoperepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts -[workflowrunactionscoperepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsListSample.ts -[workflowrunactionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsGetSample.ts -[workflowrunactionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListExpressionTracesSample.ts -[workflowrunactionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListSample.ts -[workflowrunscancelsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsCancelSample.ts -[workflowrunsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsGetSample.ts -[workflowrunslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsListSample.ts -[workflowtriggerhistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesGetSample.ts -[workflowtriggerhistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesListSample.ts -[workflowtriggerhistoriesresubmitsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesResubmitSample.ts -[workflowtriggersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSample.ts -[workflowtriggersgetschemajsonsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSchemaJsonSample.ts -[workflowtriggerslistcallbackurlsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListCallbackUrlSample.ts -[workflowtriggerslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListSample.ts -[workflowtriggersrunsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersRunSample.ts -[workflowversionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsGetSample.ts -[workflowversionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsListSample.ts -[workflowsregenerateaccesskeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsRegenerateAccessKeySample.ts -[workflowsvalidatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsValidateSample.ts -[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-appservice?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice/README.md -[typescript]: https://www.typescriptlang.org/docs/home.html diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts deleted file mode 100644 index 0a8217b4999f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete the certificate associated with a certificate order. - * - * @summary Description for Delete the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificate.json - */ -async function deleteAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const name = "SampleCertName1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.deleteCertificate( - resourceGroupName, - certificateOrderName, - name - ); - console.log(result); -} - -deleteAppServiceCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteSample.ts deleted file mode 100644 index ce9d1a9934fa..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete an existing certificate order. - * - * @summary Description for Delete an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificateOrder.json - */ -async function deleteAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.delete( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -deleteAppServiceCertificateOrder().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts deleted file mode 100644 index 305a7346fed8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the certificate associated with a certificate order. - * - * @summary Description for Get the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificate.json - */ -async function getAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const name = "SampleCertName1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.getCertificate( - resourceGroupName, - certificateOrderName, - name - ); - console.log(result); -} - -getAppServiceCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetSample.ts deleted file mode 100644 index 906bd3e6b7a3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersGetSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get a certificate order. - * - * @summary Description for Get a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificateOrder.json - */ -async function getAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.get( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -getAppServiceCertificateOrder().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts deleted file mode 100644 index faa619a08286..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get certificate orders in a resource group. - * - * @summary Description for Get certificate orders in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json - */ -async function listAppServiceCertificateOrdersByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceCertificateOrders.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppServiceCertificateOrdersByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts deleted file mode 100644 index 95906b80949d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List all certificates associated with a certificate order. - * - * @summary Description for List all certificates associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListCertificatesByAppServiceCertificateOrder.json - */ -async function listCertificatesByAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceCertificateOrders.listCertificates( - resourceGroupName, - certificateOrderName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByAppServiceCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendEmailSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendEmailSample.ts deleted file mode 100644 index b17e990400e1..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendEmailSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Resend certificate email. - * - * @summary Description for Resend certificate email. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendAppServiceCertificateOrderEmail.json - */ -async function resendAppServiceCertificateOrderEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.resendEmail( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -resendAppServiceCertificateOrderEmail().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts deleted file mode 100644 index 1143dede767a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Retrieve the list of certificate actions. - * - * @summary Description for Retrieve the list of certificate actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateOrderActions.json - */ -async function retrieveCertificateOrderActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleCertOrder"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.retrieveCertificateActions( - resourceGroupName, - name - ); - console.log(result); -} - -retrieveCertificateOrderActions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts deleted file mode 100644 index b1a4c766512a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Retrieve email history. - * - * @summary Description for Retrieve email history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveCertificateEmailHistory.json - */ -async function retrieveCertificateEmailHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleCertOrder"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.retrieveCertificateEmailHistory( - resourceGroupName, - name - ); - console.log(result); -} - -retrieveCertificateEmailHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts deleted file mode 100644 index 1c6edd6b3c15..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Verify domain ownership for this certificate order. - * - * @summary Description for Verify domain ownership for this certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/VerifyDomainOwnership.json - */ -async function verifyDomainOwnership() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceCertificateOrders.verifyDomainOwnership( - resourceGroupName, - certificateOrderName - ); - console.log(result); -} - -verifyDomainOwnership().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts deleted file mode 100644 index ac835dae20ff..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WorkerPoolResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a multi-role pool. - * - * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json - */ -async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const multiRolePoolEnvelope: WorkerPoolResource = { - workerCount: 3, - workerSize: "Medium" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginCreateOrUpdateMultiRolePoolAndWait( - resourceGroupName, - name, - multiRolePoolEnvelope - ); - console.log(result); -} - -createOrUpdateAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts deleted file mode 100644 index b517ffc6b617..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WorkerPoolResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a worker pool. - * - * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json - */ -async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "0"; - const workerPoolEnvelope: WorkerPoolResource = { - workerCount: 3, - workerSize: "Small" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginCreateOrUpdateWorkerPoolAndWait( - resourceGroupName, - name, - workerPoolName, - workerPoolEnvelope - ); - console.log(result); -} - -getPropertiesOfAWorkerPool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts deleted file mode 100644 index 5aa3d488ea60..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Delete Custom Dns Suffix configuration of an App Service Environment - * - * @summary Delete Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAseCustomDnsSuffixConfiguration.json - */ -async function deleteAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.deleteAseCustomDnsSuffixConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -deleteAseCustomDnsSuffixConfiguration().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts deleted file mode 100644 index 6dd37e3b671a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json - */ -async function deletesAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginDeletePrivateEndpointConnectionAndWait( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -deletesAPrivateEndpointConnection().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteSample.ts deleted file mode 100644 index 2a7bc6bf6b8a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete an App Service Environment. - * - * @summary Description for Delete an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Delete.json - */ -async function deleteAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts deleted file mode 100644 index a60b12cfaec7..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get Custom Dns Suffix configuration of an App Service Environment - * - * @summary Get Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAseCustomDnsSuffixConfiguration.json - */ -async function getAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getAseCustomDnsSuffixConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -getAseCustomDnsSuffixConfiguration().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts deleted file mode 100644 index abb594d4e517..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get networking configuration of an App Service Environment - * - * @summary Description for Get networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json - */ -async function getNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getAseV3NetworkingConfiguration( - resourceGroupName, - name - ); - console.log(result); -} - -getNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts deleted file mode 100644 index 7c19a75a6d24..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get a diagnostics item for an App Service Environment. - * - * @summary Description for Get a diagnostics item for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json - */ -async function getADiagnosticsItemForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const diagnosticsName = "test-diagnostic"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getDiagnosticsItem( - resourceGroupName, - name, - diagnosticsName - ); - console.log(result); -} - -getADiagnosticsItemForAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts deleted file mode 100644 index c4ae05e3e12e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the network endpoints of all inbound dependencies of an App Service Environment. - * - * @summary Description for Get the network endpoints of all inbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetInboundNetworkDependenciesEndpoints.json - */ -async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAse"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listInboundNetworkDependenciesEndpoints( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts deleted file mode 100644 index ff5e4d6c07ff..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get properties of a multi-role pool. - * - * @summary Description for Get properties of a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetMultiRolePool.json - */ -async function getPropertiesOfAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getMultiRolePool( - resourceGroupName, - name - ); - console.log(result); -} - -getPropertiesOfAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts deleted file mode 100644 index e95bec416a4a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the network endpoints of all outbound dependencies of an App Service Environment. - * - * @summary Description for Get the network endpoints of all outbound dependencies of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetOutboundNetworkDependenciesEndpoints.json - */ -async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAse"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listOutboundNetworkDependenciesEndpoints( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts deleted file mode 100644 index de27aa0cfddc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the list of private endpoints associated with a hosting environment - * - * @summary Description for Gets the list of private endpoints associated with a hosting environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json - */ -async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listPrivateEndpointConnectionList( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts deleted file mode 100644 index f5b01f9b52a2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json - */ -async function getsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getPrivateEndpointConnection( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -getsAPrivateEndpointConnection().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts deleted file mode 100644 index 558fc46ad940..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json - */ -async function getsThePrivateLinkResources() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getPrivateLinkResources( - resourceGroupName, - name - ); - console.log(result); -} - -getsThePrivateLinkResources().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetSample.ts deleted file mode 100644 index 60243a81a093..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the properties of an App Service Environment. - * - * @summary Description for Get the properties of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Get.json - */ -async function getThePropertiesOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.get( - resourceGroupName, - name - ); - console.log(result); -} - -getThePropertiesOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts deleted file mode 100644 index c80c30e4184b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get IP addresses assigned to an App Service Environment. - * - * @summary Description for Get IP addresses assigned to an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetVipInfo.json - */ -async function getIPAddressesAssignedToAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getVipInfo( - resourceGroupName, - name - ); - console.log(result); -} - -getIPAddressesAssignedToAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts deleted file mode 100644 index 4e010a7a5c47..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get properties of a worker pool. - * - * @summary Description for Get properties of a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetWorkerPool.json - */ -async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "workerPool1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.getWorkerPool( - resourceGroupName, - name, - workerPoolName - ); - console.log(result); -} - -getPropertiesOfAWorkerPool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts deleted file mode 100644 index acdd6375b53e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all App Service plans in an App Service Environment. - * - * @summary Description for Get all App Service plans in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListAppServicePlans.json - */ -async function getAllAppServicePlansInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listAppServicePlans( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppServicePlansInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index b88e9b7c10fe..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all App Service Environments in a resource group. - * - * @summary Description for Get all App Service Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListByResourceGroup.json - */ -async function getAllAppServiceEnvironmentsInAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppServiceEnvironmentsInAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts deleted file mode 100644 index 1ab10666b97c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the used, available, and total worker capacity an App Service Environment. - * - * @summary Description for Get the used, available, and total worker capacity an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListCapacities.json - */ -async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listCapacities( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts deleted file mode 100644 index f803e6d7e70e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get diagnostic information for an App Service Environment. - * - * @summary Description for Get diagnostic information for an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListDiagnostics.json - */ -async function getDiagnosticInformationForAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.listDiagnostics( - resourceGroupName, - name - ); - console.log(result); -} - -getDiagnosticInformationForAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts deleted file mode 100644 index 0f6e3eb42940..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get metric definitions for a multi-role pool of an App Service Environment. - * - * @summary Description for Get metric definitions for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json - */ -async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRoleMetricDefinitions( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts deleted file mode 100644 index 1631c1ac8891..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. - * - * @summary Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json - */ -async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const instance = "10.7.1.8"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRolePoolInstanceMetricDefinitions( - resourceGroupName, - name, - instance - )) { - resArray.push(item); - } - console.log(resArray); -} - -getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts deleted file mode 100644 index 3575848be4f5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get available SKUs for scaling a multi-role pool. - * - * @summary Description for Get available SKUs for scaling a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json - */ -async function getAvailableSkUsForScalingAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRolePoolSkus( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAvailableSkUsForScalingAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts deleted file mode 100644 index dc8e63bd4e57..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all multi-role pools. - * - * @summary Description for Get all multi-role pools. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePools.json - */ -async function getAllMultiRolePools() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRolePools( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllMultiRolePools().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts deleted file mode 100644 index 171289ebb5ae..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get usage metrics for a multi-role pool of an App Service Environment. - * - * @summary Description for Get usage metrics for a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json - */ -async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listMultiRoleUsages( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListOperationsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListOperationsSample.ts deleted file mode 100644 index 2bbe9293b348..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListOperationsSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List all currently running operations on the App Service Environment. - * - * @summary Description for List all currently running operations on the App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListOperations.json - */ -async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.listOperations( - resourceGroupName, - name - ); - console.log(result); -} - -listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListUsagesSample.ts deleted file mode 100644 index 420a41c37423..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListUsagesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get global usage metrics of an App Service Environment. - * - * @summary Description for Get global usage metrics of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListUsages.json - */ -async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listUsages( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getGlobalUsageMetricsOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebAppsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebAppsSample.ts deleted file mode 100644 index e8c539235e3d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebAppsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all apps in an App Service Environment. - * - * @summary Description for Get all apps in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebApps.json - */ -async function getAllAppsInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWebApps( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllAppsInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts deleted file mode 100644 index f7762e4002eb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get metric definitions for a worker pool of an App Service Environment. - * - * @summary Description for Get metric definitions for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json - */ -async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWebWorkerMetricDefinitions( - resourceGroupName, - name, - workerPoolName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts deleted file mode 100644 index 2f5e4f03b531..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get usage metrics for a worker pool of an App Service Environment. - * - * @summary Description for Get usage metrics for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json - */ -async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWebWorkerUsages( - resourceGroupName, - name, - workerPoolName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts deleted file mode 100644 index d4e9f1ba2453..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get available SKUs for scaling a worker pool. - * - * @summary Description for Get available SKUs for scaling a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json - */ -async function getAvailableSkUsForScalingAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "workerPool1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWorkerPoolSkus( - resourceGroupName, - name, - workerPoolName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAvailableSkUsForScalingAWorkerPool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts deleted file mode 100644 index a6dfb8486625..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all worker pools of an App Service Environment. - * - * @summary Description for Get all worker pools of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPools.json - */ -async function getAllWorkerPoolsOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.listWorkerPools( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllWorkerPoolsOfAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsRebootSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsRebootSample.ts deleted file mode 100644 index e4ad77bca460..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsRebootSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Reboot all machines in an App Service Environment. - * - * @summary Description for Reboot all machines in an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Reboot.json - */ -async function rebootAllMachinesInAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.reboot( - resourceGroupName, - name - ); - console.log(result); -} - -rebootAllMachinesInAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsResumeSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsResumeSample.ts deleted file mode 100644 index 221ff4fd9143..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsResumeSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Resume an App Service Environment. - * - * @summary Description for Resume an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Resume.json - */ -async function resumeAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.beginListResumeAndWait( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -resumeAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsSuspendSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsSuspendSample.ts deleted file mode 100644 index 4ebd9fa3aa92..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsSuspendSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Suspend an App Service Environment. - * - * @summary Description for Suspend an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Suspend.json - */ -async function suspendAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServiceEnvironments.beginListSuspendAndWait( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -suspendAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts deleted file mode 100644 index 1d98f0b54e76..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Send a test notification that an upgrade is available for this App Service Environment. - * - * @summary Send a test notification that an upgrade is available for this App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json - */ -async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "SampleHostingEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.testUpgradeAvailableNotification( - resourceGroupName, - name - ); - console.log(result); -} - -sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts deleted file mode 100644 index 0406015f59c3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WorkerPoolResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a multi-role pool. - * - * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json - */ -async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const multiRolePoolEnvelope: WorkerPoolResource = { - workerCount: 3, - workerSize: "Medium" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.updateMultiRolePool( - resourceGroupName, - name, - multiRolePoolEnvelope - ); - console.log(result); -} - -createOrUpdateAMultiRolePool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts deleted file mode 100644 index 81fb6bd24298..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WorkerPoolResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a worker pool. - * - * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json - */ -async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; - const name = "test-ase"; - const workerPoolName = "0"; - const workerPoolEnvelope: WorkerPoolResource = { - workerCount: 3, - workerSize: "Small" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.updateWorkerPool( - resourceGroupName, - name, - workerPoolName, - workerPoolEnvelope - ); - console.log(result); -} - -getPropertiesOfAWorkerPool().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpgradeSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpgradeSample.ts deleted file mode 100644 index 50f5379e1e73..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpgradeSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Initiate an upgrade of an App Service Environment if one is available. - * - * @summary Description for Initiate an upgrade of an App Service Environment if one is available. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Upgrade.json - */ -async function initiateAnUpgradeOnAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "SampleHostingEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServiceEnvironments.beginUpgradeAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -initiateAnUpgradeOnAnAppServiceEnvironment().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansCreateOrUpdateSample.ts deleted file mode 100644 index 2d8beab309d0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansCreateOrUpdateSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { AppServicePlan, WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates an App Service Plan. - * - * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateAppServicePlan.json - */ -async function createOrUpdateAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const appServicePlan: AppServicePlan = { - kind: "app", - location: "East US", - sku: { name: "P1", capacity: 1, family: "P", size: "P1", tier: "Premium" } - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.beginCreateOrUpdateAndWait( - resourceGroupName, - name, - appServicePlan - ); - console.log(result); -} - -createOrUpdateAppServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansDeleteSample.ts deleted file mode 100644 index 3facd811971c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansDeleteSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete an App Service plan. - * - * @summary Description for Delete an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteAppServicePlan.json - */ -async function deleteAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.delete(resourceGroupName, name); - console.log(result); -} - -deleteAppServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansGetSample.ts deleted file mode 100644 index 30078a70fedc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get an App Service plan. - * - * @summary Description for Get an App Service plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAppServicePlan.json - */ -async function getAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.get(resourceGroupName, name); - console.log(result); -} - -getAppServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListByResourceGroupSample.ts deleted file mode 100644 index 3f0e99b140a5..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all App Service plans in a resource group. - * - * @summary Description for Get all App Service plans in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlansByResourceGroup.json - */ -async function listAppServicePlansByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appServicePlans.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppServicePlansByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansUpdateSample.ts deleted file mode 100644 index bdaa4bc3a512..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansUpdateSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - AppServicePlanPatchResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates an App Service Plan. - * - * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchAppServicePlan.json - */ -async function patchServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testsf6141"; - const appServicePlan: AppServicePlanPatchResource = { kind: "app" }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.appServicePlans.update( - resourceGroupName, - name, - appServicePlan - ); - console.log(result); -} - -patchServicePlan().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts deleted file mode 100644 index 36237e628535..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. - * - * @summary Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json - */ -async function getAppServiceCertificateOrderDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const certificateOrderName = "SampleCertificateOrderName"; - const detectorName = "AutoRenewStatus"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificateOrdersDiagnostics.getAppServiceCertificateOrderDetectorResponse( - resourceGroupName, - certificateOrderName, - detectorName - ); - console.log(result); -} - -getAppServiceCertificateOrderDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts deleted file mode 100644 index dda6b6ce756b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. - * - * @summary Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json - */ -async function listAppServiceCertificateDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const certificateOrderName = "SampleCertificateOrderName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificateOrdersDiagnostics.listAppServiceCertificateOrderDetectorResponse( - resourceGroupName, - certificateOrderName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppServiceCertificateDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesCreateOrUpdateSample.ts deleted file mode 100644 index a0f8eb601720..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { Certificate, WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a certificate. - * - * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateCertificate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const certificateEnvelope: Certificate = { - hostNames: ["ServerCert"], - location: "East US", - password: "" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - name, - certificateEnvelope - ); - console.log(result); -} - -createOrUpdateCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesDeleteSample.ts deleted file mode 100644 index 49b858c2b590..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesDeleteSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a certificate. - * - * @summary Description for Delete a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteCertificate.json - */ -async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.delete(resourceGroupName, name); - console.log(result); -} - -deleteCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesGetSample.ts deleted file mode 100644 index 3637ec2347da..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get a certificate. - * - * @summary Description for Get a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetCertificate.json - */ -async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.get(resourceGroupName, name); - console.log(result); -} - -getCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListByResourceGroupSample.ts deleted file mode 100644 index 4ee4118926e6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all certificates in a resource group. - * - * @summary Description for Get all certificates in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificatesByResourceGroup.json - */ -async function listCertificatesByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesUpdateSample.ts deleted file mode 100644 index 15d05398ce1c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - CertificatePatchResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a certificate. - * - * @summary Description for Create or update a certificate. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchCertificate.json - */ -async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const certificateEnvelope: CertificatePatchResource = { - password: "" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.certificates.update( - resourceGroupName, - name, - certificateEnvelope - ); - console.log(result); -} - -patchCertificate().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsDeleteSample.ts deleted file mode 100644 index a35dda53d7df..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App. - * - * @summary Description for Delete a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteContainerApp.json - */ -async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteContainerApp().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsGetSample.ts deleted file mode 100644 index 4df67104b01e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the properties of a Container App. - * - * @summary Get the properties of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetContainerApp.json - */ -async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, name); - console.log(result); -} - -getContainerApp().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListByResourceGroupSample.ts deleted file mode 100644 index b48bcdc9a867..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Container Apps in a given resource group. - * - * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerApps.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listContainerAppsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListSecretsSample.ts deleted file mode 100644 index 649f71d6593c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListSecretsSample.ts +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List secrets for a container app - * - * @summary List secrets for a container app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets(name); - console.log(result); -} - -listContainerAppsSecrets().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsActivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsActivateRevisionSample.ts deleted file mode 100644 index 1dd4ee90c9a2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsActivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Activates a revision for a Container App - * - * @summary Activates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ActivateRevision.json - */ -async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -activateContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts deleted file mode 100644 index 5d4bcd195a09..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Deactivates a revision for a Container App - * - * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeactivateRevision.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deactivateContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsGetRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsGetRevisionSample.ts deleted file mode 100644 index 1d7a151ffc1a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsGetRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get a revision of a Container App. - * - * @summary Get a revision of a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetRevision.json - */ -async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsListRevisionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsListRevisionsSample.ts deleted file mode 100644 index 0fa4a0b7a35e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsListRevisionsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Revisions for a given Container App. - * - * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListRevisions.json - */ -async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsRevisions.listRevisions( - resourceGroupName, - containerAppName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listContainerAppRevisions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsRestartRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsRestartRevisionSample.ts deleted file mode 100644 index 663297ced72a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsRevisionsRestartRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Restarts a revision for a Container App - * - * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RestartRevision.json - */ -async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testStaticSite0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -restartContainerAppRevision().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts deleted file mode 100644 index c009048641ad..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json - */ -async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -executeSiteAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json - */ -async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -executeSiteSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts deleted file mode 100644 index bded91e0ec9b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysis.json - */ -async function executeSiteAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -executeSiteAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Analysis - * - * @summary Description for Execute Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json - */ -async function executeSiteSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "apprestartanalyses"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -executeSiteSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSample.ts deleted file mode 100644 index 57305c0d84a4..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json - */ -async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetector( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory - ); - console.log(result); -} - -executeSiteDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json - */ -async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetector( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory - ); - console.log(result); -} - -executeSiteSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts deleted file mode 100644 index e9f4345635d7..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetector.json - */ -async function executeSiteDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetectorSlot( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory, - slot - ); - console.log(result); -} - -executeSiteDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Execute Detector - * - * @summary Description for Execute Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json - */ -async function executeSiteSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "sitecrashes"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.executeSiteDetectorSlot( - resourceGroupName, - siteName, - detectorName, - diagnosticCategory, - slot - ); - console.log(result); -} - -executeSiteSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts deleted file mode 100644 index 7101af65c759..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Hosting Environment Detector Response - * - * @summary Description for Get Hosting Environment Detector Response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json - */ -async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAppServiceEnvironment"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getHostingEnvironmentDetectorResponse( - resourceGroupName, - name, - detectorName - ); - console.log(result); -} - -getAppServiceEnvironmentDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSample.ts deleted file mode 100644 index f8d788e342b9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json - */ -async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -getAppAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json - */ -async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysis( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName - ); - console.log(result); -} - -getAppSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts deleted file mode 100644 index f43fe7e64755..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysis.json - */ -async function getAppAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -getAppAnalysis().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analysis - * - * @summary Description for Get Site Analysis - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteAnalysisSlot.json - */ -async function getAppSlotAnalysis() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const analysisName = "appanalysis"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteAnalysisSlot( - resourceGroupName, - siteName, - diagnosticCategory, - analysisName, - slot - ); - console.log(result); -} - -getAppSlotAnalysis().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts deleted file mode 100644 index 47add308da01..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json - */ -async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponse( - resourceGroupName, - siteName, - detectorName - ); - console.log(result); -} - -getAppDetectorResponse().catch(console.error); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json - */ -async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponse( - resourceGroupName, - siteName, - detectorName - ); - console.log(result); -} - -getAppSlotDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts deleted file mode 100644 index c0541318f24a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponse.json - */ -async function getAppDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponseSlot( - resourceGroupName, - siteName, - detectorName, - slot - ); - console.log(result); -} - -getAppDetectorResponse().catch(console.error); - -/** - * This sample demonstrates how to Description for Get site detector response - * - * @summary Description for Get site detector response - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json - */ -async function getAppSlotDetectorResponse() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const detectorName = "runtimeavailability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorResponseSlot( - resourceGroupName, - siteName, - detectorName, - slot - ); - console.log(result); -} - -getAppSlotDetectorResponse().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSample.ts deleted file mode 100644 index 0c2f9aec5e29..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json - */ -async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetector( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName - ); - console.log(result); -} - -getAppDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json - */ -async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetector( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName - ); - console.log(result); -} - -getAppSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts deleted file mode 100644 index 766708da352d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetector.json - */ -async function getAppDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorSlot( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName, - slot - ); - console.log(result); -} - -getAppDetector().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detector - * - * @summary Description for Get Detector - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDetectorSlot.json - */ -async function getAppSlotDetector() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const detectorName = "sitecrashes"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDetectorSlot( - resourceGroupName, - siteName, - diagnosticCategory, - detectorName, - slot - ); - console.log(result); -} - -getAppSlotDetector().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts deleted file mode 100644 index 0070c317e483..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json - */ -async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategory( - resourceGroupName, - siteName, - diagnosticCategory - ); - console.log(result); -} - -getAppDiagnosticCategory().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json - */ -async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategory( - resourceGroupName, - siteName, - diagnosticCategory - ); - console.log(result); -} - -getAppSlotDiagnosticCategory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts deleted file mode 100644 index a931dc0d8574..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategory.json - */ -async function getAppDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategorySlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - ); - console.log(result); -} - -getAppDiagnosticCategory().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Category - * - * @summary Description for Get Diagnostics Category - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json - */ -async function getAppSlotDiagnosticCategory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.diagnostics.getSiteDiagnosticCategorySlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - ); - console.log(result); -} - -getAppSlotDiagnosticCategory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts deleted file mode 100644 index cb13d9e2b40f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List Hosting Environment Detector Responses - * - * @summary Description for List Hosting Environment Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json - */ -async function getAppServiceEnvironmentDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const name = "SampleAppServiceEnvironment"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listHostingEnvironmentDetectorResponses( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppServiceEnvironmentDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSample.ts deleted file mode 100644 index a0f99d6643e0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSample.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json - */ -async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalyses( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppAnalyses().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json - */ -async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalyses( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotAnalyses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts deleted file mode 100644 index c2c1af3e7720..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalyses.json - */ -async function listAppAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalysesSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppAnalyses().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Site Analyses - * - * @summary Description for Get Site Analyses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteAnalysesSlot.json - */ -async function listAppSlotAnalyses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteAnalysesSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotAnalyses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts deleted file mode 100644 index 3eecdbe1735b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json - */ -async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponses( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppDetectorResponses().catch(console.error); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json - */ -async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponses( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppSlotDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts deleted file mode 100644 index 23cbf60cef97..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponses.json - */ -async function getAppDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppDetectorResponses().catch(console.error); - -/** - * This sample demonstrates how to Description for List Site Detector Responses - * - * @summary Description for List Site Detector Responses - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json - */ -async function getAppSlotDetectorResponses() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAppSlotDetectorResponses().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSample.ts deleted file mode 100644 index dede03547811..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSample.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json - */ -async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectors( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDetectors().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json - */ -async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectors( - resourceGroupName, - siteName, - diagnosticCategory - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDetectors().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts deleted file mode 100644 index e152da4cb5bb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectors.json - */ -async function listAppDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorsSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDetectors().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Detectors - * - * @summary Description for Get Detectors - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDetectorsSlot.json - */ -async function listAppSlotDetectors() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const diagnosticCategory = "availability"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDetectorsSlot( - resourceGroupName, - siteName, - diagnosticCategory, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDetectors().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts deleted file mode 100644 index 7f01863932d7..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json - */ -async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategories( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDiagnosticCategories().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json - */ -async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategories( - resourceGroupName, - siteName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDiagnosticCategories().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts deleted file mode 100644 index 3e9a1bc56859..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategories.json - */ -async function listAppDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppDiagnosticCategories().catch(console.error); - -/** - * This sample demonstrates how to Description for Get Diagnostics Categories - * - * @summary Description for Get Diagnostics Categories - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json - */ -async function listAppSlotDiagnosticCategories() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "Sample-WestUSResourceGroup"; - const siteName = "SampleApp"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( - resourceGroupName, - siteName, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAppSlotDiagnosticCategories().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteOwnershipIdentifierSample.ts deleted file mode 100644 index 0c14275c33b2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteOwnershipIdentifierSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete ownership identifier for domain - * - * @summary Description for Delete ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json - */ -async function deleteAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const name = "ownershipIdentifier"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.deleteOwnershipIdentifier( - resourceGroupName, - domainName, - name - ); - console.log(result); -} - -deleteAppServiceDomainOwnershipIdentifier().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteSample.ts deleted file mode 100644 index 13fc12599025..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsDeleteSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - DomainsDeleteOptionalParams, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a domain. - * - * @summary Description for Delete a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/DeleteAppServiceDomain.json - */ -async function deleteAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const forceHardDeleteDomain = true; - const options: DomainsDeleteOptionalParams = { forceHardDeleteDomain }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.delete( - resourceGroupName, - domainName, - options - ); - console.log(result); -} - -deleteAppServiceDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetOwnershipIdentifierSample.ts deleted file mode 100644 index 17146b87eea2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetOwnershipIdentifierSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get ownership identifier for domain - * - * @summary Description for Get ownership identifier for domain - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainOwnershipIdentifier.json - */ -async function getDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const name = "SampleOwnershipId"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.getOwnershipIdentifier( - resourceGroupName, - domainName, - name - ); - console.log(result); -} - -getDomainOwnershipIdentifier().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetSample.ts deleted file mode 100644 index 8406a388e6f4..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get a domain. - * - * @summary Description for Get a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomain.json - */ -async function getDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.get(resourceGroupName, domainName); - console.log(result); -} - -getDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListByResourceGroupSample.ts deleted file mode 100644 index 629ebd215760..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all domains in a resource group. - * - * @summary Description for Get all domains in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsByResourceGroup.json - */ -async function listDomainsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.domains.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listDomainsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListOwnershipIdentifiersSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListOwnershipIdentifiersSample.ts deleted file mode 100644 index 3616c1a7555d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListOwnershipIdentifiersSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Lists domain ownership identifiers. - * - * @summary Description for Lists domain ownership identifiers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainOwnershipIdentifiers.json - */ -async function listDomainOwnershipIdentifiers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.domains.listOwnershipIdentifiers( - resourceGroupName, - domainName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listDomainOwnershipIdentifiers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsRenewSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsRenewSample.ts deleted file mode 100644 index 6a3fcb8b4a0e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsRenewSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Renew a domain. - * - * @summary Description for Renew a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/RenewDomain.json - */ -async function renewAnExistingDomain() { - const subscriptionId = "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; - const resourceGroupName = "RG"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.renew(resourceGroupName, domainName); - console.log(result); -} - -renewAnExistingDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsTransferOutSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsTransferOutSample.ts deleted file mode 100644 index 9d9d197a84eb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsTransferOutSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Transfer out domain to another registrar - * - * @summary Transfer out domain to another registrar - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/TransferOutDomain.json - */ -async function transferOutDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const domainName = "example.com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.domains.transferOut( - resourceGroupName, - domainName - ); - console.log(result); -} - -transferOutDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 0269f48ca761..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - KubeEnvironment, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. - * - * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_CreateOrUpdate.json - */ -async function createKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testkubeenv"; - const kubeEnvironmentEnvelope: KubeEnvironment = { - location: "East US", - staticIp: "1.2.3.4" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - name, - kubeEnvironmentEnvelope - ); - console.log(result); -} - -createKubeEnvironments().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsDeleteSample.ts deleted file mode 100644 index efdbe8b7341d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Kubernetes Environment. - * - * @summary Description for Delete a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Delete.json - */ -async function deleteKubeEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteKubeEnvironmentByName().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsGetSample.ts deleted file mode 100644 index 8afd444aeae6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get the properties of a Kubernetes Environment. - * - * @summary Description for Get the properties of a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Get.json - */ -async function getKubeEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getKubeEnvironmentsByName().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index f59a46fe668b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get all the Kubernetes Environments in a resource group. - * - * @summary Description for Get all the Kubernetes Environments in a resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListByResourceGroup.json - */ -async function listKubeEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.kubeEnvironments.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listKubeEnvironmentsByResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsUpdateSample.ts deleted file mode 100644 index ef4c7118739a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - KubeEnvironmentPatchResource, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. - * - * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_Update.json - */ -async function updateKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testkubeenv"; - const kubeEnvironmentEnvelope: KubeEnvironmentPatchResource = { - staticIp: "1.2.3.4" - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.kubeEnvironments.update( - resourceGroupName, - name, - kubeEnvironmentEnvelope - ); - console.log(result); -} - -updateKubeEnvironments().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSample.ts deleted file mode 100644 index 3c71fd4d2917..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json - */ -async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.resourceHealthMetadataOperations.getBySite( - resourceGroupName, - name - ); - console.log(result); -} - -getResourceHealthMetadata().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts deleted file mode 100644 index d5671e5dcd25..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetResourceHealthMetadataBySite.json - */ -async function getResourceHealthMetadata() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.resourceHealthMetadataOperations.getBySiteSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -getResourceHealthMetadata().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts deleted file mode 100644 index 90d36520d544..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. - * - * @summary Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataByResourceGroup.json - */ -async function listResourceHealthMetadataForAResourceGroup() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.resourceHealthMetadataOperations.listByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listResourceHealthMetadataForAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSample.ts deleted file mode 100644 index 2775b9c8c321..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json - */ -async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.resourceHealthMetadataOperations.listBySite( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listResourceHealthMetadataForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts deleted file mode 100644 index be93e8a535f8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * - * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json - */ -async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; - const name = "newsiteinnewASE-NCUS"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.resourceHealthMetadataOperations.listBySiteSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listResourceHealthMetadataForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts deleted file mode 100644 index da399bb0337d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - StringDictionary, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates the app settings of a static site. - * - * @summary Description for Creates or updates the app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteAppSettings.json - */ -async function createsOrUpdatesTheAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const appSettings: StringDictionary = { - properties: { setting1: "someval", setting2: "someval2" } - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.createOrUpdateStaticSiteAppSettings( - resourceGroupName, - name, - appSettings - ); - console.log(result); -} - -createsOrUpdatesTheAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts deleted file mode 100644 index 2417dfe246cd..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - StringDictionary, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Creates or updates the function app settings of a static site. - * - * @summary Description for Creates or updates the function app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json - */ -async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const appSettings: StringDictionary = { - properties: { setting1: "someval", setting2: "someval2" } - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.createOrUpdateStaticSiteFunctionAppSettings( - resourceGroupName, - name, - appSettings - ); - console.log(result); -} - -createsOrUpdatesTheFunctionAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts deleted file mode 100644 index e9daff0b660f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json - */ -async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeletePrivateEndpointConnectionAndWait( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -deleteAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts deleted file mode 100644 index 657fda729848..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a static site build. - * - * @summary Description for Deletes a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteBuild.json - */ -async function deleteAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteBuildAndWait( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -deleteAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts deleted file mode 100644 index 17f6152db056..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a custom domain. - * - * @summary Description for Deletes a custom domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteCustomDomain.json - */ -async function deleteACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const domainName = "custom.domain.net"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteCustomDomainAndWait( - resourceGroupName, - name, - domainName - ); - console.log(result); -} - -deleteACustomDomainForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteSample.ts deleted file mode 100644 index 3dee3a98ad22..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a static site. - * - * @summary Description for Deletes a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSite.json - */ -async function deleteAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDeleteStaticSiteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteUserSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteUserSample.ts deleted file mode 100644 index e139e331ee79..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDeleteStaticSiteUserSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes the user entry from the static site. - * - * @summary Description for Deletes the user entry from the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteUser.json - */ -async function deleteAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const authprovider = "aad"; - const userid = "1234"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.deleteStaticSiteUser( - resourceGroupName, - name, - authprovider, - userid - ); - console.log(result); -} - -deleteAUserForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachStaticSiteSample.ts deleted file mode 100644 index 166cf03e7ecb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachStaticSiteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Detaches a static site. - * - * @summary Description for Detaches a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachStaticSite.json - */ -async function detachAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.beginDetachStaticSiteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -detachAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts deleted file mode 100644 index cb16449dc0de..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Detach the user provided function app from the static site build - * - * @summary Description for Detach the user provided function app from the static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json - */ -async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const functionAppName = "testFunctionApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSiteBuild( - resourceGroupName, - name, - environmentName, - functionAppName - ); - console.log(result); -} - -detachTheUserProvidedFunctionAppFromTheStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts deleted file mode 100644 index 694f599babdc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Detach the user provided function app from the static site - * - * @summary Description for Detach the user provided function app from the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json - */ -async function detachTheUserProvidedFunctionAppFromTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const functionAppName = "testFunctionApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSite( - resourceGroupName, - name, - functionAppName - ); - console.log(result); -} - -detachTheUserProvidedFunctionAppFromTheStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts deleted file mode 100644 index 488a88e58b8e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Returns the details of a linked backend linked to a static site build by name - * - * @summary Returns the details of a linked backend linked to a static site build by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSiteBuild.json - */ -async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getLinkedBackendForBuild( - resourceGroupName, - name, - environmentName, - linkedBackendName - ); - console.log(result); -} - -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendSample.ts deleted file mode 100644 index ab42e3072da1..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Returns the details of a linked backend linked to a static site by name - * - * @summary Returns the details of a linked backend linked to a static site by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSite.json - */ -async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getLinkedBackend( - resourceGroupName, - name, - linkedBackendName - ); - console.log(result); -} - -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts deleted file mode 100644 index 5b1b895b6f02..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Returns details of all backends linked to a static site build - * - * @summary Returns details of all backends linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSiteBuild.json - */ -async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listLinkedBackendsForBuild( - resourceGroupName, - name, - environmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsSample.ts deleted file mode 100644 index a40c43d97698..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetLinkedBackendsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Returns details of all backends linked to a static site - * - * @summary Returns details of all backends linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendsForStaticSite.json - */ -async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listLinkedBackends( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts deleted file mode 100644 index 41b3d33a7abc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the list of private endpoint connections associated with a static site - * - * @summary Description for Gets the list of private endpoint connections associated with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionList.json - */ -async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listPrivateEndpointConnectionList( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAListOfPrivateEndpointConnectionsAssociatedWithASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts deleted file mode 100644 index ec906e97f477..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getPrivateEndpointConnection( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts deleted file mode 100644 index 2b79f46f6bd3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getPrivateLinkResources( - resourceGroupName, - name - ); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildSample.ts deleted file mode 100644 index c305cd87ff06..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of a static site build. - * - * @summary Description for Gets the details of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuild.json - */ -async function getAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSiteBuild( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildsSample.ts deleted file mode 100644 index f4d880ab0993..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteBuildsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets all static site builds for a particular static site. - * - * @summary Description for Gets all static site builds for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteBuilds.json - */ -async function getAllBuildsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteBuilds( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAllBuildsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts deleted file mode 100644 index 64066c1f7659..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets an existing custom domain for a particular static site. - * - * @summary Description for Gets an existing custom domain for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomain.json - */ -async function getCustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const domainName = "custom.domain.net"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSiteCustomDomain( - resourceGroupName, - name, - domainName - ); - console.log(result); -} - -getCustomDomainForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteSample.ts deleted file mode 100644 index 8228305601bc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSiteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of a static site. - * - * @summary Description for Gets the details of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSite.json - */ -async function getDetailsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getStaticSite( - resourceGroupName, - name - ); - console.log(result); -} - -getDetailsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts deleted file mode 100644 index ac477b205386..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets all static sites in the specified resource group. - * - * @summary Description for Gets all static sites in the specified resource group. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSites.json - */ -async function getStaticSitesForAResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSitesByResourceGroup( - resourceGroupName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getStaticSitesForAResourceGroup().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts deleted file mode 100644 index 02b326f484f8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site build - * - * @summary Description for Gets the details of the user provided function app registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json - */ -async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const functionAppName = "testFunctionApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getUserProvidedFunctionAppForStaticSiteBuild( - resourceGroupName, - name, - environmentName, - functionAppName - ); - console.log(result); -} - -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts deleted file mode 100644 index 2028ad41ad7a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site - * - * @summary Description for Gets the details of the user provided function app registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSite.json - */ -async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const functionAppName = "testFunctionApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.getUserProvidedFunctionAppForStaticSite( - resourceGroupName, - name, - functionAppName - ); - console.log(result); -} - -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts deleted file mode 100644 index 39b9ca309323..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site build - * - * @summary Description for Gets the details of the user provided function apps registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json - */ -async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listUserProvidedFunctionAppsForStaticSiteBuild( - resourceGroupName, - name, - environmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts deleted file mode 100644 index a2a712afe072..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site - * - * @summary Description for Gets the details of the user provided function apps registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSite.json - */ -async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listUserProvidedFunctionAppsForStaticSite( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite().catch( - console.error -); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts deleted file mode 100644 index a8983dfe3374..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site. - * - * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteAppSettings.json - */ -async function getAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteAppSettings( - resourceGroupName, - name - ); - console.log(result); -} - -getAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts deleted file mode 100644 index 0300168ca497..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site build. - * - * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildAppSettings.json - */ -async function getAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteBuildAppSettings( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getAppSettingsOfAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts deleted file mode 100644 index 2f7ced124eae..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site build. - * - * @summary Description for Gets the application settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctionAppSettings.json - */ -async function getFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteBuildFunctionAppSettings( - resourceGroupName, - name, - environmentName - ); - console.log(result); -} - -getFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts deleted file mode 100644 index 9e5143937149..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the functions of a particular static site build. - * - * @summary Description for Gets the functions of a particular static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctions.json - */ -async function getsTheFunctionsOfAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "default"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteBuildFunctions( - resourceGroupName, - name, - environmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -getsTheFunctionsOfAParticularStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts deleted file mode 100644 index 09fe315e9845..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Lists the roles configured for the static site. - * - * @summary Description for Lists the roles configured for the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteConfiguredRoles.json - */ -async function listsTheConfiguredRolesForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteConfiguredRoles( - resourceGroupName, - name - ); - console.log(result); -} - -listsTheConfiguredRolesForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts deleted file mode 100644 index 1558a0861c2f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets all static site custom domains for a particular static site. - * - * @summary Description for Gets all static site custom domains for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomains.json - */ -async function listCustomDomainsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteCustomDomains( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listCustomDomainsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts deleted file mode 100644 index cc92d1ee132c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the application settings of a static site. - * - * @summary Description for Gets the application settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctionAppSettings.json - */ -async function getFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteFunctionAppSettings( - resourceGroupName, - name - ); - console.log(result); -} - -getFunctionAppSettingsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionsSample.ts deleted file mode 100644 index a898d27c297e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteFunctionsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the functions of a static site. - * - * @summary Description for Gets the functions of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteFunctions.json - */ -async function getsTheFunctionsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteFunctions( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getsTheFunctionsOfAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteSecretsSample.ts deleted file mode 100644 index 253337170950..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteSecretsSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Lists the secrets for an existing static site. - * - * @summary Description for Lists the secrets for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteSecrets.json - */ -async function listSecretsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.listStaticSiteSecrets( - resourceGroupName, - name - ); - console.log(result); -} - -listSecretsForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteUsersSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteUsersSample.ts deleted file mode 100644 index 31a9d1b40608..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListStaticSiteUsersSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the list of users of a static site. - * - * @summary Description for Gets the list of users of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteUsers.json - */ -async function listUsersForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const authprovider = "all"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.staticSites.listStaticSiteUsers( - resourceGroupName, - name, - authprovider - )) { - resArray.push(item); - } - console.log(resArray); -} - -listUsersForAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts deleted file mode 100644 index d40e53352709..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Unlink a backend from a static site build - * - * @summary Unlink a backend from a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSiteBuild.json - */ -async function unlinkABackendFromAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const environmentName = "12"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.unlinkBackendFromBuild( - resourceGroupName, - name, - environmentName, - linkedBackendName - ); - console.log(result); -} - -unlinkABackendFromAStaticSiteBuild().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendSample.ts deleted file mode 100644 index 033d6660e289..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUnlinkBackendSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Unlink a backend from a static site - * - * @summary Unlink a backend from a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UnlinkBackendFromStaticSite.json - */ -async function unlinkABackendFromAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testStaticSite0"; - const linkedBackendName = "testBackend"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.staticSites.unlinkBackend( - resourceGroupName, - name, - linkedBackendName - ); - console.log(result); -} - -unlinkABackendFromAStaticSite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsGetSample.ts deleted file mode 100644 index 3a0c8d33e7bb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsGetSample.ts +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Get details of a top-level domain. - * - * @summary Description for Get details of a top-level domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetTopLevelDomain.json - */ -async function getTopLevelDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const name = "com"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.topLevelDomains.get(name); - console.log(result); -} - -getTopLevelDomain().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts deleted file mode 100644 index 474484425f17..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnection.json - */ -async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginDeletePrivateEndpointConnectionAndWait( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -deleteAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts deleted file mode 100644 index 03c6818268e8..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Deletes a private endpoint connection - * - * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnectionSlot.json - */ -async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginDeletePrivateEndpointConnectionSlotAndWait( - resourceGroupName, - name, - privateEndpointConnectionName, - slot - ); - console.log(result); -} - -deleteAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts deleted file mode 100644 index 43c6377bfe2c..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the config reference and status of an app - * - * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSetting.json - */ -async function getAzureKeyVaultAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const appSettingKey = "setting"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getAppSettingKeyVaultReference( - resourceGroupName, - name, - appSettingKey - ); - console.log(result); -} - -getAzureKeyVaultAppSettingReference().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts deleted file mode 100644 index 77629132b010..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the config reference and status of an app - * - * @summary Description for Gets the config reference and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingSlot.json - */ -async function getAzureKeyVaultSlotAppSettingReference() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const appSettingKey = "setting"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getAppSettingKeyVaultReferenceSlot( - resourceGroupName, - name, - appSettingKey, - slot - ); - console.log(result); -} - -getAzureKeyVaultSlotAppSettingReference().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts deleted file mode 100644 index bf03ee907977..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the config reference app settings and status of an app - * - * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettings.json - */ -async function getAzureKeyVaultReferencesForAppSettings() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listAppSettingsKeyVaultReferences( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAzureKeyVaultReferencesForAppSettings().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts deleted file mode 100644 index 63b0ba791f59..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the config reference app settings and status of an app - * - * @summary Description for Gets the config reference app settings and status of an app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json - */ -async function getAzureKeyVaultReferencesForAppSettingsForSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "testc6282"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listAppSettingsKeyVaultReferencesSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -getAzureKeyVaultReferencesForAppSettingsForSlot().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSample.ts deleted file mode 100644 index 95c542071cac..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. - * - * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json - */ -async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getFtpAllowed(resourceGroupName, name); - console.log(result); -} - -getFtpAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSlotSample.ts deleted file mode 100644 index 3abf88b4a297..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetFtpAllowedSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. - * - * @summary Description for Returns whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json - */ -async function getFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getFtpAllowedSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -getFtpAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSample.ts deleted file mode 100644 index 0f13421a4012..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets all scale-out instances of an app. - * - * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json - */ -async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const instanceId = "134987120"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getInstanceInfo( - resourceGroupName, - name, - instanceId - ); - console.log(result); -} - -getSiteInstanceInfo().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSlotSample.ts deleted file mode 100644 index ab0318ead477..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetInstanceInfoSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets all scale-out instances of an app. - * - * @summary Description for Gets all scale-out instances of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteInstanceInfo.json - */ -async function getSiteInstanceInfo() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const instanceId = "134987120"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getInstanceInfoSlot( - resourceGroupName, - name, - instanceId, - slot - ); - console.log(result); -} - -getSiteInstanceInfo().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSample.ts deleted file mode 100644 index d5ef3618be27..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json - */ -async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTraceOperation( - resourceGroupName, - name, - operationId - ); - console.log(result); -} - -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts deleted file mode 100644 index 89227fd6954a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json - */ -async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTraceOperationSlot( - resourceGroupName, - name, - operationId, - slot - ); - console.log(result); -} - -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts deleted file mode 100644 index a8fe0471a22a..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json - */ -async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTraceOperationSlotV2( - resourceGroupName, - name, - operationId, - slot - ); - console.log(result); -} - -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts deleted file mode 100644 index 56f016e0de02..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json - */ -async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTraceOperationV2( - resourceGroupName, - name, - operationId - ); - console.log(result); -} - -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSample.ts deleted file mode 100644 index c0a161e6aa85..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json - */ -async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTraces( - resourceGroupName, - name, - operationId - ); - console.log(result); -} - -getNetworkTracesForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotSample.ts deleted file mode 100644 index 9b75b9938ebb..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json - */ -async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTracesSlot( - resourceGroupName, - name, - operationId, - slot - ); - console.log(result); -} - -getNetworkTracesForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts deleted file mode 100644 index 491f5f70498e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json - */ -async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTracesSlotV2( - resourceGroupName, - name, - operationId, - slot - ); - console.log(result); -} - -getNetworkTracesForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesV2Sample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesV2Sample.ts deleted file mode 100644 index bd1bbb1b3cca..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetNetworkTracesV2Sample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * - * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json - */ -async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getNetworkTracesV2( - resourceGroupName, - name, - operationId - ); - console.log(result); -} - -getNetworkTracesForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts deleted file mode 100644 index 2855a5010892..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnection.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateEndpointConnection( - resourceGroupName, - name, - privateEndpointConnectionName - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts deleted file mode 100644 index e99f60c701f3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets a private endpoint connection - * - * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionSlot.json - */ -async function getAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const privateEndpointConnectionName = "connection"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateEndpointConnectionSlot( - resourceGroupName, - name, - privateEndpointConnectionName, - slot - ); - console.log(result); -} - -getAPrivateEndpointConnectionForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSample.ts deleted file mode 100644 index d80f6792533b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResources.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateLinkResources( - resourceGroupName, - name - ); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts deleted file mode 100644 index cb198578c43f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets the private link resources - * - * @summary Description for Gets the private link resources - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateLinkResourcesSlot.json - */ -async function getPrivateLinkResourcesOfASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getPrivateLinkResourcesSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -getPrivateLinkResourcesOfASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts deleted file mode 100644 index 7624f03bd14d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). - * - * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatus.json - */ -async function getDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginGetProductionSiteDeploymentStatusAndWait( - resourceGroupName, - name, - deploymentStatusId - ); - console.log(result); -} - -getDeploymentStatus().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSample.ts deleted file mode 100644 index c8a2f66e93af..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. - * - * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicy.json - */ -async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getScmAllowed(resourceGroupName, name); - console.log(result); -} - -getScmAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSlotSample.ts deleted file mode 100644 index 6f4fe3b80eab..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetScmAllowedSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. - * - * @summary Description for Returns whether Scm basic auth is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetPublishingCredentialsPolicySlot.json - */ -async function getScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.getScmAllowedSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -getScmAllowed().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts deleted file mode 100644 index 325feb5a15ae..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). - * - * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatusSlot.json - */ -async function getDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginGetSlotSiteDeploymentStatusSlotAndWait( - resourceGroupName, - name, - slot, - deploymentStatusId - ); - console.log(result); -} - -getDeploymentStatusSlot().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts deleted file mode 100644 index b2f1122e2917..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * - * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPolicies.json - */ -async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; - const name = "testsite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listBasicPublishingCredentialsPolicies( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listPublishingCredentialsPolicies().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts deleted file mode 100644 index 64a52c3527e0..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * - * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPoliciesSlot.json - */ -async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; - const name = "testsite"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listBasicPublishingCredentialsPoliciesSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listPublishingCredentialsPolicies().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts deleted file mode 100644 index ea63e3d7f25d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). - * - * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatus.json - */ -async function listDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listProductionSiteDeploymentStatuses( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listDeploymentStatus().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSample.ts deleted file mode 100644 index 6af8660e78e9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets existing backups of an app. - * - * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json - */ -async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listSiteBackups( - resourceGroupName, - name - )) { - resArray.push(item); - } - console.log(resArray); -} - -listBackups().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSlotSample.ts deleted file mode 100644 index 2639464b5543..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSiteBackupsSlotSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Gets existing backups of an app. - * - * @summary Description for Gets existing backups of an app. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSlotBackups.json - */ -async function listBackups() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "tests346"; - const slot = "staging"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listSiteBackupsSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listBackups().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts deleted file mode 100644 index 3add9ed3eb6d..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). - * - * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatusSlot.json - */ -async function listDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testSite"; - const slot = "stage"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.webApps.listSlotSiteDeploymentStatusesSlot( - resourceGroupName, - name, - slot - )) { - resArray.push(item); - } - console.log(resArray); -} - -listDeploymentStatusSlot().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSample.ts deleted file mode 100644 index 9b288dd620b2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WebAppsStartNetworkTraceOptionalParams, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Start capturing network packets for the site. - * - * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json - */ -async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const durationInSeconds = 60; - const options: WebAppsStartNetworkTraceOptionalParams = { durationInSeconds }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginStartNetworkTraceAndWait( - resourceGroupName, - name, - options - ); - console.log(result); -} - -startANewNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSlotSample.ts deleted file mode 100644 index 13e206c3f865..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartNetworkTraceSlotSample.ts +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WebAppsStartNetworkTraceSlotOptionalParams, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Start capturing network packets for the site. - * - * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json - */ -async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const durationInSeconds = 60; - const slot = "Production"; - const options: WebAppsStartNetworkTraceSlotOptionalParams = { - durationInSeconds - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginStartNetworkTraceSlotAndWait( - resourceGroupName, - name, - slot, - options - ); - console.log(result); -} - -startANewNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts deleted file mode 100644 index 2e1621db3d8e..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - WebAppsStartWebSiteNetworkTraceOperationOptionalParams, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Start capturing network packets for the site. - * - * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json - */ -async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const durationInSeconds = 60; - const options: WebAppsStartWebSiteNetworkTraceOperationOptionalParams = { - durationInSeconds - }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.beginStartWebSiteNetworkTraceOperationAndWait( - resourceGroupName, - name, - options - ); - console.log(result); -} - -startANewNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSample.ts deleted file mode 100644 index 48db6f796c32..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopNetworkTrace(resourceGroupName, name); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSlotSample.ts deleted file mode 100644 index cc5d4dc945dd..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopNetworkTraceSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopNetworkTraceSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts deleted file mode 100644 index 035ba9dbfdfa..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopWebSiteNetworkTrace( - resourceGroupName, - name - ); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts deleted file mode 100644 index bec7040724c6..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. - * - * @summary Description for Stop ongoing capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StopWebSiteNetworkTrace.json - */ -async function stopACurrentlyRunningNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; - const name = "SampleApp"; - const slot = "Production"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.webApps.stopWebSiteNetworkTraceSlot( - resourceGroupName, - name, - slot - ); - console.log(result); -} - -stopACurrentlyRunningNetworkTraceOperationForASite().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsGetSample.ts deleted file mode 100644 index 77abc1104ccc..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsGetSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get a workflow run action repetition. - * - * @summary Get a workflow run action repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_Get.json - */ -async function getARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testFlow"; - const runName = "08586776228332053161046300351"; - const actionName = "testAction"; - const repetitionName = "000001"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRunActionRepetitions.get( - resourceGroupName, - name, - workflowName, - runName, - actionName, - repetitionName - ); - console.log(result); -} - -getARepetition().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListSample.ts deleted file mode 100644 index 407ee0e4fcac..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListSample.ts +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get all of a workflow run action repetitions. - * - * @summary Get all of a workflow run action repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_List.json - */ -async function listRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testFlow"; - const runName = "08586776228332053161046300351"; - const actionName = "testAction"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRunActionRepetitions.list( - resourceGroupName, - name, - workflowName, - runName, - actionName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listRepetitions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts deleted file mode 100644 index 1521d4cb4e90..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get a workflow run action scoped repetition. - * - * @summary Get a workflow run action scoped repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_Get.json - */ -async function getAScopedRepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testFlow"; - const runName = "08586776228332053161046300351"; - const actionName = "for_each"; - const repetitionName = "000000"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRunActionScopeRepetitions.get( - resourceGroupName, - name, - workflowName, - runName, - actionName, - repetitionName - ); - console.log(result); -} - -getAScopedRepetition().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsListSample.ts deleted file mode 100644 index e1138cf92e28..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionScopeRepetitionsListSample.ts +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List the workflow run action scoped repetitions. - * - * @summary List the workflow run action scoped repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_List.json - */ -async function listTheScopedRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testFlow"; - const runName = "08586776228332053161046300351"; - const actionName = "for_each"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRunActionScopeRepetitions.list( - resourceGroupName, - name, - workflowName, - runName, - actionName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listTheScopedRepetitions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsGetSample.ts deleted file mode 100644 index c66f00252bb9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsGetSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a workflow run action. - * - * @summary Gets a workflow run action. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_Get.json - */ -async function getAWorkflowRunAction() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const actionName = "HTTP"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRunActions.get( - resourceGroupName, - name, - workflowName, - runName, - actionName - ); - console.log(result); -} - -getAWorkflowRunAction().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListExpressionTracesSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListExpressionTracesSample.ts deleted file mode 100644 index 3dccaf195666..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListExpressionTracesSample.ts +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Lists a workflow run expression trace. - * - * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_ListExpressionTraces.json - */ -async function listExpressionTraces() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testFlow"; - const runName = "08586776228332053161046300351"; - const actionName = "testAction"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRunActions.listExpressionTraces( - resourceGroupName, - name, - workflowName, - runName, - actionName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listExpressionTraces().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListSample.ts deleted file mode 100644 index 3127dd17e1a2..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionsListSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a list of workflow run actions. - * - * @summary Gets a list of workflow run actions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_List.json - */ -async function listAWorkflowRunActions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRunActions.list( - resourceGroupName, - name, - workflowName, - runName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAWorkflowRunActions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsCancelSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsCancelSample.ts deleted file mode 100644 index eb7119705df9..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsCancelSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Cancels a workflow run. - * - * @summary Cancels a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Cancel.json - */ -async function cancelAWorkflowRun() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRuns.cancel( - resourceGroupName, - name, - workflowName, - runName - ); - console.log(result); -} - -cancelAWorkflowRun().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsGetSample.ts deleted file mode 100644 index d9f0d49efa67..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsGetSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a workflow run. - * - * @summary Gets a workflow run. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_Get.json - */ -async function getARunForAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const runName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowRuns.get( - resourceGroupName, - name, - workflowName, - runName - ); - console.log(result); -} - -getARunForAWorkflow().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsListSample.ts deleted file mode 100644 index 458deb11a011..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunsListSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a list of workflow runs. - * - * @summary Gets a list of workflow runs. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRuns_List.json - */ -async function listWorkflowRuns() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowRuns.list( - resourceGroupName, - name, - workflowName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listWorkflowRuns().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesGetSample.ts deleted file mode 100644 index cf210b413129..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesGetSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a workflow trigger history. - * - * @summary Gets a workflow trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Get.json - */ -async function getAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const triggerName = "testTriggerName"; - const historyName = "08586676746934337772206998657CU22"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggerHistories.get( - resourceGroupName, - name, - workflowName, - triggerName, - historyName - ); - console.log(result); -} - -getAWorkflowTriggerHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesListSample.ts deleted file mode 100644 index 14a50f6d3bfa..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesListSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a list of workflow trigger histories. - * - * @summary Gets a list of workflow trigger histories. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_List.json - */ -async function listAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const triggerName = "testTriggerName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowTriggerHistories.list( - resourceGroupName, - name, - workflowName, - triggerName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAWorkflowTriggerHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesResubmitSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesResubmitSample.ts deleted file mode 100644 index 430ebfd2048f..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggerHistoriesResubmitSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Resubmits a workflow run based on the trigger history. - * - * @summary Resubmits a workflow run based on the trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Resubmit.json - */ -async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const triggerName = "testTriggerName"; - const historyName = "testHistoryName"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggerHistories.beginResubmitAndWait( - resourceGroupName, - name, - workflowName, - triggerName, - historyName - ); - console.log(result); -} - -resubmitAWorkflowRunBasedOnTheTriggerHistory().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSample.ts deleted file mode 100644 index 3600946f36e3..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a workflow trigger. - * - * @summary Gets a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Get.json - */ -async function getAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.get( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getAWorkflowTrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSchemaJsonSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSchemaJsonSample.ts deleted file mode 100644 index c3a8704a6dbd..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersGetSchemaJsonSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the trigger schema as JSON. - * - * @summary Get the trigger schema as JSON. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_GetSchemaJson.json - */ -async function getTriggerSchema() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflow"; - const triggerName = "testTrigger"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.getSchemaJson( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getTriggerSchema().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListCallbackUrlSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListCallbackUrlSample.ts deleted file mode 100644 index 4f3a018dd8a1..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListCallbackUrlSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the callback URL for a workflow trigger. - * - * @summary Get the callback URL for a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_ListCallbackUrl.json - */ -async function getTheCallbackUrlForATrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.listCallbackUrl( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -getTheCallbackUrlForATrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListSample.ts deleted file mode 100644 index f3b47ae11474..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersListSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a list of workflow triggers. - * - * @summary Gets a list of workflow triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_List.json - */ -async function listWorkflowTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowTriggers.list( - resourceGroupName, - name, - workflowName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listWorkflowTriggers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersRunSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersRunSample.ts deleted file mode 100644 index d67faf74b122..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowTriggersRunSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Runs a workflow trigger. - * - * @summary Runs a workflow trigger. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggers_Run.json - */ -async function runAWorkflowTrigger() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const triggerName = "manual"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowTriggers.beginRunAndWait( - resourceGroupName, - name, - workflowName, - triggerName - ); - console.log(result); -} - -runAWorkflowTrigger().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsGetSample.ts deleted file mode 100644 index 15e226ec220b..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsGetSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a workflow version. - * - * @summary Gets a workflow version. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_Get.json - */ -async function getAWorkflowVersion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const versionId = "08586676824806722526"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflowVersions.get( - resourceGroupName, - name, - workflowName, - versionId - ); - console.log(result); -} - -getAWorkflowVersion().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsListSample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsListSample.ts deleted file mode 100644 index 1d6cd9cfc598..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowVersionsListSample.ts +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Gets a list of workflow versions. - * - * @summary Gets a list of workflow versions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowVersions_List.json - */ -async function listAWorkflowsVersions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; - const name = "test-name"; - const workflowName = "test-workflow"; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.workflowVersions.list( - resourceGroupName, - name, - workflowName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listAWorkflowsVersions().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsRegenerateAccessKeySample.ts b/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsRegenerateAccessKeySample.ts deleted file mode 100644 index 5b5157365a33..000000000000 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsRegenerateAccessKeySample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - RegenerateActionParameter, - WebSiteManagementClient -} from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Regenerates the callback URL access key for request triggers. - * - * @summary Regenerates the callback URL access key for request triggers. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_RegenerateAccessKey.json - */ -async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; - const name = "test-name"; - const workflowName = "testWorkflowName"; - const keyType: RegenerateActionParameter = { keyType: "Primary" }; - const credential = new DefaultAzureCredential(); - const client = new WebSiteManagementClient(credential, subscriptionId); - const result = await client.workflows.regenerateAccessKey( - resourceGroupName, - name, - workflowName, - keyType - ); - console.log(result); -} - -regenerateTheCallbackUrlAccessKeyForRequestTriggers().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/README.md b/sdk/appservice/arm-appservice/samples/v14/javascript/README.md new file mode 100644 index 000000000000..cd5e05c3b8ec --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/README.md @@ -0,0 +1,738 @@ +# client library samples for JavaScript + +These sample programs show how to use the JavaScript client libraries for in some common scenarios. + +| **File Name** | **Description** | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| [appServiceCertificateOrdersCreateOrUpdateCertificateSample.js][appservicecertificateorderscreateorupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificate.json | +| [appServiceCertificateOrdersCreateOrUpdateSample.js][appservicecertificateorderscreateorupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersDeleteCertificateSample.js][appservicecertificateordersdeletecertificatesample] | Description for Delete the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificate.json | +| [appServiceCertificateOrdersDeleteSample.js][appservicecertificateordersdeletesample] | Description for Delete an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersGetCertificateSample.js][appservicecertificateordersgetcertificatesample] | Description for Get the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificate.json | +| [appServiceCertificateOrdersGetSample.js][appservicecertificateordersgetsample] | Description for Get a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersListByResourceGroupSample.js][appservicecertificateorderslistbyresourcegroupsample] | Description for Get certificate orders in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json | +| [appServiceCertificateOrdersListCertificatesSample.js][appservicecertificateorderslistcertificatessample] | Description for List all certificates associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListCertificatesByAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersListSample.js][appservicecertificateorderslistsample] | Description for List all certificate orders in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersBySubscription.json | +| [appServiceCertificateOrdersReissueSample.js][appservicecertificateordersreissuesample] | Description for Reissue an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ReissueAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersRenewSample.js][appservicecertificateordersrenewsample] | Description for Renew an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RenewAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersResendEmailSample.js][appservicecertificateordersresendemailsample] | Description for Resend certificate email. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendAppServiceCertificateOrderEmail.json | +| [appServiceCertificateOrdersResendRequestEmailsSample.js][appservicecertificateordersresendrequestemailssample] | Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendDomainOwnershipVerificationEmail.json | +| [appServiceCertificateOrdersRetrieveCertificateActionsSample.js][appservicecertificateordersretrievecertificateactionssample] | Description for Retrieve the list of certificate actions. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateOrderActions.json | +| [appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js][appservicecertificateordersretrievecertificateemailhistorysample] | Description for Retrieve email history. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateEmailHistory.json | +| [appServiceCertificateOrdersRetrieveSiteSealSample.js][appservicecertificateordersretrievesitesealsample] | This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveSiteSeal.json | +| [appServiceCertificateOrdersUpdateCertificateSample.js][appservicecertificateordersupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificate.json | +| [appServiceCertificateOrdersUpdateSample.js][appservicecertificateordersupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersValidatePurchaseInformationSample.js][appservicecertificateordersvalidatepurchaseinformationsample] | Description for Validate information for a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json | +| [appServiceCertificateOrdersVerifyDomainOwnershipSample.js][appservicecertificateordersverifydomainownershipsample] | Description for Verify domain ownership for this certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/VerifyDomainOwnership.json | +| [appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js][appserviceenvironmentsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json | +| [appServiceEnvironmentsChangeVnetSample.js][appserviceenvironmentschangevnetsample] | Description for Move an App Service Environment to a different VNET. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ChangeVnet.json | +| [appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js][appserviceenvironmentscreateorupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | +| [appServiceEnvironmentsCreateOrUpdateSample.js][appserviceenvironmentscreateorupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdate.json | +| [appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js][appserviceenvironmentscreateorupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | +| [appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample] | Delete Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js][appserviceenvironmentsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json | +| [appServiceEnvironmentsDeleteSample.js][appserviceenvironmentsdeletesample] | Description for Delete an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Delete.json | +| [appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsgetasecustomdnssuffixconfigurationsample] | Get Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js][appserviceenvironmentsgetasev3networkingconfigurationsample] | Description for Get networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json | +| [appServiceEnvironmentsGetDiagnosticsItemSample.js][appserviceenvironmentsgetdiagnosticsitemsample] | Description for Get a diagnostics item for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json | +| [appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js][appserviceenvironmentsgetinboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all inbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetInboundNetworkDependenciesEndpoints.json | +| [appServiceEnvironmentsGetMultiRolePoolSample.js][appserviceenvironmentsgetmultirolepoolsample] | Description for Get properties of a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetMultiRolePool.json | +| [appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js][appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all outbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetOutboundNetworkDependenciesEndpoints.json | +| [appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js][appserviceenvironmentsgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoints associated with a hosting environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json | +| [appServiceEnvironmentsGetPrivateEndpointConnectionSample.js][appserviceenvironmentsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json | +| [appServiceEnvironmentsGetPrivateLinkResourcesSample.js][appserviceenvironmentsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json | +| [appServiceEnvironmentsGetSample.js][appserviceenvironmentsgetsample] | Description for Get the properties of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Get.json | +| [appServiceEnvironmentsGetVipInfoSample.js][appserviceenvironmentsgetvipinfosample] | Description for Get IP addresses assigned to an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetVipInfo.json | +| [appServiceEnvironmentsGetWorkerPoolSample.js][appserviceenvironmentsgetworkerpoolsample] | Description for Get properties of a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetWorkerPool.json | +| [appServiceEnvironmentsListAppServicePlansSample.js][appserviceenvironmentslistappserviceplanssample] | Description for Get all App Service plans in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListAppServicePlans.json | +| [appServiceEnvironmentsListByResourceGroupSample.js][appserviceenvironmentslistbyresourcegroupsample] | Description for Get all App Service Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListByResourceGroup.json | +| [appServiceEnvironmentsListCapacitiesSample.js][appserviceenvironmentslistcapacitiessample] | Description for Get the used, available, and total worker capacity an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListCapacities.json | +| [appServiceEnvironmentsListDiagnosticsSample.js][appserviceenvironmentslistdiagnosticssample] | Description for Get diagnostic information for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListDiagnostics.json | +| [appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js][appserviceenvironmentslistmultirolemetricdefinitionssample] | Description for Get metric definitions for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json | +| [appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js][appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json | +| [appServiceEnvironmentsListMultiRolePoolSkusSample.js][appserviceenvironmentslistmultirolepoolskussample] | Description for Get available SKUs for scaling a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json | +| [appServiceEnvironmentsListMultiRolePoolsSample.js][appserviceenvironmentslistmultirolepoolssample] | Description for Get all multi-role pools. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePools.json | +| [appServiceEnvironmentsListMultiRoleUsagesSample.js][appserviceenvironmentslistmultiroleusagessample] | Description for Get usage metrics for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json | +| [appServiceEnvironmentsListOperationsSample.js][appserviceenvironmentslistoperationssample] | Description for List all currently running operations on the App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListOperations.json | +| [appServiceEnvironmentsListSample.js][appserviceenvironmentslistsample] | Description for Get all App Service Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_List.json | +| [appServiceEnvironmentsListUsagesSample.js][appserviceenvironmentslistusagessample] | Description for Get global usage metrics of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListUsages.json | +| [appServiceEnvironmentsListWebAppsSample.js][appserviceenvironmentslistwebappssample] | Description for Get all apps in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebApps.json | +| [appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js][appserviceenvironmentslistwebworkermetricdefinitionssample] | Description for Get metric definitions for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json | +| [appServiceEnvironmentsListWebWorkerUsagesSample.js][appserviceenvironmentslistwebworkerusagessample] | Description for Get usage metrics for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json | +| [appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js][appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json | +| [appServiceEnvironmentsListWorkerPoolSkusSample.js][appserviceenvironmentslistworkerpoolskussample] | Description for Get available SKUs for scaling a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json | +| [appServiceEnvironmentsListWorkerPoolsSample.js][appserviceenvironmentslistworkerpoolssample] | Description for Get all worker pools of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPools.json | +| [appServiceEnvironmentsRebootSample.js][appserviceenvironmentsrebootsample] | Description for Reboot all machines in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Reboot.json | +| [appServiceEnvironmentsResumeSample.js][appserviceenvironmentsresumesample] | Description for Resume an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Resume.json | +| [appServiceEnvironmentsSuspendSample.js][appserviceenvironmentssuspendsample] | Description for Suspend an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Suspend.json | +| [appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js][appserviceenvironmentstestupgradeavailablenotificationsample] | Send a test notification that an upgrade is available for this App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json | +| [appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js][appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample] | Update Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js][appserviceenvironmentsupdateasenetworkingconfigurationsample] | Description for Update networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json | +| [appServiceEnvironmentsUpdateMultiRolePoolSample.js][appserviceenvironmentsupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | +| [appServiceEnvironmentsUpdateSample.js][appserviceenvironmentsupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Update.json | +| [appServiceEnvironmentsUpdateWorkerPoolSample.js][appserviceenvironmentsupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | +| [appServiceEnvironmentsUpgradeSample.js][appserviceenvironmentsupgradesample] | Description for Initiate an upgrade of an App Service Environment if one is available. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Upgrade.json | +| [appServicePlansCreateOrUpdateSample.js][appserviceplanscreateorupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateAppServicePlan.json | +| [appServicePlansDeleteSample.js][appserviceplansdeletesample] | Description for Delete an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAppServicePlan.json | +| [appServicePlansGetSample.js][appserviceplansgetsample] | Description for Get an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAppServicePlan.json | +| [appServicePlansListByResourceGroupSample.js][appserviceplanslistbyresourcegroupsample] | Description for Get all App Service plans in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlansByResourceGroup.json | +| [appServicePlansListSample.js][appserviceplanslistsample] | Description for Get all App Service plans for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlans.json | +| [appServicePlansUpdateSample.js][appserviceplansupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchAppServicePlan.json | +| [certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js][certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json | +| [certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js][certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json | +| [certificateRegistrationProviderListOperationsSample.js][certificateregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListOperations.json | +| [certificatesCreateOrUpdateSample.js][certificatescreateorupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateCertificate.json | +| [certificatesDeleteSample.js][certificatesdeletesample] | Description for Delete a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteCertificate.json | +| [certificatesGetSample.js][certificatesgetsample] | Description for Get a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetCertificate.json | +| [certificatesListByResourceGroupSample.js][certificateslistbyresourcegroupsample] | Description for Get all certificates in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificatesByResourceGroup.json | +| [certificatesListSample.js][certificateslistsample] | Description for Get all certificates for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificates.json | +| [certificatesUpdateSample.js][certificatesupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchCertificate.json | +| [containerAppsCreateOrUpdateSample.js][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateContainerApp.json | +| [containerAppsDeleteSample.js][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteContainerApp.json | +| [containerAppsGetSample.js][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetContainerApp.json | +| [containerAppsListByResourceGroupSample.js][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsByResourceGroup.json | +| [containerAppsListBySubscriptionSample.js][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsBySubscription.json | +| [containerAppsListSecretsSample.js][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppSecrets.json | +| [containerAppsRevisionsActivateRevisionSample.js][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ActivateRevision.json | +| [containerAppsRevisionsDeactivateRevisionSample.js][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeactivateRevision.json | +| [containerAppsRevisionsGetRevisionSample.js][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetRevision.json | +| [containerAppsRevisionsListRevisionsSample.js][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListRevisions.json | +| [containerAppsRevisionsRestartRevisionSample.js][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestartRevision.json | +| [deletedWebAppsGetDeletedWebAppByLocationSample.js][deletedwebappsgetdeletedwebappbylocationsample] | Description for Get deleted app for a subscription at location. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppByLocation.json | +| [deletedWebAppsListByLocationSample.js][deletedwebappslistbylocationsample] | Description for Get all deleted apps for a subscription at location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListDeletedWebAppsByLocation.json | +| [diagnosticsExecuteSiteAnalysisSample.js][diagnosticsexecutesiteanalysissample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json | +| [diagnosticsExecuteSiteAnalysisSlotSample.js][diagnosticsexecutesiteanalysisslotsample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json | +| [diagnosticsExecuteSiteDetectorSample.js][diagnosticsexecutesitedetectorsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json | +| [diagnosticsExecuteSiteDetectorSlotSample.js][diagnosticsexecutesitedetectorslotsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json | +| [diagnosticsGetHostingEnvironmentDetectorResponseSample.js][diagnosticsgethostingenvironmentdetectorresponsesample] | Description for Get Hosting Environment Detector Response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json | +| [diagnosticsGetSiteAnalysisSample.js][diagnosticsgetsiteanalysissample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json | +| [diagnosticsGetSiteAnalysisSlotSample.js][diagnosticsgetsiteanalysisslotsample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json | +| [diagnosticsGetSiteDetectorResponseSample.js][diagnosticsgetsitedetectorresponsesample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json | +| [diagnosticsGetSiteDetectorResponseSlotSample.js][diagnosticsgetsitedetectorresponseslotsample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json | +| [diagnosticsGetSiteDetectorSample.js][diagnosticsgetsitedetectorsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json | +| [diagnosticsGetSiteDetectorSlotSample.js][diagnosticsgetsitedetectorslotsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json | +| [diagnosticsGetSiteDiagnosticCategorySample.js][diagnosticsgetsitediagnosticcategorysample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | +| [diagnosticsGetSiteDiagnosticCategorySlotSample.js][diagnosticsgetsitediagnosticcategoryslotsample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | +| [diagnosticsListHostingEnvironmentDetectorResponsesSample.js][diagnosticslisthostingenvironmentdetectorresponsessample] | Description for List Hosting Environment Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json | +| [diagnosticsListSiteAnalysesSample.js][diagnosticslistsiteanalysessample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json | +| [diagnosticsListSiteAnalysesSlotSample.js][diagnosticslistsiteanalysesslotsample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json | +| [diagnosticsListSiteDetectorResponsesSample.js][diagnosticslistsitedetectorresponsessample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json | +| [diagnosticsListSiteDetectorResponsesSlotSample.js][diagnosticslistsitedetectorresponsesslotsample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json | +| [diagnosticsListSiteDetectorsSample.js][diagnosticslistsitedetectorssample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json | +| [diagnosticsListSiteDetectorsSlotSample.js][diagnosticslistsitedetectorsslotsample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json | +| [diagnosticsListSiteDiagnosticCategoriesSample.js][diagnosticslistsitediagnosticcategoriessample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | +| [diagnosticsListSiteDiagnosticCategoriesSlotSample.js][diagnosticslistsitediagnosticcategoriesslotsample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | +| [domainRegistrationProviderListOperationsSample.js][domainregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListOperations.json | +| [domainsCheckAvailabilitySample.js][domainscheckavailabilitysample] | Description for Check if a domain is available for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CheckDomainAvailability.json | +| [domainsCreateOrUpdateOwnershipIdentifierSample.js][domainscreateorupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomainOwnershipIdentifier.json | +| [domainsCreateOrUpdateSample.js][domainscreateorupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomain.json | +| [domainsDeleteOwnershipIdentifierSample.js][domainsdeleteownershipidentifiersample] | Description for Delete ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json | +| [domainsDeleteSample.js][domainsdeletesample] | Description for Delete a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomain.json | +| [domainsGetControlCenterSsoRequestSample.js][domainsgetcontrolcenterssorequestsample] | Description for Generate a single sign-on request for the domain management portal. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainControlCenterSsoRequest.json | +| [domainsGetOwnershipIdentifierSample.js][domainsgetownershipidentifiersample] | Description for Get ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainOwnershipIdentifier.json | +| [domainsGetSample.js][domainsgetsample] | Description for Get a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomain.json | +| [domainsListByResourceGroupSample.js][domainslistbyresourcegroupsample] | Description for Get all domains in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsByResourceGroup.json | +| [domainsListOwnershipIdentifiersSample.js][domainslistownershipidentifierssample] | Description for Lists domain ownership identifiers. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainOwnershipIdentifiers.json | +| [domainsListRecommendationsSample.js][domainslistrecommendationssample] | Description for Get domain name recommendations based on keywords. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainRecommendations.json | +| [domainsListSample.js][domainslistsample] | Description for Get all domains in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsBySubscription.json | +| [domainsRenewSample.js][domainsrenewsample] | Description for Renew a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/RenewDomain.json | +| [domainsTransferOutSample.js][domainstransferoutsample] | Transfer out domain to another registrar x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/TransferOutDomain.json | +| [domainsUpdateOwnershipIdentifierSample.js][domainsupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json | +| [domainsUpdateSample.js][domainsupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomain.json | +| [globalGetDeletedWebAppSample.js][globalgetdeletedwebappsample] | Description for Get deleted app for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebApp.json | +| [globalGetDeletedWebAppSnapshotsSample.js][globalgetdeletedwebappsnapshotssample] | Description for Get all deleted apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppSnapshots.json | +| [globalGetSubscriptionOperationWithAsyncResponseSample.js][globalgetsubscriptionoperationwithasyncresponsesample] | Description for Gets an operation in a subscription and given region x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSubscriptionOperationWithAsyncResponse.json | +| [kubeEnvironmentsCreateOrUpdateSample.js][kubeenvironmentscreateorupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_CreateOrUpdate.json | +| [kubeEnvironmentsDeleteSample.js][kubeenvironmentsdeletesample] | Description for Delete a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Delete.json | +| [kubeEnvironmentsGetSample.js][kubeenvironmentsgetsample] | Description for Get the properties of a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Get.json | +| [kubeEnvironmentsListByResourceGroupSample.js][kubeenvironmentslistbyresourcegroupsample] | Description for Get all the Kubernetes Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListByResourceGroup.json | +| [kubeEnvironmentsListBySubscriptionSample.js][kubeenvironmentslistbysubscriptionsample] | Description for Get all Kubernetes Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListBySubscription.json | +| [kubeEnvironmentsUpdateSample.js][kubeenvironmentsupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Update.json | +| [listCustomHostNameSitesSample.js][listcustomhostnamesitessample] | Get custom hostnames under this subscription x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomHostNameSites.json | +| [providerGetFunctionAppStacksForLocationSample.js][providergetfunctionappstacksforlocationsample] | Description for Get available Function app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacksForLocation.json | +| [providerGetFunctionAppStacksSample.js][providergetfunctionappstackssample] | Description for Get available Function app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacks.json | +| [providerGetWebAppStacksForLocationSample.js][providergetwebappstacksforlocationsample] | Description for Get available Web app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacksForLocation.json | +| [providerGetWebAppStacksSample.js][providergetwebappstackssample] | Description for Get available Web app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacks.json | +| [providerListOperationsSample.js][providerlistoperationssample] | Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListOperations.json | +| [resourceHealthMetadataGetBySiteSample.js][resourcehealthmetadatagetbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json | +| [resourceHealthMetadataGetBySiteSlotSample.js][resourcehealthmetadatagetbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListByResourceGroupSample.js][resourcehealthmetadatalistbyresourcegroupsample] | Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataByResourceGroup.json | +| [resourceHealthMetadataListBySiteSample.js][resourcehealthmetadatalistbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListBySiteSlotSample.js][resourcehealthmetadatalistbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListSample.js][resourcehealthmetadatalistsample] | Description for List all ResourceHealthMetadata for all sites in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySubscription.json | +| [staticSitesApproveOrRejectPrivateEndpointConnectionSample.js][staticsitesapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json | +| [staticSitesCreateOrUpdateBasicAuthSample.js][staticsitescreateorupdatebasicauthsample] | Description for Adds or updates basic auth for a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBasicAuth.json | +| [staticSitesCreateOrUpdateBuildDatabaseConnectionSample.js][staticsitescreateorupdatebuilddatabaseconnectionsample] | Description for Create or update a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildDatabaseConnection.json | +| [staticSitesCreateOrUpdateDatabaseConnectionSample.js][staticsitescreateorupdatedatabaseconnectionsample] | Description for Create or update a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteDatabaseConnection.json | +| [staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js][staticsitescreateorupdatestaticsiteappsettingssample] | Description for Creates or updates the app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js][staticsitescreateorupdatestaticsitebuildappsettingssample] | Description for Creates or updates the app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js][staticsitescreateorupdatestaticsitebuildfunctionappsettingssample] | Description for Creates or updates the function app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js][staticsitescreateorupdatestaticsitecustomdomainsample] | Description for Creates a new static site custom domain in an existing resource group and static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteCustomDomain.json | +| [staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js][staticsitescreateorupdatestaticsitefunctionappsettingssample] | Description for Creates or updates the function app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteSample.js][staticsitescreateorupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSite.json | +| [staticSitesCreateUserRolesInvitationLinkSample.js][staticsitescreateuserrolesinvitationlinksample] | Description for Creates an invitation link for a user with the role x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateUserRolesInvitationLink.json | +| [staticSitesCreateZipDeploymentForStaticSiteBuildSample.js][staticsitescreatezipdeploymentforstaticsitebuildsample] | Description for Deploys zipped content to a specific environment of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteBuildZipDeploy.json | +| [staticSitesCreateZipDeploymentForStaticSiteSample.js][staticsitescreatezipdeploymentforstaticsitesample] | Description for Deploys zipped content to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteZipDeploy.json | +| [staticSitesDeleteBuildDatabaseConnectionSample.js][staticsitesdeletebuilddatabaseconnectionsample] | Delete a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuildDatabaseConnection.json | +| [staticSitesDeleteDatabaseConnectionSample.js][staticsitesdeletedatabaseconnectionsample] | Delete a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteDatabaseConnection.json | +| [staticSitesDeletePrivateEndpointConnectionSample.js][staticsitesdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json | +| [staticSitesDeleteStaticSiteBuildSample.js][staticsitesdeletestaticsitebuildsample] | Description for Deletes a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuild.json | +| [staticSitesDeleteStaticSiteCustomDomainSample.js][staticsitesdeletestaticsitecustomdomainsample] | Description for Deletes a custom domain. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteCustomDomain.json | +| [staticSitesDeleteStaticSiteSample.js][staticsitesdeletestaticsitesample] | Description for Deletes a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSite.json | +| [staticSitesDeleteStaticSiteUserSample.js][staticsitesdeletestaticsiteusersample] | Description for Deletes the user entry from the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteUser.json | +| [staticSitesDetachStaticSiteSample.js][staticsitesdetachstaticsitesample] | Description for Detaches a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachStaticSite.json | +| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js][staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample] | Description for Detach the user provided function app from the static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json | +| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js][staticsitesdetachuserprovidedfunctionappfromstaticsitesample] | Description for Detach the user provided function app from the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json | +| [staticSitesGetBasicAuthSample.js][staticsitesgetbasicauthsample] | Description for Gets the basic auth properties for a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBasicAuth.json | +| [staticSitesGetBuildDatabaseConnectionSample.js][staticsitesgetbuilddatabaseconnectionsample] | Returns overview of a database connection for a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnection.json | +| [staticSitesGetBuildDatabaseConnectionWithDetailsSample.js][staticsitesgetbuilddatabaseconnectionwithdetailssample] | Returns details of a database connection for a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionWithDetails.json | +| [staticSitesGetBuildDatabaseConnectionsSample.js][staticsitesgetbuilddatabaseconnectionssample] | Returns overviews of database connections for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnections.json | +| [staticSitesGetBuildDatabaseConnectionsWithDetailsSample.js][staticsitesgetbuilddatabaseconnectionswithdetailssample] | Returns details of database connections for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionsWithDetails.json | +| [staticSitesGetDatabaseConnectionSample.js][staticsitesgetdatabaseconnectionsample] | Returns overview of a database connection for a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnection.json | +| [staticSitesGetDatabaseConnectionWithDetailsSample.js][staticsitesgetdatabaseconnectionwithdetailssample] | Returns details of a database connection for a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionWithDetails.json | +| [staticSitesGetDatabaseConnectionsSample.js][staticsitesgetdatabaseconnectionssample] | Returns overviews of database connections for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnections.json | +| [staticSitesGetDatabaseConnectionsWithDetailsSample.js][staticsitesgetdatabaseconnectionswithdetailssample] | Returns details of database connections for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionsWithDetails.json | +| [staticSitesGetLinkedBackendForBuildSample.js][staticsitesgetlinkedbackendforbuildsample] | Returns the details of a linked backend linked to a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSiteBuild.json | +| [staticSitesGetLinkedBackendSample.js][staticsitesgetlinkedbackendsample] | Returns the details of a linked backend linked to a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSite.json | +| [staticSitesGetLinkedBackendsForBuildSample.js][staticsitesgetlinkedbackendsforbuildsample] | Returns details of all backends linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSiteBuild.json | +| [staticSitesGetLinkedBackendsSample.js][staticsitesgetlinkedbackendssample] | Returns details of all backends linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSite.json | +| [staticSitesGetPrivateEndpointConnectionListSample.js][staticsitesgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoint connections associated with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionList.json | +| [staticSitesGetPrivateEndpointConnectionSample.js][staticsitesgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json | +| [staticSitesGetPrivateLinkResourcesSample.js][staticsitesgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json | +| [staticSitesGetStaticSiteBuildSample.js][staticsitesgetstaticsitebuildsample] | Description for Gets the details of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuild.json | +| [staticSitesGetStaticSiteBuildsSample.js][staticsitesgetstaticsitebuildssample] | Description for Gets all static site builds for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuilds.json | +| [staticSitesGetStaticSiteCustomDomainSample.js][staticsitesgetstaticsitecustomdomainsample] | Description for Gets an existing custom domain for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomain.json | +| [staticSitesGetStaticSiteSample.js][staticsitesgetstaticsitesample] | Description for Gets the details of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSite.json | +| [staticSitesGetStaticSitesByResourceGroupSample.js][staticsitesgetstaticsitesbyresourcegroupsample] | Description for Gets all static sites in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSites.json | +| [staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js][staticsitesgetuserprovidedfunctionappforstaticsitebuildsample] | Description for Gets the details of the user provided function app registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json | +| [staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js][staticsitesgetuserprovidedfunctionappforstaticsitesample] | Description for Gets the details of the user provided function app registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSite.json | +| [staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js][staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample] | Description for Gets the details of the user provided function apps registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json | +| [staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js][staticsitesgetuserprovidedfunctionappsforstaticsitesample] | Description for Gets the details of the user provided function apps registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSite.json | +| [staticSitesLinkBackendSample.js][staticsiteslinkbackendsample] | Link backend to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSite.json | +| [staticSitesLinkBackendToBuildSample.js][staticsiteslinkbackendtobuildsample] | Link backend to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSiteBuild.json | +| [staticSitesListBasicAuthSample.js][staticsiteslistbasicauthsample] | Description for Gets the basic auth properties for a static site as a collection. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBasicAuth.json | +| [staticSitesListSample.js][staticsiteslistsample] | Description for Get all Static Sites for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAllStaticSites.json | +| [staticSitesListStaticSiteAppSettingsSample.js][staticsitesliststaticsiteappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteAppSettings.json | +| [staticSitesListStaticSiteBuildAppSettingsSample.js][staticsitesliststaticsitebuildappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildAppSettings.json | +| [staticSitesListStaticSiteBuildFunctionAppSettingsSample.js][staticsitesliststaticsitebuildfunctionappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctionAppSettings.json | +| [staticSitesListStaticSiteBuildFunctionsSample.js][staticsitesliststaticsitebuildfunctionssample] | Description for Gets the functions of a particular static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctions.json | +| [staticSitesListStaticSiteConfiguredRolesSample.js][staticsitesliststaticsiteconfiguredrolessample] | Description for Lists the roles configured for the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteConfiguredRoles.json | +| [staticSitesListStaticSiteCustomDomainsSample.js][staticsitesliststaticsitecustomdomainssample] | Description for Gets all static site custom domains for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomains.json | +| [staticSitesListStaticSiteFunctionAppSettingsSample.js][staticsitesliststaticsitefunctionappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctionAppSettings.json | +| [staticSitesListStaticSiteFunctionsSample.js][staticsitesliststaticsitefunctionssample] | Description for Gets the functions of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctions.json | +| [staticSitesListStaticSiteSecretsSample.js][staticsitesliststaticsitesecretssample] | Description for Lists the secrets for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteSecrets.json | +| [staticSitesListStaticSiteUsersSample.js][staticsitesliststaticsiteuserssample] | Description for Gets the list of users of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteUsers.json | +| [staticSitesPreviewWorkflowSample.js][staticsitespreviewworkflowsample] | Description for Generates a preview workflow file for the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GenerateStaticSiteWorkflowPreview.json | +| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js][staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample] | Description for Register a user provided function app with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json | +| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js][staticsitesregisteruserprovidedfunctionappwithstaticsitesample] | Description for Register a user provided function app with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json | +| [staticSitesResetStaticSiteApiKeySample.js][staticsitesresetstaticsiteapikeysample] | Description for Resets the api key for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ResetStaticSiteApiKey.json | +| [staticSitesUnlinkBackendFromBuildSample.js][staticsitesunlinkbackendfrombuildsample] | Unlink a backend from a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSiteBuild.json | +| [staticSitesUnlinkBackendSample.js][staticsitesunlinkbackendsample] | Unlink a backend from a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSite.json | +| [staticSitesUpdateBuildDatabaseConnectionSample.js][staticsitesupdatebuilddatabaseconnectionsample] | Description for Create or update a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteBuildDatabaseConnection.json | +| [staticSitesUpdateDatabaseConnectionSample.js][staticsitesupdatedatabaseconnectionsample] | Description for Create or update a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteDatabaseConnection.json | +| [staticSitesUpdateStaticSiteSample.js][staticsitesupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSite.json | +| [staticSitesUpdateStaticSiteUserSample.js][staticsitesupdatestaticsiteusersample] | Description for Updates a user entry with the listed roles x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateStaticSiteUser.json | +| [staticSitesValidateBackendForBuildSample.js][staticsitesvalidatebackendforbuildsample] | Validates that a backend can be linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSiteBuild.json | +| [staticSitesValidateBackendSample.js][staticsitesvalidatebackendsample] | Validates that a backend can be linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSite.json | +| [staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js][staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample] | Description for Validates a particular custom domain can be added to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateStaticSiteCustomDomain.json | +| [topLevelDomainsGetSample.js][topleveldomainsgetsample] | Description for Get details of a top-level domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetTopLevelDomain.json | +| [topLevelDomainsListAgreementsSample.js][topleveldomainslistagreementssample] | Description for Gets all legal agreements that user needs to accept before purchasing a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomainAgreements.json | +| [topLevelDomainsListSample.js][topleveldomainslistsample] | Description for Get all top-level domains supported for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomains.json | +| [verifyHostingEnvironmentVnetSample.js][verifyhostingenvironmentvnetsample] | Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/VerifyHostingEnvironmentVnet.json | +| [webAppsAnalyzeCustomHostnameSample.js][webappsanalyzecustomhostnamesample] | Description for Analyze a custom hostname. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostName.json | +| [webAppsAnalyzeCustomHostnameSlotSample.js][webappsanalyzecustomhostnameslotsample] | Description for Analyze a custom hostname. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostNameSlot.json | +| [webAppsApplySlotConfigToProductionSample.js][webappsapplyslotconfigtoproductionsample] | Description for Applies the configuration settings from the target slot onto the current slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApplySlotConfig.json | +| [webAppsApproveOrRejectPrivateEndpointConnectionSample.js][webappsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json | +| [webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js][webappsapproveorrejectprivateendpointconnectionslotsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json | +| [webAppsBackupSample.js][webappsbackupsample] | Description for Creates a backup of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/BackupWebApp.json | +| [webAppsCreateOrUpdateConfigurationSample.js][webappscreateorupdateconfigurationsample] | Description for Updates the configuration of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateSiteConfig.json | +| [webAppsCreateOrUpdateSample.js][webappscreateorupdatesample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebApp.json | +| [webAppsCreateOrUpdateSlotSample.js][webappscreateorupdateslotsample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebAppSlot.json | +| [webAppsDeleteBackupSample.js][webappsdeletebackupsample] | Description for Deletes a backup of an app by its ID. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppBackup.json | +| [webAppsDeletePrivateEndpointConnectionSample.js][webappsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json | +| [webAppsDeletePrivateEndpointConnectionSlotSample.js][webappsdeleteprivateendpointconnectionslotsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnectionSlot.json | +| [webAppsDeleteSample.js][webappsdeletesample] | Description for Deletes a web, mobile, or API app, or one of the deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebApp.json | +| [webAppsDeleteSlotSample.js][webappsdeleteslotsample] | Description for Deletes a web, mobile, or API app, or one of the deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppSlot.json | +| [webAppsDeployWorkflowArtifactsSample.js][webappsdeployworkflowartifactssample] | Description for Creates the artifacts for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteDeployWorkflowArtifacts.json | +| [webAppsDeployWorkflowArtifactsSlotSample.js][webappsdeployworkflowartifactsslotsample] | Description for Creates the artifacts for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifactsSlot.json | +| [webAppsGetAppSettingKeyVaultReferenceSample.js][webappsgetappsettingkeyvaultreferencesample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSetting.json | +| [webAppsGetAppSettingKeyVaultReferenceSlotSample.js][webappsgetappsettingkeyvaultreferenceslotsample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingSlot.json | +| [webAppsGetAppSettingsKeyVaultReferencesSample.js][webappsgetappsettingskeyvaultreferencessample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettings.json | +| [webAppsGetAppSettingsKeyVaultReferencesSlotSample.js][webappsgetappsettingskeyvaultreferencesslotsample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json | +| [webAppsGetAuthSettingsSample.js][webappsgetauthsettingssample] | Description for Gets the Authentication/Authorization settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettings.json | +| [webAppsGetAuthSettingsV2Sample.js][webappsgetauthsettingsv2sample] | Description for Gets site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettingsV2.json | +| [webAppsGetAuthSettingsV2WithoutSecretsSample.js][webappsgetauthsettingsv2withoutsecretssample] | Description for Gets site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAuthSettingsV2WithoutSecrets.json | +| [webAppsGetBackupStatusSample.js][webappsgetbackupstatussample] | Description for Gets a backup of an app by its ID. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackup.json | +| [webAppsGetConfigurationSample.js][webappsgetconfigurationsample] | Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteConfig.json | +| [webAppsGetFtpAllowedSample.js][webappsgetftpallowedsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json | +| [webAppsGetFtpAllowedSlotSample.js][webappsgetftpallowedslotsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json | +| [webAppsGetInstanceInfoSample.js][webappsgetinstanceinfosample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json | +| [webAppsGetInstanceInfoSlotSample.js][webappsgetinstanceinfoslotsample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json | +| [webAppsGetInstanceWorkflowSlotSample.js][webappsgetinstanceworkflowslotsample] | Get workflow information by its ID for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json | +| [webAppsGetNetworkTraceOperationSample.js][webappsgetnetworktraceoperationsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationSlotSample.js][webappsgetnetworktraceoperationslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationSlotV2Sample.js][webappsgetnetworktraceoperationslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationV2Sample.js][webappsgetnetworktraceoperationv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTracesSample.js][webappsgetnetworktracessample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesSlotSample.js][webappsgetnetworktracesslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesSlotV2Sample.js][webappsgetnetworktracesslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesV2Sample.js][webappsgetnetworktracesv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetPrivateEndpointConnectionSample.js][webappsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json | +| [webAppsGetPrivateEndpointConnectionSlotSample.js][webappsgetprivateendpointconnectionslotsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionSlot.json | +| [webAppsGetPrivateLinkResourcesSample.js][webappsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json | +| [webAppsGetPrivateLinkResourcesSlotSample.js][webappsgetprivatelinkresourcesslotsample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResourcesSlot.json | +| [webAppsGetProductionSiteDeploymentStatusSample.js][webappsgetproductionsitedeploymentstatussample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatus.json | +| [webAppsGetSample.js][webappsgetsample] | Description for Gets the details of a web, mobile, or API app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebApp.json | +| [webAppsGetScmAllowedSample.js][webappsgetscmallowedsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json | +| [webAppsGetScmAllowedSlotSample.js][webappsgetscmallowedslotsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json | +| [webAppsGetSlotSample.js][webappsgetslotsample] | Description for Gets the details of a web, mobile, or API app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppSlot.json | +| [webAppsGetSlotSiteDeploymentStatusSlotSample.js][webappsgetslotsitedeploymentstatusslotsample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatusSlot.json | +| [webAppsGetWorkflowSample.js][webappsgetworkflowsample] | Get workflow information by its ID for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json | +| [webAppsListApplicationSettingsSample.js][webappslistapplicationsettingssample] | Description for Gets the application settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppSettings.json | +| [webAppsListBackupStatusSecretsSample.js][webappslistbackupstatussecretssample] | Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackupWithSecrets.json | +| [webAppsListBackupsSample.js][webappslistbackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppBackups.json | +| [webAppsListBasicPublishingCredentialsPoliciesSample.js][webappslistbasicpublishingcredentialspoliciessample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPolicies.json | +| [webAppsListBasicPublishingCredentialsPoliciesSlotSample.js][webappslistbasicpublishingcredentialspoliciesslotsample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPoliciesSlot.json | +| [webAppsListByResourceGroupSample.js][webappslistbyresourcegroupsample] | Description for Gets all web, mobile, and API apps in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppsByResourceGroup.json | +| [webAppsListConfigurationsSample.js][webappslistconfigurationssample] | Description for List the configurations of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppConfigurations.json | +| [webAppsListInstanceWorkflowsSlotSample.js][webappslistinstanceworkflowsslotsample] | List the workflows for a web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json | +| [webAppsListProductionSiteDeploymentStatusesSample.js][webappslistproductionsitedeploymentstatusessample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatus.json | +| [webAppsListSample.js][webappslistsample] | Description for Get all apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebApps.json | +| [webAppsListSiteBackupsSample.js][webappslistsitebackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json | +| [webAppsListSiteBackupsSlotSample.js][webappslistsitebackupsslotsample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json | +| [webAppsListSlotSiteDeploymentStatusesSlotSample.js][webappslistslotsitedeploymentstatusesslotsample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatusSlot.json | +| [webAppsListSlotsSample.js][webappslistslotssample] | Description for Gets an app's deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppSlots.json | +| [webAppsListWorkflowsConnectionsSample.js][webappslistworkflowsconnectionssample] | Lists logic app's connections for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json | +| [webAppsListWorkflowsConnectionsSlotSample.js][webappslistworkflowsconnectionsslotsample] | Lists logic app's connections for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json | +| [webAppsListWorkflowsSample.js][webappslistworkflowssample] | List the workflows for a web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json | +| [webAppsRestoreSample.js][webappsrestoresample] | Description for Restores a specific backup to another app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestoreWebAppBackup.json | +| [webAppsStartNetworkTraceSample.js][webappsstartnetworktracesample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartNetworkTraceSlotSample.js][webappsstartnetworktraceslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartWebSiteNetworkTraceOperationSample.js][webappsstartwebsitenetworktraceoperationsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartWebSiteNetworkTraceOperationSlotSample.js][webappsstartwebsitenetworktraceoperationslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStopNetworkTraceSample.js][webappsstopnetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopNetworkTraceSlotSample.js][webappsstopnetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopWebSiteNetworkTraceSample.js][webappsstopwebsitenetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopWebSiteNetworkTraceSlotSample.js][webappsstopwebsitenetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsUpdateApplicationSettingsSample.js][webappsupdateapplicationsettingssample] | Description for Replaces the application settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAppSettings.json | +| [webAppsUpdateAuthSettingsSample.js][webappsupdateauthsettingssample] | Description for Updates the Authentication / Authorization settings associated with web app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettings.json | +| [webAppsUpdateAuthSettingsV2Sample.js][webappsupdateauthsettingsv2sample] | Description for Updates site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettingsV2.json | +| [webAppsUpdateAzureStorageAccountsSample.js][webappsupdateazurestorageaccountssample] | Description for Updates the Azure storage account configurations of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAzureStorageAccounts.json | +| [webAppsUpdateFtpAllowedSample.js][webappsupdateftpallowedsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json | +| [webAppsUpdateFtpAllowedSlotSample.js][webappsupdateftpallowedslotsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json | +| [webAppsUpdateSample.js][webappsupdatesample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebApp.json | +| [webAppsUpdateScmAllowedSample.js][webappsupdatescmallowedsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json | +| [webAppsUpdateScmAllowedSlotSample.js][webappsupdatescmallowedslotsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json | +| [webAppsUpdateSlotSample.js][webappsupdateslotsample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebAppSlot.json | +| [workflowRunActionRepetitionsGetSample.js][workflowrunactionrepetitionsgetsample] | Get a workflow run action repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_Get.json | +| [workflowRunActionRepetitionsListExpressionTracesSample.js][workflowrunactionrepetitionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json | +| [workflowRunActionRepetitionsListSample.js][workflowrunactionrepetitionslistsample] | Get all of a workflow run action repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_List.json | +| [workflowRunActionRepetitionsRequestHistoriesGetSample.js][workflowrunactionrepetitionsrequesthistoriesgetsample] | Gets a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json | +| [workflowRunActionRepetitionsRequestHistoriesListSample.js][workflowrunactionrepetitionsrequesthistorieslistsample] | List a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json | +| [workflowRunActionScopeRepetitionsGetSample.js][workflowrunactionscoperepetitionsgetsample] | Get a workflow run action scoped repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_Get.json | +| [workflowRunActionScopeRepetitionsListSample.js][workflowrunactionscoperepetitionslistsample] | List the workflow run action scoped repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_List.json | +| [workflowRunActionsGetSample.js][workflowrunactionsgetsample] | Gets a workflow run action. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_Get.json | +| [workflowRunActionsListExpressionTracesSample.js][workflowrunactionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_ListExpressionTraces.json | +| [workflowRunActionsListSample.js][workflowrunactionslistsample] | Gets a list of workflow run actions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_List.json | +| [workflowRunsCancelSample.js][workflowrunscancelsample] | Cancels a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Cancel.json | +| [workflowRunsGetSample.js][workflowrunsgetsample] | Gets a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Get.json | +| [workflowRunsListSample.js][workflowrunslistsample] | Gets a list of workflow runs. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_List.json | +| [workflowTriggerHistoriesGetSample.js][workflowtriggerhistoriesgetsample] | Gets a workflow trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Get.json | +| [workflowTriggerHistoriesListSample.js][workflowtriggerhistorieslistsample] | Gets a list of workflow trigger histories. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_List.json | +| [workflowTriggerHistoriesResubmitSample.js][workflowtriggerhistoriesresubmitsample] | Resubmits a workflow run based on the trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Resubmit.json | +| [workflowTriggersGetSample.js][workflowtriggersgetsample] | Gets a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Get.json | +| [workflowTriggersGetSchemaJsonSample.js][workflowtriggersgetschemajsonsample] | Get the trigger schema as JSON. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_GetSchemaJson.json | +| [workflowTriggersListCallbackUrlSample.js][workflowtriggerslistcallbackurlsample] | Get the callback URL for a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_ListCallbackUrl.json | +| [workflowTriggersListSample.js][workflowtriggerslistsample] | Gets a list of workflow triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_List.json | +| [workflowTriggersRunSample.js][workflowtriggersrunsample] | Runs a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Run.json | +| [workflowVersionsGetSample.js][workflowversionsgetsample] | Gets a workflow version. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_Get.json | +| [workflowVersionsListSample.js][workflowversionslistsample] | Gets a list of workflow versions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_List.json | +| [workflowsRegenerateAccessKeySample.js][workflowsregenerateaccesskeysample] | Regenerates the callback URL access key for request triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_RegenerateAccessKey.json | +| [workflowsValidateSample.js][workflowsvalidatesample] | Validates the workflow definition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_Validate.json | + +## Prerequisites + +The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule). + +You need [an Azure subscription][freesub] to run these sample programs. + +Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function. + +Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package]. + +## Setup + +To run the samples using the published version of the package: + +1. Install the dependencies using `npm`: + +```bash +npm install +``` + +2. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically. + +3. Run whichever samples you like (note that some samples may require additional setup, see the table above): + +```bash +node appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +``` + +Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): + +```bash +npx cross-env APPSERVICE_SUBSCRIPTION_ID="" APPSERVICE_RESOURCE_GROUP="" node appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +``` + +## Next Steps + +Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. + +[appservicecertificateorderscreateorupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +[appservicecertificateorderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js +[appservicecertificateordersdeletecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteCertificateSample.js +[appservicecertificateordersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteSample.js +[appservicecertificateordersgetcertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetCertificateSample.js +[appservicecertificateordersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetSample.js +[appservicecertificateorderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListByResourceGroupSample.js +[appservicecertificateorderslistcertificatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListCertificatesSample.js +[appservicecertificateorderslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListSample.js +[appservicecertificateordersreissuesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersReissueSample.js +[appservicecertificateordersrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRenewSample.js +[appservicecertificateordersresendemailsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendEmailSample.js +[appservicecertificateordersresendrequestemailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js +[appservicecertificateordersretrievecertificateactionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js +[appservicecertificateordersretrievecertificateemailhistorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js +[appservicecertificateordersretrievesitesealsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js +[appservicecertificateordersupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateCertificateSample.js +[appservicecertificateordersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateSample.js +[appservicecertificateordersvalidatepurchaseinformationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js +[appservicecertificateordersverifydomainownershipsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js +[appserviceenvironmentsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js +[appserviceenvironmentschangevnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsChangeVnetSample.js +[appserviceenvironmentscreateorupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js +[appserviceenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateSample.js +[appserviceenvironmentscreateorupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js +[appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js +[appserviceenvironmentsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js +[appserviceenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteSample.js +[appserviceenvironmentsgetasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js +[appserviceenvironmentsgetasev3networkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js +[appserviceenvironmentsgetdiagnosticsitemsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js +[appserviceenvironmentsgetinboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js +[appserviceenvironmentsgetmultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js +[appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js +[appserviceenvironmentsgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js +[appserviceenvironmentsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js +[appserviceenvironmentsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js +[appserviceenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetSample.js +[appserviceenvironmentsgetvipinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetVipInfoSample.js +[appserviceenvironmentsgetworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetWorkerPoolSample.js +[appserviceenvironmentslistappserviceplanssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListAppServicePlansSample.js +[appserviceenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListByResourceGroupSample.js +[appserviceenvironmentslistcapacitiessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListCapacitiesSample.js +[appserviceenvironmentslistdiagnosticssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListDiagnosticsSample.js +[appserviceenvironmentslistmultirolemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js +[appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js +[appserviceenvironmentslistmultirolepoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js +[appserviceenvironmentslistmultirolepoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js +[appserviceenvironmentslistmultiroleusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js +[appserviceenvironmentslistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListOperationsSample.js +[appserviceenvironmentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListSample.js +[appserviceenvironmentslistusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListUsagesSample.js +[appserviceenvironmentslistwebappssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebAppsSample.js +[appserviceenvironmentslistwebworkermetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js +[appserviceenvironmentslistwebworkerusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js +[appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js +[appserviceenvironmentslistworkerpoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js +[appserviceenvironmentslistworkerpoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolsSample.js +[appserviceenvironmentsrebootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsRebootSample.js +[appserviceenvironmentsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsResumeSample.js +[appserviceenvironmentssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsSuspendSample.js +[appserviceenvironmentstestupgradeavailablenotificationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js +[appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js +[appserviceenvironmentsupdateasenetworkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js +[appserviceenvironmentsupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js +[appserviceenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateSample.js +[appserviceenvironmentsupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js +[appserviceenvironmentsupgradesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpgradeSample.js +[appserviceplanscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansCreateOrUpdateSample.js +[appserviceplansdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansDeleteSample.js +[appserviceplansgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansGetSample.js +[appserviceplanslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListByResourceGroupSample.js +[appserviceplanslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListSample.js +[appserviceplansupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansUpdateSample.js +[certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js +[certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js +[certificateregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificateRegistrationProviderListOperationsSample.js +[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesCreateOrUpdateSample.js +[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesDeleteSample.js +[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesGetSample.js +[certificateslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListByResourceGroupSample.js +[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListSample.js +[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesUpdateSample.js +[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsCreateOrUpdateSample.js +[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsDeleteSample.js +[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsGetSample.js +[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListByResourceGroupSample.js +[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListBySubscriptionSample.js +[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListSecretsSample.js +[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsActivateRevisionSample.js +[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsDeactivateRevisionSample.js +[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsGetRevisionSample.js +[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsListRevisionsSample.js +[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsRestartRevisionSample.js +[deletedwebappsgetdeletedwebappbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js +[deletedwebappslistbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsListByLocationSample.js +[diagnosticsexecutesiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSample.js +[diagnosticsexecutesiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js +[diagnosticsexecutesitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSample.js +[diagnosticsexecutesitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSlotSample.js +[diagnosticsgethostingenvironmentdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js +[diagnosticsgetsiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSample.js +[diagnosticsgetsiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSlotSample.js +[diagnosticsgetsitedetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSample.js +[diagnosticsgetsitedetectorresponseslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js +[diagnosticsgetsitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSample.js +[diagnosticsgetsitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSlotSample.js +[diagnosticsgetsitediagnosticcategorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySample.js +[diagnosticsgetsitediagnosticcategoryslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js +[diagnosticslisthostingenvironmentdetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js +[diagnosticslistsiteanalysessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSample.js +[diagnosticslistsiteanalysesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSlotSample.js +[diagnosticslistsitedetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSample.js +[diagnosticslistsitedetectorresponsesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js +[diagnosticslistsitedetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSample.js +[diagnosticslistsitedetectorsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSlotSample.js +[diagnosticslistsitediagnosticcategoriessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js +[diagnosticslistsitediagnosticcategoriesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js +[domainregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainRegistrationProviderListOperationsSample.js +[domainscheckavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCheckAvailabilitySample.js +[domainscreateorupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js +[domainscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateSample.js +[domainsdeleteownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteOwnershipIdentifierSample.js +[domainsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteSample.js +[domainsgetcontrolcenterssorequestsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetControlCenterSsoRequestSample.js +[domainsgetownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetOwnershipIdentifierSample.js +[domainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetSample.js +[domainslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListByResourceGroupSample.js +[domainslistownershipidentifierssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListOwnershipIdentifiersSample.js +[domainslistrecommendationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListRecommendationsSample.js +[domainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListSample.js +[domainsrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsRenewSample.js +[domainstransferoutsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsTransferOutSample.js +[domainsupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateOwnershipIdentifierSample.js +[domainsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateSample.js +[globalgetdeletedwebappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSample.js +[globalgetdeletedwebappsnapshotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSnapshotsSample.js +[globalgetsubscriptionoperationwithasyncresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js +[kubeenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsCreateOrUpdateSample.js +[kubeenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsDeleteSample.js +[kubeenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsGetSample.js +[kubeenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListByResourceGroupSample.js +[kubeenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListBySubscriptionSample.js +[kubeenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsUpdateSample.js +[listcustomhostnamesitessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/listCustomHostNameSitesSample.js +[providergetfunctionappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksForLocationSample.js +[providergetfunctionappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksSample.js +[providergetwebappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksForLocationSample.js +[providergetwebappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksSample.js +[providerlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/providerListOperationsSample.js +[resourcehealthmetadatagetbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSample.js +[resourcehealthmetadatagetbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSlotSample.js +[resourcehealthmetadatalistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListByResourceGroupSample.js +[resourcehealthmetadatalistbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSample.js +[resourcehealthmetadatalistbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSlotSample.js +[resourcehealthmetadatalistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListSample.js +[staticsitesapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js +[staticsitescreateorupdatebasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBasicAuthSample.js +[staticsitescreateorupdatebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.js +[staticsitescreateorupdatedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateDatabaseConnectionSample.js +[staticsitescreateorupdatestaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js +[staticsitescreateorupdatestaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js +[staticsitescreateorupdatestaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js +[staticsitescreateorupdatestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js +[staticsitescreateorupdatestaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js +[staticsitescreateorupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteSample.js +[staticsitescreateuserrolesinvitationlinksample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateUserRolesInvitationLinkSample.js +[staticsitescreatezipdeploymentforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js +[staticsitescreatezipdeploymentforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js +[staticsitesdeletebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteBuildDatabaseConnectionSample.js +[staticsitesdeletedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteDatabaseConnectionSample.js +[staticsitesdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeletePrivateEndpointConnectionSample.js +[staticsitesdeletestaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteBuildSample.js +[staticsitesdeletestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js +[staticsitesdeletestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteSample.js +[staticsitesdeletestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteUserSample.js +[staticsitesdetachstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachStaticSiteSample.js +[staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js +[staticsitesdetachuserprovidedfunctionappfromstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js +[staticsitesgetbasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBasicAuthSample.js +[staticsitesgetbuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionSample.js +[staticsitesgetbuilddatabaseconnectionwithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionWithDetailsSample.js +[staticsitesgetbuilddatabaseconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsSample.js +[staticsitesgetbuilddatabaseconnectionswithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.js +[staticsitesgetdatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionSample.js +[staticsitesgetdatabaseconnectionwithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionWithDetailsSample.js +[staticsitesgetdatabaseconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsSample.js +[staticsitesgetdatabaseconnectionswithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsWithDetailsSample.js +[staticsitesgetlinkedbackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendForBuildSample.js +[staticsitesgetlinkedbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendSample.js +[staticsitesgetlinkedbackendsforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsForBuildSample.js +[staticsitesgetlinkedbackendssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsSample.js +[staticsitesgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionListSample.js +[staticsitesgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionSample.js +[staticsitesgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateLinkResourcesSample.js +[staticsitesgetstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildSample.js +[staticsitesgetstaticsitebuildssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildsSample.js +[staticsitesgetstaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteCustomDomainSample.js +[staticsitesgetstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteSample.js +[staticsitesgetstaticsitesbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSitesByResourceGroupSample.js +[staticsitesgetuserprovidedfunctionappforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js +[staticsitesgetuserprovidedfunctionappforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js +[staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js +[staticsitesgetuserprovidedfunctionappsforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js +[staticsiteslinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendSample.js +[staticsiteslinkbackendtobuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendToBuildSample.js +[staticsiteslistbasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListBasicAuthSample.js +[staticsiteslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListSample.js +[staticsitesliststaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteAppSettingsSample.js +[staticsitesliststaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js +[staticsitesliststaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js +[staticsitesliststaticsitebuildfunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionsSample.js +[staticsitesliststaticsiteconfiguredrolessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteConfiguredRolesSample.js +[staticsitesliststaticsitecustomdomainssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteCustomDomainsSample.js +[staticsitesliststaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js +[staticsitesliststaticsitefunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionsSample.js +[staticsitesliststaticsitesecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteSecretsSample.js +[staticsitesliststaticsiteuserssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteUsersSample.js +[staticsitespreviewworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesPreviewWorkflowSample.js +[staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js +[staticsitesregisteruserprovidedfunctionappwithstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js +[staticsitesresetstaticsiteapikeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesResetStaticSiteApiKeySample.js +[staticsitesunlinkbackendfrombuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendFromBuildSample.js +[staticsitesunlinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendSample.js +[staticsitesupdatebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateBuildDatabaseConnectionSample.js +[staticsitesupdatedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateDatabaseConnectionSample.js +[staticsitesupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteSample.js +[staticsitesupdatestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteUserSample.js +[staticsitesvalidatebackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendForBuildSample.js +[staticsitesvalidatebackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendSample.js +[staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js +[topleveldomainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsGetSample.js +[topleveldomainslistagreementssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListAgreementsSample.js +[topleveldomainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListSample.js +[verifyhostingenvironmentvnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/verifyHostingEnvironmentVnetSample.js +[webappsanalyzecustomhostnamesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSample.js +[webappsanalyzecustomhostnameslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSlotSample.js +[webappsapplyslotconfigtoproductionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApplySlotConfigToProductionSample.js +[webappsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js +[webappsapproveorrejectprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js +[webappsbackupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsBackupSample.js +[webappscreateorupdateconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateConfigurationSample.js +[webappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSample.js +[webappscreateorupdateslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSlotSample.js +[webappsdeletebackupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteBackupSample.js +[webappsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSample.js +[webappsdeleteprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js +[webappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSample.js +[webappsdeleteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSlotSample.js +[webappsdeployworkflowartifactssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSample.js +[webappsdeployworkflowartifactsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSlotSample.js +[webappsgetappsettingkeyvaultreferencesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js +[webappsgetappsettingkeyvaultreferenceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js +[webappsgetappsettingskeyvaultreferencessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js +[webappsgetappsettingskeyvaultreferencesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js +[webappsgetauthsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsSample.js +[webappsgetauthsettingsv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2Sample.js +[webappsgetauthsettingsv2withoutsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2WithoutSecretsSample.js +[webappsgetbackupstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetBackupStatusSample.js +[webappsgetconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetConfigurationSample.js +[webappsgetftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSample.js +[webappsgetftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSlotSample.js +[webappsgetinstanceinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSample.js +[webappsgetinstanceinfoslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSlotSample.js +[webappsgetinstanceworkflowslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceWorkflowSlotSample.js +[webappsgetnetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSample.js +[webappsgetnetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotSample.js +[webappsgetnetworktraceoperationslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js +[webappsgetnetworktraceoperationv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationV2Sample.js +[webappsgetnetworktracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSample.js +[webappsgetnetworktracesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotSample.js +[webappsgetnetworktracesslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotV2Sample.js +[webappsgetnetworktracesv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesV2Sample.js +[webappsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSample.js +[webappsgetprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js +[webappsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSample.js +[webappsgetprivatelinkresourcesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSlotSample.js +[webappsgetproductionsitedeploymentstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetProductionSiteDeploymentStatusSample.js +[webappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSample.js +[webappsgetscmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSample.js +[webappsgetscmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSlotSample.js +[webappsgetslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSample.js +[webappsgetslotsitedeploymentstatusslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js +[webappsgetworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetWorkflowSample.js +[webappslistapplicationsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListApplicationSettingsSample.js +[webappslistbackupstatussecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupStatusSecretsSample.js +[webappslistbackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupsSample.js +[webappslistbasicpublishingcredentialspoliciessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js +[webappslistbasicpublishingcredentialspoliciesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js +[webappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListByResourceGroupSample.js +[webappslistconfigurationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListConfigurationsSample.js +[webappslistinstanceworkflowsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListInstanceWorkflowsSlotSample.js +[webappslistproductionsitedeploymentstatusessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListProductionSiteDeploymentStatusesSample.js +[webappslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSample.js +[webappslistsitebackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSample.js +[webappslistsitebackupsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSlotSample.js +[webappslistslotsitedeploymentstatusesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js +[webappslistslotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotsSample.js +[webappslistworkflowsconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSample.js +[webappslistworkflowsconnectionsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSlotSample.js +[webappslistworkflowssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsSample.js +[webappsrestoresample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsRestoreSample.js +[webappsstartnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSample.js +[webappsstartnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSlotSample.js +[webappsstartwebsitenetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js +[webappsstartwebsitenetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js +[webappsstopnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSample.js +[webappsstopnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSlotSample.js +[webappsstopwebsitenetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSample.js +[webappsstopwebsitenetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js +[webappsupdateapplicationsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateApplicationSettingsSample.js +[webappsupdateauthsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsSample.js +[webappsupdateauthsettingsv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsV2Sample.js +[webappsupdateazurestorageaccountssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAzureStorageAccountsSample.js +[webappsupdateftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSample.js +[webappsupdateftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSlotSample.js +[webappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSample.js +[webappsupdatescmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSample.js +[webappsupdatescmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSlotSample.js +[webappsupdateslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSlotSample.js +[workflowrunactionrepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsGetSample.js +[workflowrunactionrepetitionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js +[workflowrunactionrepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListSample.js +[workflowrunactionrepetitionsrequesthistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js +[workflowrunactionrepetitionsrequesthistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js +[workflowrunactionscoperepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsGetSample.js +[workflowrunactionscoperepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsListSample.js +[workflowrunactionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsGetSample.js +[workflowrunactionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListExpressionTracesSample.js +[workflowrunactionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListSample.js +[workflowrunscancelsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsCancelSample.js +[workflowrunsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsGetSample.js +[workflowrunslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsListSample.js +[workflowtriggerhistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesGetSample.js +[workflowtriggerhistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesListSample.js +[workflowtriggerhistoriesresubmitsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesResubmitSample.js +[workflowtriggersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSample.js +[workflowtriggersgetschemajsonsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSchemaJsonSample.js +[workflowtriggerslistcallbackurlsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListCallbackUrlSample.js +[workflowtriggerslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListSample.js +[workflowtriggersrunsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersRunSample.js +[workflowversionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsGetSample.js +[workflowversionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsListSample.js +[workflowsregenerateaccesskeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsRegenerateAccessKeySample.js +[workflowsvalidatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsValidateSample.js +[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-appservice?view=azure-node-preview +[freesub]: https://azure.microsoft.com/free/ +[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice/README.md diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js index 41215d590721..339319d78fa0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificate.json */ async function createCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate = { @@ -39,4 +41,8 @@ async function createCertificate() { console.log(result); } -createCertificate().catch(console.error); +async function main() { + createCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js similarity index 83% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js index 36a8c3bfa662..030228e9ca7b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificateOrder.json */ async function createCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName = { autoRenew: true, @@ -51,4 +53,8 @@ async function createCertificateOrder() { console.log(result); } -createCertificateOrder().catch(console.error); +async function main() { + createCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteCertificateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteCertificateSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteCertificateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteCertificateSample.js index f2d6e4a113eb..f2969a29c9cf 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersDeleteCertificateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteCertificateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Delete the certificate associated with a certificate order. * * @summary Description for Delete the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/DeleteAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificate.json */ async function deleteAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function deleteAppServiceCertificate() { console.log(result); } -deleteAppServiceCertificate().catch(console.error); +async function main() { + deleteAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteSample.js new file mode 100644 index 000000000000..d41fc64d4900 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersDeleteSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete an existing certificate order. + * + * @summary Description for Delete an existing certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificateOrder.json + */ +async function deleteAppServiceCertificateOrder() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.delete( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + deleteAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetCertificateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetCertificateSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetCertificateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetCertificateSample.js index d1c19815f72c..90efde001afd 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersGetCertificateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetCertificateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get the certificate associated with a certificate order. * * @summary Description for Get the certificate associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/GetAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificate.json */ async function getAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getAppServiceCertificate() { console.log(result); } -getAppServiceCertificate().catch(console.error); +async function main() { + getAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetSample.js new file mode 100644 index 000000000000..68b5988fe522 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersGetSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get a certificate order. + * + * @summary Description for Get a certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificateOrder.json + */ +async function getAppServiceCertificateOrder() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.get( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + getAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListByResourceGroupSample.js new file mode 100644 index 000000000000..c62b2fbc41ed --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListByResourceGroupSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get certificate orders in a resource group. + * + * @summary Description for Get certificate orders in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json + */ +async function listAppServiceCertificateOrdersByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceCertificateOrders.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppServiceCertificateOrdersByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListCertificatesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListCertificatesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListCertificatesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListCertificatesSample.js index dca6c5168b3f..9a6ddee53103 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListCertificatesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListCertificatesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for List all certificates associated with a certificate order. * * @summary Description for List all certificates associated with a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListCertificatesByAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListCertificatesByAppServiceCertificateOrder.json */ async function listCertificatesByAppServiceCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function listCertificatesByAppServiceCertificate() { console.log(resArray); } -listCertificatesByAppServiceCertificate().catch(console.error); +async function main() { + listCertificatesByAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListSample.js index c329382bf8a1..39e3f506ee61 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for List all certificate orders in a subscription. * * @summary Description for List all certificate orders in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersBySubscription.json */ async function listAppServiceCertificateOrdersBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listAppServiceCertificateOrdersBySubscription() { console.log(resArray); } -listAppServiceCertificateOrdersBySubscription().catch(console.error); +async function main() { + listAppServiceCertificateOrdersBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersReissueSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersReissueSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersReissueSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersReissueSample.js index a178b5082197..7770377bf56b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersReissueSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersReissueSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Reissue an existing certificate order. * * @summary Description for Reissue an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ReissueAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ReissueAppServiceCertificateOrder.json */ async function reissueAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const reissueCertificateOrderRequest = { csr: "CSR1223238Value", @@ -37,4 +39,8 @@ async function reissueAppServiceCertificateOrder() { console.log(result); } -reissueAppServiceCertificateOrder().catch(console.error); +async function main() { + reissueAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRenewSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRenewSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRenewSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRenewSample.js index be960e7d5611..10c7d57f7471 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRenewSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRenewSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Renew an existing certificate order. * * @summary Description for Renew an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RenewAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RenewAppServiceCertificateOrder.json */ async function renewAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const renewCertificateOrderRequest = { csr: "CSR1223238Value", @@ -36,4 +38,8 @@ async function renewAppServiceCertificateOrder() { console.log(result); } -renewAppServiceCertificateOrder().catch(console.error); +async function main() { + renewAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendEmailSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendEmailSample.js new file mode 100644 index 000000000000..eb4c8fc57132 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendEmailSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Resend certificate email. + * + * @summary Description for Resend certificate email. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendAppServiceCertificateOrderEmail.json + */ +async function resendAppServiceCertificateOrderEmail() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.resendEmail( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + resendAppServiceCertificateOrderEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js index e534ca0a264a..157a3d8d4b5e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersResendRequestEmailsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order * * @summary Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendDomainOwnershipVerificationEmail.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendDomainOwnershipVerificationEmail.json */ async function resendDomainOwnershipVerificationEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const nameIdentifier = { name: "Domain name" }; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function resendDomainOwnershipVerificationEmail() { console.log(result); } -resendDomainOwnershipVerificationEmail().catch(console.error); +async function main() { + resendDomainOwnershipVerificationEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js new file mode 100644 index 000000000000..e53e5ea96869 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateActionsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Retrieve the list of certificate actions. + * + * @summary Description for Retrieve the list of certificate actions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateOrderActions.json + */ +async function retrieveCertificateOrderActions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleCertOrder"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.retrieveCertificateActions( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + retrieveCertificateOrderActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js new file mode 100644 index 000000000000..7ff9980907b9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Retrieve email history. + * + * @summary Description for Retrieve email history. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateEmailHistory.json + */ +async function retrieveCertificateEmailHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleCertOrder"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.retrieveCertificateEmailHistory( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + retrieveCertificateEmailHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js similarity index 86% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js index d419fea344fd..5b8781c407a3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersRetrieveSiteSealSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. * * @summary This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveSiteSeal.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveSiteSeal.json */ async function retrieveSiteSeal() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertOrder"; const siteSealRequest = { lightTheme: true, @@ -35,4 +37,8 @@ async function retrieveSiteSeal() { console.log(result); } -retrieveSiteSeal().catch(console.error); +async function main() { + retrieveSiteSeal(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateCertificateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateCertificateSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateCertificateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateCertificateSample.js index 21bdf5968cd5..92b769583dd4 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateCertificateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateCertificateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificate.json */ async function updateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate = { @@ -38,4 +40,8 @@ async function updateCertificate() { console.log(result); } -updateCertificate().catch(console.error); +async function main() { + updateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateSample.js similarity index 83% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateSample.js index 4fa940d44d78..46ce476afd96 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificateOrder.json */ async function updateCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName = { autoRenew: true, @@ -50,4 +52,8 @@ async function updateCertificateOrder() { console.log(result); } -updateCertificateOrder().catch(console.error); +async function main() { + updateCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js similarity index 84% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js index b3be6b90b8dc..532b2de54e14 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersValidatePurchaseInformationSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Validate information for a certificate order. * * @summary Description for Validate information for a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json */ async function validateAppServiceCertificatePurchaseInformationBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const appServiceCertificateOrder = { autoRenew: true, certificates: { @@ -47,4 +49,8 @@ async function validateAppServiceCertificatePurchaseInformationBySubscription() console.log(result); } -validateAppServiceCertificatePurchaseInformationBySubscription().catch(console.error); +async function main() { + validateAppServiceCertificatePurchaseInformationBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js new file mode 100644 index 000000000000..5a482a63e0ca --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceCertificateOrdersVerifyDomainOwnershipSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Verify domain ownership for this certificate order. + * + * @summary Description for Verify domain ownership for this certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/VerifyDomainOwnership.json + */ +async function verifyDomainOwnership() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.verifyDomainOwnership( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + verifyDomainOwnership(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js index 11d755592532..a63e92b0f3e3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const privateEndpointWrapper = { @@ -40,4 +42,8 @@ async function approvesOrRejectsAPrivateEndpointConnection() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnection().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsChangeVnetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsChangeVnetSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsChangeVnetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsChangeVnetSample.js index 54db7a13fb54..70b501cd83e8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsChangeVnetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsChangeVnetSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Move an App Service Environment to a different VNET. * * @summary Description for Move an App Service Environment to a different VNET. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ChangeVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ChangeVnet.json */ async function moveAnAppServiceEnvironmentToADifferentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const vnetInfo = { id: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/test-rg/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/default", @@ -37,4 +39,8 @@ async function moveAnAppServiceEnvironmentToADifferentVnet() { console.log(resArray); } -moveAnAppServiceEnvironmentToADifferentVnet().catch(console.error); +async function main() { + moveAnAppServiceEnvironmentToADifferentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js index 2df08504bf36..7096c24ea43f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a multi-role pool. * * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json */ async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const multiRolePoolEnvelope = { workerCount: 3, @@ -35,4 +37,8 @@ async function createOrUpdateAMultiRolePool() { console.log(result); } -createOrUpdateAMultiRolePool().catch(console.error); +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateSample.js index 29bc8253b7e3..a5199ab41f35 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdate.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope = { kind: "Asev3", @@ -38,4 +40,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js index 126cf67f0ef0..a7623624b1a4 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a worker pool. * * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json */ async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const workerPoolEnvelope = { @@ -37,4 +39,8 @@ async function getPropertiesOfAWorkerPool() { console.log(result); } -getPropertiesOfAWorkerPool().catch(console.error); +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js new file mode 100644 index 000000000000..4e4a6e59f1ab --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Delete Custom Dns Suffix configuration of an App Service Environment + * + * @summary Delete Custom Dns Suffix configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAseCustomDnsSuffixConfiguration.json + */ +async function deleteAseCustomDnsSuffixConfiguration() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.deleteAseCustomDnsSuffixConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js index 331253569634..89fbe30c1d7c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json */ async function deletesAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function deletesAPrivateEndpointConnection() { console.log(result); } -deletesAPrivateEndpointConnection().catch(console.error); +async function main() { + deletesAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteSample.js new file mode 100644 index 000000000000..e3cb98000f17 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete an App Service Environment. + * + * @summary Description for Delete an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Delete.json + */ +async function deleteAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginDeleteAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js new file mode 100644 index 000000000000..9fca831692f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get Custom Dns Suffix configuration of an App Service Environment + * + * @summary Get Custom Dns Suffix configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAseCustomDnsSuffixConfiguration.json + */ +async function getAseCustomDnsSuffixConfiguration() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getAseCustomDnsSuffixConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js new file mode 100644 index 000000000000..dc5a8ccccdad --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get networking configuration of an App Service Environment + * + * @summary Description for Get networking configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json + */ +async function getNetworkingConfigurationOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getAseV3NetworkingConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js new file mode 100644 index 000000000000..fc4629e63ed8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetDiagnosticsItemSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get a diagnostics item for an App Service Environment. + * + * @summary Description for Get a diagnostics item for an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json + */ +async function getADiagnosticsItemForAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const diagnosticsName = "test-diagnostic"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getDiagnosticsItem( + resourceGroupName, + name, + diagnosticsName + ); + console.log(result); +} + +async function main() { + getADiagnosticsItemForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js new file mode 100644 index 000000000000..afb4a83237d2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get the network endpoints of all inbound dependencies of an App Service Environment. + * + * @summary Description for Get the network endpoints of all inbound dependencies of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetInboundNetworkDependenciesEndpoints.json + */ +async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAse"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listInboundNetworkDependenciesEndpoints( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js new file mode 100644 index 000000000000..e39a4f9eaf9a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetMultiRolePoolSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get properties of a multi-role pool. + * + * @summary Description for Get properties of a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetMultiRolePool.json + */ +async function getPropertiesOfAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getMultiRolePool(resourceGroupName, name); + console.log(result); +} + +async function main() { + getPropertiesOfAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js new file mode 100644 index 000000000000..b8f93ce05bd7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get the network endpoints of all outbound dependencies of an App Service Environment. + * + * @summary Description for Get the network endpoints of all outbound dependencies of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetOutboundNetworkDependenciesEndpoints.json + */ +async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAse"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listOutboundNetworkDependenciesEndpoints( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js new file mode 100644 index 000000000000..eaa53e569f39 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the list of private endpoints associated with a hosting environment + * + * @summary Description for Gets the list of private endpoints associated with a hosting environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json + */ +async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listPrivateEndpointConnectionList( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js index 451e75a773ca..e1552eba3f53 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateEndpointConnectionSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a private endpoint connection * * @summary Description for Gets a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json */ async function getsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getsAPrivateEndpointConnection() { console.log(result); } -getsAPrivateEndpointConnection().catch(console.error); +async function main() { + getsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js new file mode 100644 index 000000000000..dd4f274f1ce2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetPrivateLinkResourcesSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json + */ +async function getsThePrivateLinkResources() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getPrivateLinkResources( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getsThePrivateLinkResources(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetSample.js new file mode 100644 index 000000000000..cd7086683590 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get the properties of an App Service Environment. + * + * @summary Description for Get the properties of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Get.json + */ +async function getThePropertiesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getThePropertiesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetVipInfoSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetVipInfoSample.js new file mode 100644 index 000000000000..fd49eda39543 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetVipInfoSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get IP addresses assigned to an App Service Environment. + * + * @summary Description for Get IP addresses assigned to an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetVipInfo.json + */ +async function getIPAddressesAssignedToAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getVipInfo(resourceGroupName, name); + console.log(result); +} + +async function main() { + getIPAddressesAssignedToAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetWorkerPoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetWorkerPoolSample.js new file mode 100644 index 000000000000..f7bf2dc8b129 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsGetWorkerPoolSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get properties of a worker pool. + * + * @summary Description for Get properties of a worker pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetWorkerPool.json + */ +async function getPropertiesOfAWorkerPool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "workerPool1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getWorkerPool( + resourceGroupName, + name, + workerPoolName + ); + console.log(result); +} + +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListAppServicePlansSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListAppServicePlansSample.js new file mode 100644 index 000000000000..4a297fff8855 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListAppServicePlansSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all App Service plans in an App Service Environment. + * + * @summary Description for Get all App Service plans in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListAppServicePlans.json + */ +async function getAllAppServicePlansInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listAppServicePlans( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppServicePlansInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListByResourceGroupSample.js new file mode 100644 index 000000000000..f50517f9de29 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all App Service Environments in a resource group. + * + * @summary Description for Get all App Service Environments in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListByResourceGroup.json + */ +async function getAllAppServiceEnvironmentsInAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppServiceEnvironmentsInAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListCapacitiesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListCapacitiesSample.js new file mode 100644 index 000000000000..053a4d0fd7f3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListCapacitiesSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get the used, available, and total worker capacity an App Service Environment. + * + * @summary Description for Get the used, available, and total worker capacity an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListCapacities.json + */ +async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listCapacities(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListDiagnosticsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListDiagnosticsSample.js new file mode 100644 index 000000000000..d171d3d01f48 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListDiagnosticsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get diagnostic information for an App Service Environment. + * + * @summary Description for Get diagnostic information for an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListDiagnostics.json + */ +async function getDiagnosticInformationForAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.listDiagnostics(resourceGroupName, name); + console.log(result); +} + +async function main() { + getDiagnosticInformationForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js new file mode 100644 index 000000000000..17913517eb55 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get metric definitions for a multi-role pool of an App Service Environment. + * + * @summary Description for Get metric definitions for a multi-role pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json + */ +async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRoleMetricDefinitions( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js index 936b3f93adcc..0715aebdbffd 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. * * @summary Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json */ async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const instance = "10.7.1.8"; const credential = new DefaultAzureCredential(); @@ -35,6 +37,8 @@ async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppSe console.log(resArray); } -getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js new file mode 100644 index 000000000000..e003b89b8b16 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolSkusSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get available SKUs for scaling a multi-role pool. + * + * @summary Description for Get available SKUs for scaling a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json + */ +async function getAvailableSkUsForScalingAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRolePoolSkus( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAvailableSkUsForScalingAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js new file mode 100644 index 000000000000..20d5eb7a44de --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRolePoolsSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all multi-role pools. + * + * @summary Description for Get all multi-role pools. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePools.json + */ +async function getAllMultiRolePools() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRolePools( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllMultiRolePools(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js new file mode 100644 index 000000000000..ad150f265c3f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListMultiRoleUsagesSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get usage metrics for a multi-role pool of an App Service Environment. + * + * @summary Description for Get usage metrics for a multi-role pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json + */ +async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRoleUsages( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListOperationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListOperationsSample.js new file mode 100644 index 000000000000..3cd0de3b60f0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListOperationsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List all currently running operations on the App Service Environment. + * + * @summary Description for List all currently running operations on the App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListOperations.json + */ +async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.listOperations(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListSample.js index 41e43456b49b..cb5a94bf3eaa 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all App Service Environments for a subscription. * * @summary Description for Get all App Service Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_List.json */ async function getAllAppServiceEnvironmentsForASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function getAllAppServiceEnvironmentsForASubscription() { console.log(resArray); } -getAllAppServiceEnvironmentsForASubscription().catch(console.error); +async function main() { + getAllAppServiceEnvironmentsForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListUsagesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListUsagesSample.js new file mode 100644 index 000000000000..c229596a8d56 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListUsagesSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get global usage metrics of an App Service Environment. + * + * @summary Description for Get global usage metrics of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListUsages.json + */ +async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listUsages(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getGlobalUsageMetricsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebAppsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebAppsSample.js new file mode 100644 index 000000000000..51598aa312f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebAppsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all apps in an App Service Environment. + * + * @summary Description for Get all apps in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebApps.json + */ +async function getAllAppsInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWebApps(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppsInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js index 630a20a4d079..df06eaf1ecaa 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get metric definitions for a worker pool of an App Service Environment. * * @summary Description for Get metric definitions for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json */ async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { console.log(resArray); } -getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js index fda78554e0f8..4b464ad52371 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWebWorkerUsagesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get usage metrics for a worker pool of an App Service Environment. * * @summary Description for Get usage metrics for a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json */ async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { console.log(resArray); } -getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment().catch(console.error); +async function main() { + getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js index 037006689145..3c292a8fcf3e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. * * @summary Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json */ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const instance = "10.8.0.7"; @@ -37,6 +39,8 @@ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServi console.log(resArray); } -getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js index 89fbf1f7a309..d8bbe137b103 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolSkusSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get available SKUs for scaling a worker pool. * * @summary Description for Get available SKUs for scaling a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json */ async function getAvailableSkUsForScalingAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "workerPool1"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function getAvailableSkUsForScalingAWorkerPool() { console.log(resArray); } -getAvailableSkUsForScalingAWorkerPool().catch(console.error); +async function main() { + getAvailableSkUsForScalingAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolsSample.js new file mode 100644 index 000000000000..517ae192e15d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsListWorkerPoolsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all worker pools of an App Service Environment. + * + * @summary Description for Get all worker pools of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPools.json + */ +async function getAllWorkerPoolsOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWorkerPools(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllWorkerPoolsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsRebootSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsRebootSample.js new file mode 100644 index 000000000000..3fd66fe6f87d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsRebootSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Reboot all machines in an App Service Environment. + * + * @summary Description for Reboot all machines in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Reboot.json + */ +async function rebootAllMachinesInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.reboot(resourceGroupName, name); + console.log(result); +} + +async function main() { + rebootAllMachinesInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsResumeSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsResumeSample.js new file mode 100644 index 000000000000..2837939ab755 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsResumeSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Resume an App Service Environment. + * + * @summary Description for Resume an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Resume.json + */ +async function resumeAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.beginListResumeAndWait( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + resumeAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsSuspendSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsSuspendSample.js new file mode 100644 index 000000000000..aa0c0453bcc1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsSuspendSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Suspend an App Service Environment. + * + * @summary Description for Suspend an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Suspend.json + */ +async function suspendAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.beginListSuspendAndWait( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + suspendAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js new file mode 100644 index 000000000000..ca67da95d1af --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Send a test notification that an upgrade is available for this App Service Environment. + * + * @summary Send a test notification that an upgrade is available for this App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json + */ +async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "SampleHostingEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.testUpgradeAvailableNotification( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js index aef08404f9bf..70a96434adfd 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Update Custom Dns Suffix configuration of an App Service Environment * * @summary Update Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateAseCustomDnsSuffixConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAseCustomDnsSuffixConfiguration.json */ async function updateAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const customDnsSuffixConfiguration = { certificateUrl: "https://test-kv.vault.azure.net/secrets/contosocert", @@ -37,4 +39,8 @@ async function updateAseCustomDnsSuffixConfiguration() { console.log(result); } -updateAseCustomDnsSuffixConfiguration().catch(console.error); +async function main() { + updateAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js index 4df96b8a1dc7..6c047bf44275 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Update networking configuration of an App Service Environment * * @summary Description for Update networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json */ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const aseNetworkingConfiguration = { ftpEnabled: true, @@ -35,4 +37,8 @@ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { console.log(result); } -updateNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); +async function main() { + updateNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js index 59e0ed49bed3..ce6594cd7429 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateMultiRolePoolSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a multi-role pool. * * @summary Description for Create or update a multi-role pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json */ async function createOrUpdateAMultiRolePool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const multiRolePoolEnvelope = { workerCount: 3, @@ -35,4 +37,8 @@ async function createOrUpdateAMultiRolePool() { console.log(result); } -createOrUpdateAMultiRolePool().catch(console.error); +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateSample.js index 54eb7c03b569..c415bb22f7d8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Update.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Update.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope = { frontEndScaleFactor: 20, @@ -37,4 +39,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js index 9b2bd0e3e33b..7410269f18b3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpdateWorkerPoolSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a worker pool. * * @summary Description for Create or update a worker pool. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json */ async function getPropertiesOfAWorkerPool() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const workerPoolEnvelope = { @@ -37,4 +39,8 @@ async function getPropertiesOfAWorkerPool() { console.log(result); } -getPropertiesOfAWorkerPool().catch(console.error); +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpgradeSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpgradeSample.js new file mode 100644 index 000000000000..455777ef1c33 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServiceEnvironmentsUpgradeSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Initiate an upgrade of an App Service Environment if one is available. + * + * @summary Description for Initiate an upgrade of an App Service Environment if one is available. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Upgrade.json + */ +async function initiateAnUpgradeOnAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "SampleHostingEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginUpgradeAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + initiateAnUpgradeOnAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansCreateOrUpdateSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansCreateOrUpdateSample.js index a02cf08fc94b..6ce62be629c4 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates an App Service Plan. * * @summary Description for Creates or updates an App Service Plan. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateAppServicePlan.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateAppServicePlan.json */ async function createOrUpdateAppServicePlan() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsf6141"; const appServicePlan = { kind: "app", @@ -36,4 +38,8 @@ async function createOrUpdateAppServicePlan() { console.log(result); } -createOrUpdateAppServicePlan().catch(console.error); +async function main() { + createOrUpdateAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansDeleteSample.js new file mode 100644 index 000000000000..9c8fb684b996 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete an App Service plan. + * + * @summary Description for Delete an App Service plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAppServicePlan.json + */ +async function deleteAppServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansGetSample.js new file mode 100644 index 000000000000..eedad50cf292 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get an App Service plan. + * + * @summary Description for Get an App Service plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAppServicePlan.json + */ +async function getAppServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListByResourceGroupSample.js new file mode 100644 index 000000000000..42b6f1fb8e87 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all App Service plans in a resource group. + * + * @summary Description for Get all App Service plans in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlansByResourceGroup.json + */ +async function listAppServicePlansByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServicePlans.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppServicePlansByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListSample.js index dc4a1cfb7f57..984eeb638329 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/appServicePlansListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all App Service plans for a subscription. * * @summary Description for Get all App Service plans for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlans.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlans.json */ async function listAppServicePlans() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listAppServicePlans() { console.log(resArray); } -listAppServicePlans().catch(console.error); +async function main() { + listAppServicePlans(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansUpdateSample.js new file mode 100644 index 000000000000..717ec29c1591 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/appServicePlansUpdateSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates or updates an App Service Plan. + * + * @summary Description for Creates or updates an App Service Plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchAppServicePlan.json + */ +async function patchServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const appServicePlan = { kind: "app" }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.update(resourceGroupName, name, appServicePlan); + console.log(result); +} + +async function main() { + patchServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js index e0b6a336695d..829f8d04b1db 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.js @@ -10,16 +10,19 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. * * @summary Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json */ async function getAppServiceCertificateOrderDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const certificateOrderName = "SampleCertificateOrderName"; const detectorName = "AutoRenewStatus"; const credential = new DefaultAzureCredential(); @@ -33,4 +36,8 @@ async function getAppServiceCertificateOrderDetectorResponse() { console.log(result); } -getAppServiceCertificateOrderDetectorResponse().catch(console.error); +async function main() { + getAppServiceCertificateOrderDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js index 546a3001e633..6d2c6e2a4adf 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.js @@ -10,16 +10,19 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. * * @summary Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json */ async function listAppServiceCertificateDetectorResponse() { - const subscriptionId = "5700fc96-77b4-4f8d-afce-c353d8c443bd"; - const resourceGroupName = "Sample-WestUSResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; const certificateOrderName = "SampleCertificateOrderName"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +36,8 @@ async function listAppServiceCertificateDetectorResponse() { console.log(resArray); } -listAppServiceCertificateDetectorResponse().catch(console.error); +async function main() { + listAppServiceCertificateDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateRegistrationProviderListOperationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateRegistrationProviderListOperationsSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/certificateRegistrationProviderListOperationsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/certificateRegistrationProviderListOperationsSample.js index 71bc9601ad4e..b1be2aa6ac55 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificateRegistrationProviderListOperationsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificateRegistrationProviderListOperationsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesCreateOrUpdateSample.js new file mode 100644 index 000000000000..1a617dc82d11 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesCreateOrUpdateSample.js @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a certificate. + * + * @summary Description for Create or update a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateCertificate.json + */ +async function createOrUpdateCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const certificateEnvelope = { + hostNames: ["ServerCert"], + location: "East US", + password: "", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.createOrUpdate( + resourceGroupName, + name, + certificateEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesDeleteSample.js new file mode 100644 index 000000000000..2150cb75bc21 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete a certificate. + * + * @summary Description for Delete a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteCertificate.json + */ +async function deleteCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesGetSample.js new file mode 100644 index 000000000000..cb3eb61f825a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get a certificate. + * + * @summary Description for Get a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetCertificate.json + */ +async function getCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListByResourceGroupSample.js new file mode 100644 index 000000000000..542827f1793b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all certificates in a resource group. + * + * @summary Description for Get all certificates in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificatesByResourceGroup.json + */ +async function listCertificatesByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.certificates.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listCertificatesByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListSample.js index 4466ca13004e..18c037c9b93d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/certificatesListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all certificates for a subscription. * * @summary Description for Get all certificates for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificates.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificates.json */ async function listCertificatesForSubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listCertificatesForSubscription() { console.log(resArray); } -listCertificatesForSubscription().catch(console.error); +async function main() { + listCertificatesForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesUpdateSample.js new file mode 100644 index 000000000000..862b68e302c5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/certificatesUpdateSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a certificate. + * + * @summary Description for Create or update a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchCertificate.json + */ +async function patchCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const certificateEnvelope = { + password: "", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.update(resourceGroupName, name, certificateEnvelope); + console.log(result); +} + +async function main() { + patchCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsCreateOrUpdateSample.js similarity index 82% rename from sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsCreateOrUpdateSample.js index b111d54bfc0a..89695387e64a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Create or update a Container App. * * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateContainerApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateContainerApp.json */ async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testcontainerApp0"; const containerAppEnvelope = { configuration: { ingress: { external: true, targetPort: 3000 } }, @@ -52,4 +54,8 @@ async function createOrUpdateContainerApp() { console.log(result); } -createOrUpdateContainerApp().catch(console.error); +async function main() { + createOrUpdateContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsDeleteSample.js new file mode 100644 index 000000000000..47c7b185de70 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete a Container App. + * + * @summary Description for Delete a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteContainerApp.json + */ +async function deleteContainerApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testWorkerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerApps.beginDeleteAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsGetSample.js new file mode 100644 index 000000000000..7464f65433e2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get the properties of a Container App. + * + * @summary Get the properties of a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetContainerApp.json + */ +async function getContainerApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testcontainerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerApps.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListByResourceGroupSample.js new file mode 100644 index 000000000000..546492204f82 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get the Container Apps in a given resource group. + * + * @summary Get the Container Apps in a given resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsByResourceGroup.json + */ +async function listContainerAppsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.containerApps.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListBySubscriptionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListBySubscriptionSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListBySubscriptionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListBySubscriptionSample.js index b142723e1ba2..e6d117c61ce7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListBySubscriptionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListBySubscriptionSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get the Container Apps in a given subscription. * * @summary Get the Container Apps in a given subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsBySubscription.json */ async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listContainerAppsByResourceGroup() { console.log(resArray); } -listContainerAppsByResourceGroup().catch(console.error); +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListSecretsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListSecretsSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListSecretsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListSecretsSample.js index 30505d226ea5..54e4cccb2e40 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsListSecretsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsListSecretsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to List secrets for a container app * * @summary List secrets for a container app - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppSecrets.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppSecrets.json */ async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "testcontainerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +28,8 @@ async function listContainerAppsSecrets() { console.log(result); } -listContainerAppsSecrets().catch(console.error); +async function main() { + listContainerAppsSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsActivateRevisionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsActivateRevisionSample.js new file mode 100644 index 000000000000..439f97bda664 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsActivateRevisionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Activates a revision for a Container App + * + * @summary Activates a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ActivateRevision.json + */ +async function activateContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.activateRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + activateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsDeactivateRevisionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsDeactivateRevisionSample.js new file mode 100644 index 000000000000..dcf749d8a35d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsDeactivateRevisionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Deactivates a revision for a Container App + * + * @summary Deactivates a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeactivateRevision.json + */ +async function deactivateContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.deactivateRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + deactivateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsGetRevisionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsGetRevisionSample.js new file mode 100644 index 000000000000..cb7a9fdc851c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsGetRevisionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get a revision of a Container App. + * + * @summary Get a revision of a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetRevision.json + */ +async function getContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.getRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + getContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsListRevisionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsListRevisionsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsListRevisionsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsListRevisionsSample.js index 9d8c157918a7..de4679341dde 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/containerAppsRevisionsListRevisionsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsListRevisionsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get the Revisions for a given Container App. * * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListRevisions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListRevisions.json */ async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const containerAppName = "testcontainerApp0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function listContainerAppRevisions() { console.log(resArray); } -listContainerAppRevisions().catch(console.error); +async function main() { + listContainerAppRevisions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsRestartRevisionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsRestartRevisionSample.js new file mode 100644 index 000000000000..f4ce5d12b706 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/containerAppsRevisionsRestartRevisionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Restarts a revision for a Container App + * + * @summary Restarts a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestartRevision.json + */ +async function restartContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testStaticSite0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.restartRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + restartContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js index 04dd45e43afc..b6f373d2ce2c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsGetDeletedWebAppByLocationSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription at location. * * @summary Description for Get deleted app for a subscription at location. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppByLocation.json */ async function getDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); @@ -27,4 +29,8 @@ async function getDeletedWebAppByLocation() { console.log(result); } -getDeletedWebAppByLocation().catch(console.error); +async function main() { + getDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsListByLocationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsListByLocationSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsListByLocationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsListByLocationSample.js index b632e868bf6f..1940cbade4c3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/deletedWebAppsListByLocationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/deletedWebAppsListByLocationSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription at location * * @summary Description for Get all deleted apps for a subscription at location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListDeletedWebAppsByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListDeletedWebAppsByLocation.json */ async function listDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -29,4 +31,8 @@ async function listDeletedWebAppByLocation() { console.log(resArray); } -listDeletedWebAppByLocation().catch(console.error); +async function main() { + listDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSample.js new file mode 100644 index 000000000000..d9a198abcefd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json + */ +async function executeSiteAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + */ +async function executeSiteSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js new file mode 100644 index 000000000000..9d34efb9f986 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteAnalysisSlotSample.js @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json + */ +async function executeSiteAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + */ +async function executeSiteSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSample.js new file mode 100644 index 000000000000..7b0b014d69f2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json + */ +async function executeSiteDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetector( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + */ +async function executeSiteSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetector( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory + ); + console.log(result); +} + +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSlotSample.js new file mode 100644 index 000000000000..787a3dde0b14 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsExecuteSiteDetectorSlotSample.js @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json + */ +async function executeSiteDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetectorSlot( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + */ +async function executeSiteSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetectorSlot( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory, + slot + ); + console.log(result); +} + +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js new file mode 100644 index 000000000000..7348bd8b45f6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetHostingEnvironmentDetectorResponseSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Hosting Environment Detector Response + * + * @summary Description for Get Hosting Environment Detector Response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json + */ +async function getAppServiceEnvironmentDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAppServiceEnvironment"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getHostingEnvironmentDetectorResponse( + resourceGroupName, + name, + detectorName + ); + console.log(result); +} + +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSample.js new file mode 100644 index 000000000000..115af5ec60ad --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json + */ +async function getAppAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json + */ +async function getAppSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSlotSample.js new file mode 100644 index 000000000000..148df24e7c82 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteAnalysisSlotSample.js @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json + */ +async function getAppAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json + */ +async function getAppSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSample.js new file mode 100644 index 000000000000..e666d9c7e29f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSample.js @@ -0,0 +1,66 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json + */ +async function getAppDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponse( + resourceGroupName, + siteName, + detectorName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + */ +async function getAppSlotDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponse( + resourceGroupName, + siteName, + detectorName + ); + console.log(result); +} + +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js new file mode 100644 index 000000000000..8aa4d9806339 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorResponseSlotSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json + */ +async function getAppDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponseSlot( + resourceGroupName, + siteName, + detectorName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + */ +async function getAppSlotDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponseSlot( + resourceGroupName, + siteName, + detectorName, + slot + ); + console.log(result); +} + +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSample.js new file mode 100644 index 000000000000..7e260f92cfe7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json + */ +async function getAppDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetector( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json + */ +async function getAppSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetector( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName + ); + console.log(result); +} + +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSlotSample.js new file mode 100644 index 000000000000..83d0699a1859 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDetectorSlotSample.js @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json + */ +async function getAppDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorSlot( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json + */ +async function getAppSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorSlot( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName, + slot + ); + console.log(result); +} + +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySample.js new file mode 100644 index 000000000000..dfd0316b263f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySample.js @@ -0,0 +1,66 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + */ +async function getAppDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategory( + resourceGroupName, + siteName, + diagnosticCategory + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + */ +async function getAppSlotDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategory( + resourceGroupName, + siteName, + diagnosticCategory + ); + console.log(result); +} + +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js new file mode 100644 index 000000000000..4e904ade9f8c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsGetSiteDiagnosticCategorySlotSample.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + */ +async function getAppDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategorySlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + */ +async function getAppSlotDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategorySlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + ); + console.log(result); +} + +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js new file mode 100644 index 000000000000..246c7eefda70 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListHostingEnvironmentDetectorResponsesSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List Hosting Environment Detector Responses + * + * @summary Description for List Hosting Environment Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json + */ +async function getAppServiceEnvironmentDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAppServiceEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listHostingEnvironmentDetectorResponses( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSample.js new file mode 100644 index 000000000000..bc6f9645109b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSample.js @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json + */ +async function listAppAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalyses( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json + */ +async function listAppSlotAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalyses( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSlotSample.js new file mode 100644 index 000000000000..52d4b329aa33 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteAnalysesSlotSample.js @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json + */ +async function listAppAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalysesSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json + */ +async function listAppSlotAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalysesSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSample.js new file mode 100644 index 000000000000..b2893d6bdb37 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSample.js @@ -0,0 +1,68 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json + */ +async function getAppDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponses( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + */ +async function getAppSlotDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponses( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js new file mode 100644 index 000000000000..f7b1b5b38f74 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorResponsesSlotSample.js @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json + */ +async function getAppDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + */ +async function getAppSlotDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSample.js new file mode 100644 index 000000000000..15e623c47e78 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSample.js @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json + */ +async function listAppDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectors( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json + */ +async function listAppSlotDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectors( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSlotSample.js new file mode 100644 index 000000000000..aecced181b4b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDetectorsSlotSample.js @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json + */ +async function listAppDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorsSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json + */ +async function listAppSlotDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorsSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js new file mode 100644 index 000000000000..e08ab2aa5a21 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSample.js @@ -0,0 +1,68 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + */ +async function listAppDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategories( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + */ +async function listAppSlotDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategories( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js new file mode 100644 index 000000000000..9f415f8cc600 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/diagnosticsListSiteDiagnosticCategoriesSlotSample.js @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + */ +async function listAppDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + */ +async function listAppSlotDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainRegistrationProviderListOperationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainRegistrationProviderListOperationsSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainRegistrationProviderListOperationsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainRegistrationProviderListOperationsSample.js index 56a74bbe3413..6e3c5c3d3316 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainRegistrationProviderListOperationsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainRegistrationProviderListOperationsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCheckAvailabilitySample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCheckAvailabilitySample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsCheckAvailabilitySample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsCheckAvailabilitySample.js index 7d2e2b6cf3f4..e1064e925814 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCheckAvailabilitySample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCheckAvailabilitySample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Check if a domain is available for registration. * * @summary Description for Check if a domain is available for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CheckDomainAvailability.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CheckDomainAvailability.json */ async function checkDomainAvailability() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const identifier = { name: "abcd.com" }; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +28,8 @@ async function checkDomainAvailability() { console.log(result); } -checkDomainAvailability().catch(console.error); +async function main() { + checkDomainAvailability(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js index cd8c0f96919c..073fcb1b4ccb 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateOwnershipIdentifierSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomainOwnershipIdentifier.json */ async function createAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier = { @@ -36,4 +38,8 @@ async function createAppServiceDomainOwnershipIdentifier() { console.log(result); } -createAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + createAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateSample.js similarity index 89% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateSample.js index d98a8a6c7d21..8cf2bdda8d14 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomain.json */ async function createAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain = { authCode: "exampleAuthCode", @@ -112,4 +114,8 @@ async function createAppServiceDomain() { console.log(result); } -createAppServiceDomain().catch(console.error); +async function main() { + createAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteOwnershipIdentifierSample.js new file mode 100644 index 000000000000..bd05081dfddc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteOwnershipIdentifierSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete ownership identifier for domain + * + * @summary Description for Delete ownership identifier for domain + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json + */ +async function deleteAppServiceDomainOwnershipIdentifier() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const name = "ownershipIdentifier"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.deleteOwnershipIdentifier( + resourceGroupName, + domainName, + name + ); + console.log(result); +} + +async function main() { + deleteAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteSample.js new file mode 100644 index 000000000000..fd9248e1f31a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsDeleteSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete a domain. + * + * @summary Description for Delete a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomain.json + */ +async function deleteAppServiceDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const forceHardDeleteDomain = true; + const options = { forceHardDeleteDomain }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.delete(resourceGroupName, domainName, options); + console.log(result); +} + +async function main() { + deleteAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetControlCenterSsoRequestSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetControlCenterSsoRequestSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetControlCenterSsoRequestSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetControlCenterSsoRequestSample.js index a1ed7bce23df..68cd3627a084 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsGetControlCenterSsoRequestSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetControlCenterSsoRequestSample.js @@ -10,19 +10,25 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Generate a single sign-on request for the domain management portal. * * @summary Description for Generate a single sign-on request for the domain management portal. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainControlCenterSsoRequest.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainControlCenterSsoRequest.json */ async function getDomainControlCenterSsoRequest() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const result = await client.domains.getControlCenterSsoRequest(); console.log(result); } -getDomainControlCenterSsoRequest().catch(console.error); +async function main() { + getDomainControlCenterSsoRequest(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetOwnershipIdentifierSample.js new file mode 100644 index 000000000000..a3ff3354abc1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetOwnershipIdentifierSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get ownership identifier for domain + * + * @summary Description for Get ownership identifier for domain + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainOwnershipIdentifier.json + */ +async function getDomainOwnershipIdentifier() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const name = "SampleOwnershipId"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.getOwnershipIdentifier(resourceGroupName, domainName, name); + console.log(result); +} + +async function main() { + getDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetSample.js new file mode 100644 index 000000000000..5abfe7145e3e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get a domain. + * + * @summary Description for Get a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomain.json + */ +async function getDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.get(resourceGroupName, domainName); + console.log(result); +} + +async function main() { + getDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListByResourceGroupSample.js new file mode 100644 index 000000000000..2c1229eb4819 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all domains in a resource group. + * + * @summary Description for Get all domains in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsByResourceGroup.json + */ +async function listDomainsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.domains.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDomainsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListOwnershipIdentifiersSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListOwnershipIdentifiersSample.js new file mode 100644 index 000000000000..02226b881be3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListOwnershipIdentifiersSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Lists domain ownership identifiers. + * + * @summary Description for Lists domain ownership identifiers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainOwnershipIdentifiers.json + */ +async function listDomainOwnershipIdentifiers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.domains.listOwnershipIdentifiers(resourceGroupName, domainName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDomainOwnershipIdentifiers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListRecommendationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListRecommendationsSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsListRecommendationsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsListRecommendationsSample.js index ec9ca1e8b53d..269064c2b386 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListRecommendationsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListRecommendationsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get domain name recommendations based on keywords. * * @summary Description for Get domain name recommendations based on keywords. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainRecommendations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainRecommendations.json */ async function listDomainRecommendations() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters = { keywords: "example1", maxDomainRecommendations: 10, @@ -32,4 +34,8 @@ async function listDomainRecommendations() { console.log(resArray); } -listDomainRecommendations().catch(console.error); +async function main() { + listDomainRecommendations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsListSample.js index 5f35e03a7cb6..cab4429e2ff7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all domains in a subscription. * * @summary Description for Get all domains in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsBySubscription.json */ async function listDomainsBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listDomainsBySubscription() { console.log(resArray); } -listDomainsBySubscription().catch(console.error); +async function main() { + listDomainsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsRenewSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsRenewSample.js new file mode 100644 index 000000000000..0562e891a455 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsRenewSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Renew a domain. + * + * @summary Description for Renew a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/RenewDomain.json + */ +async function renewAnExistingDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "RG"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.renew(resourceGroupName, domainName); + console.log(result); +} + +async function main() { + renewAnExistingDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/domainsTransferOutSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsTransferOutSample.js new file mode 100644 index 000000000000..51fe4d6deb27 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsTransferOutSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Transfer out domain to another registrar + * + * @summary Transfer out domain to another registrar + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/TransferOutDomain.json + */ +async function transferOutDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.transferOut(resourceGroupName, domainName); + console.log(result); +} + +async function main() { + transferOutDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateOwnershipIdentifierSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateOwnershipIdentifierSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateOwnershipIdentifierSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateOwnershipIdentifierSample.js index c421188fd45f..d24b5dad7c87 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateOwnershipIdentifierSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateOwnershipIdentifierSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json */ async function updateAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier = { @@ -36,4 +38,8 @@ async function updateAppServiceDomainOwnershipIdentifier() { console.log(result); } -updateAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + updateAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateSample.js similarity index 88% rename from sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateSample.js index eab4da705116..4be315c96434 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/domainsUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/domainsUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomain.json */ async function updateAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain = { authCode: "exampleAuthCode", @@ -106,4 +108,8 @@ async function updateAppServiceDomain() { console.log(result); } -updateAppServiceDomain().catch(console.error); +async function main() { + updateAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSample.js index 256658dbba12..163b84ca2e73 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription. * * @summary Description for Get deleted app for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebApp.json */ async function getDeletedWebApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +28,8 @@ async function getDeletedWebApp() { console.log(result); } -getDeletedWebApp().catch(console.error); +async function main() { + getDeletedWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSnapshotsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSnapshotsSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSnapshotsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSnapshotsSample.js index 96683c419327..5af68ebb7e80 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetDeletedWebAppSnapshotsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetDeletedWebAppSnapshotsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription. * * @summary Description for Get all deleted apps for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppSnapshots.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppSnapshots.json */ async function getDeletedWebAppSnapshots() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +28,8 @@ async function getDeletedWebAppSnapshots() { console.log(result); } -getDeletedWebAppSnapshots().catch(console.error); +async function main() { + getDeletedWebAppSnapshots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js index cddf16e6e6a1..1b17dd4f462c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/globalGetSubscriptionOperationWithAsyncResponseSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets an operation in a subscription and given region * * @summary Description for Gets an operation in a subscription and given region - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSubscriptionOperationWithAsyncResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSubscriptionOperationWithAsyncResponse.json */ async function getsAnOperationInASubscriptionAndGivenRegion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US"; const operationId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab5d5"; const credential = new DefaultAzureCredential(); @@ -30,4 +32,8 @@ async function getsAnOperationInASubscriptionAndGivenRegion() { console.log(result); } -getsAnOperationInASubscriptionAndGivenRegion().catch(console.error); +async function main() { + getsAnOperationInASubscriptionAndGivenRegion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsCreateOrUpdateSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsCreateOrUpdateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsCreateOrUpdateSample.js index f24efa7d150f..fce379964a21 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsCreateOrUpdateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsCreateOrUpdateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. * * @summary Description for Creates or updates a Kubernetes Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_CreateOrUpdate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_CreateOrUpdate.json */ async function createKubeEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; const name = "testkubeenv"; const kubeEnvironmentEnvelope = { location: "East US", @@ -35,4 +37,8 @@ async function createKubeEnvironments() { console.log(result); } -createKubeEnvironments().catch(console.error); +async function main() { + createKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsDeleteSample.js new file mode 100644 index 000000000000..b1ee75cb1129 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Delete a Kubernetes Environment. + * + * @summary Description for Delete a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Delete.json + */ +async function deleteKubeEnvironmentByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "examplekenv"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.beginDeleteAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteKubeEnvironmentByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsGetSample.js new file mode 100644 index 000000000000..f127b9c0a57e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get the properties of a Kubernetes Environment. + * + * @summary Description for Get the properties of a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Get.json + */ +async function getKubeEnvironmentsByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "jlaw-demo1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getKubeEnvironmentsByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListByResourceGroupSample.js new file mode 100644 index 000000000000..c88370d455c3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all the Kubernetes Environments in a resource group. + * + * @summary Description for Get all the Kubernetes Environments in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListByResourceGroup.json + */ +async function listKubeEnvironmentsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.kubeEnvironments.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listKubeEnvironmentsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListBySubscriptionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListBySubscriptionSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListBySubscriptionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListBySubscriptionSample.js index 6331e0934e7e..83e8456f0c7c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/kubeEnvironmentsListBySubscriptionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsListBySubscriptionSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all Kubernetes Environments for a subscription. * * @summary Description for Get all Kubernetes Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListBySubscription.json */ async function listKubeEnvironmentsBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listKubeEnvironmentsBySubscription() { console.log(resArray); } -listKubeEnvironmentsBySubscription().catch(console.error); +async function main() { + listKubeEnvironmentsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsUpdateSample.js new file mode 100644 index 000000000000..50c2ca68758e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/kubeEnvironmentsUpdateSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. + * + * @summary Description for Creates or updates a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Update.json + */ +async function updateKubeEnvironments() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "testkubeenv"; + const kubeEnvironmentEnvelope = { + staticIp: "1.2.3.4", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.update( + resourceGroupName, + name, + kubeEnvironmentEnvelope + ); + console.log(result); +} + +async function main() { + updateKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/listCustomHostNameSitesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/listCustomHostNameSitesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/listCustomHostNameSitesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/listCustomHostNameSitesSample.js index 9d5d2b258915..c431ee07e6c0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/listCustomHostNameSitesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/listCustomHostNameSitesSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomHostNameSites.json */ async function getCustomHostnamesUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,16 +30,15 @@ async function getCustomHostnamesUnderSubscription() { console.log(resArray); } -getCustomHostnamesUnderSubscription().catch(console.error); - /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomSpecificHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomSpecificHostNameSites.json */ async function getSpecificCustomHostnameUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const hostname = "www.example.com"; const options = { hostname }; const credential = new DefaultAzureCredential(); @@ -49,4 +50,9 @@ async function getSpecificCustomHostnameUnderSubscription() { console.log(resArray); } -getSpecificCustomHostnameUnderSubscription().catch(console.error); +async function main() { + getCustomHostnamesUnderSubscription(); + getSpecificCustomHostnameUnderSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/package.json b/sdk/appservice/arm-appservice/samples/v14/javascript/package.json similarity index 100% rename from sdk/appservice/arm-appservice/samples/v13/javascript/package.json rename to sdk/appservice/arm-appservice/samples/v14/javascript/package.json diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksForLocationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksForLocationSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksForLocationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksForLocationSample.js index 1752defa3b56..1c6459742e98 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksForLocationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksForLocationSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions for location * * @summary Description for Get available Function app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacksForLocation.json */ async function getLocationsFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -29,4 +31,8 @@ async function getLocationsFunctionAppStacks() { console.log(resArray); } -getLocationsFunctionAppStacks().catch(console.error); +async function main() { + getLocationsFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksSample.js index 7c789b9e94c9..85ae57ae4848 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetFunctionAppStacksSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetFunctionAppStacksSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions * * @summary Description for Get available Function app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacks.json */ async function getFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function getFunctionAppStacks() { console.log(resArray); } -getFunctionAppStacks().catch(console.error); +async function main() { + getFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksForLocationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksForLocationSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksForLocationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksForLocationSample.js index 3d2775ba6f21..2970e484e3ac 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksForLocationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksForLocationSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions for location * * @summary Description for Get available Web app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacksForLocation.json */ async function getLocationsWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -29,4 +31,8 @@ async function getLocationsWebAppStacks() { console.log(resArray); } -getLocationsWebAppStacks().catch(console.error); +async function main() { + getLocationsWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksSample.js index 7d39be726232..08a7b099829e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/providerGetWebAppStacksSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/providerGetWebAppStacksSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions * * @summary Description for Get available Web app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacks.json */ async function getWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function getWebAppStacks() { console.log(resArray); } -getWebAppStacks().catch(console.error); +async function main() { + getWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/providerListOperationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/providerListOperationsSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/providerListOperationsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/providerListOperationsSample.js index ce9c6b8bcd3d..743b06d0eece 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/providerListOperationsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/providerListOperationsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions * * @summary Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSample.js new file mode 100644 index 000000000000..c20d150e50e4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json + */ +async function getResourceHealthMetadata() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.resourceHealthMetadataOperations.getBySite(resourceGroupName, name); + console.log(result); +} + +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSlotSample.js new file mode 100644 index 000000000000..45cf62688975 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataGetBySiteSlotSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json + */ +async function getResourceHealthMetadata() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.resourceHealthMetadataOperations.getBySiteSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListByResourceGroupSample.js new file mode 100644 index 000000000000..c18d3e867e1d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListByResourceGroupSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. + * + * @summary Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataByResourceGroup.json + */ +async function listResourceHealthMetadataForAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.resourceHealthMetadataOperations.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listResourceHealthMetadataForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSample.js new file mode 100644 index 000000000000..634f76e7d5e4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json + */ +async function listResourceHealthMetadataForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.resourceHealthMetadataOperations.listBySite( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSlotSample.js index 85da96eec662..2368182ffecb 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListBySiteSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListBySiteSlotSample.js @@ -10,16 +10,19 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection * * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json */ async function listResourceHealthMetadataForASite() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; - const resourceGroupName = "Default-Web-NorthCentralUS"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; const name = "newsiteinnewASE-NCUS"; const slot = "Production"; const credential = new DefaultAzureCredential(); @@ -35,4 +38,8 @@ async function listResourceHealthMetadataForASite() { console.log(resArray); } -listResourceHealthMetadataForASite().catch(console.error); +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListSample.js index 49120d96176a..678578e79cec 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/resourceHealthMetadataListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/resourceHealthMetadataListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the subscription. * * @summary Description for List all ResourceHealthMetadata for all sites in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySubscription.json */ async function listResourceHealthMetadataForASubscription() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "4adb32ad-8327-4cbb-b775-b84b4465bb38"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listResourceHealthMetadataForASubscription() { console.log(resArray); } -listResourceHealthMetadataForASubscription().catch(console.error); +async function main() { + listResourceHealthMetadataForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/sample.env b/sdk/appservice/arm-appservice/samples/v14/javascript/sample.env similarity index 100% rename from sdk/appservice/arm-appservice/samples/v13/javascript/sample.env rename to sdk/appservice/arm-appservice/samples/v14/javascript/sample.env diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js index f2d710445a30..91868a58b34c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesApproveOrRejectPrivateEndpointConnectionSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper = { @@ -40,4 +42,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBasicAuthSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBasicAuthSample.js new file mode 100644 index 000000000000..75844e32eb2f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBasicAuthSample.js @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Adds or updates basic auth for a static site. + * + * @summary Description for Adds or updates basic auth for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBasicAuth.json + */ +async function createsOrUpdatesBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const basicAuthEnvelope = { + applicableEnvironmentsMode: "AllEnvironments", + environments: [], + password: "**********************", + secretUrl: undefined, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBasicAuth( + resourceGroupName, + name, + basicAuthName, + basicAuthEnvelope + ); + console.log(result); +} + +async function main() { + createsOrUpdatesBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.js new file mode 100644 index 000000000000..8db943057b69 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.js @@ -0,0 +1,52 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateDatabaseConnectionSample.js new file mode 100644 index 000000000000..73d4a8a88e13 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateDatabaseConnectionSample.js @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js index 683eeb02de93..c37ce010370f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates the app settings of a static site. * * @summary Description for Creates or updates the app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteAppSettings.json */ async function createsOrUpdatesTheAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const appSettings = { properties: { setting1: "someval", setting2: "someval2" }, @@ -34,4 +36,8 @@ async function createsOrUpdatesTheAppSettingsOfAStaticSite() { console.log(result); } -createsOrUpdatesTheAppSettingsOfAStaticSite().catch(console.error); +async function main() { + createsOrUpdatesTheAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js index 38263c1a31bc..625e955c1e91 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates the app settings of a static site build. * * @summary Description for Creates or updates the app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings = { @@ -36,4 +38,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js index b6897ff6c81d..b229bc58575c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates the function app settings of a static site build. * * @summary Description for Creates or updates the function app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings = { @@ -36,4 +38,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js index 4a063dfc289b..5cbfe400635c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates a new static site custom domain in an existing resource group and static site. * * @summary Description for Creates a new static site custom domain in an existing resource group and static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteCustomDomain.json */ async function createOrUpdateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope = {}; @@ -34,4 +36,8 @@ async function createOrUpdateACustomDomainForAStaticSite() { console.log(result); } -createOrUpdateACustomDomainForAStaticSite().catch(console.error); +async function main() { + createOrUpdateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js index 5be33dc2fa5a..8125bb70da94 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates or updates the function app settings of a static site. * * @summary Description for Creates or updates the function app settings of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const appSettings = { properties: { setting1: "someval", setting2: "someval2" }, @@ -34,4 +36,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSite().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteSample.js index a2182a97213a..7ff7ecf7ab55 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateOrUpdateStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateOrUpdateStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSite.json */ async function createOrUpdateAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope = { branch: "master", @@ -43,4 +45,8 @@ async function createOrUpdateAStaticSite() { console.log(result); } -createOrUpdateAStaticSite().catch(console.error); +async function main() { + createOrUpdateAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateUserRolesInvitationLinkSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateUserRolesInvitationLinkSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateUserRolesInvitationLinkSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateUserRolesInvitationLinkSample.js index bc36260f2221..41b287c849c8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateUserRolesInvitationLinkSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateUserRolesInvitationLinkSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates an invitation link for a user with the role * * @summary Description for Creates an invitation link for a user with the role - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateUserRolesInvitationLink.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateUserRolesInvitationLink.json */ async function createAnInvitationLinkForAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteUserRolesInvitationEnvelope = { domain: "happy-sea-15afae3e.azurestaticwebsites.net", @@ -38,4 +40,8 @@ async function createAnInvitationLinkForAUserForAStaticSite() { console.log(result); } -createAnInvitationLinkForAUserForAStaticSite().catch(console.error); +async function main() { + createAnInvitationLinkForAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js index a4ef5b80c150..54773453843e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Deploys zipped content to a specific environment of a static site. * * @summary Description for Deploys zipped content to a specific environment of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteBuildZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteBuildZipDeploy.json */ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const staticSiteZipDeploymentEnvelope = { @@ -42,4 +44,8 @@ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { console.log(result); } -deployASiteFromAZippedPackageToAParticularStaticSiteBuild().catch(console.error); +async function main() { + deployASiteFromAZippedPackageToAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js index d0c280eaec40..c3617fff703b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesCreateZipDeploymentForStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Deploys zipped content to a static site. * * @summary Description for Deploys zipped content to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteZipDeploy.json */ async function deployASiteFromAZippedPackage() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteZipDeploymentEnvelope = { apiZipUrl: @@ -40,4 +42,8 @@ async function deployASiteFromAZippedPackage() { console.log(result); } -deployASiteFromAZippedPackage().catch(console.error); +async function main() { + deployASiteFromAZippedPackage(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteBuildDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteBuildDatabaseConnectionSample.js new file mode 100644 index 000000000000..dc61d031b673 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteBuildDatabaseConnectionSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site build + * + * @summary Delete a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuildDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteDatabaseConnectionSample.js new file mode 100644 index 000000000000..2c1c99259b02 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteDatabaseConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site + * + * @summary Delete a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeletePrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeletePrivateEndpointConnectionSample.js new file mode 100644 index 000000000000..1eea3a1ed8e4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeletePrivateEndpointConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json + */ +async function deleteAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeletePrivateEndpointConnectionAndWait( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteBuildSample.js new file mode 100644 index 000000000000..2af1ac93a4bf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteBuildSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a static site build. + * + * @summary Description for Deletes a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuild.json + */ +async function deleteAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteBuildAndWait( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + deleteAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js new file mode 100644 index 000000000000..d4ef8750a949 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteCustomDomainSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a custom domain. + * + * @summary Description for Deletes a custom domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteCustomDomain.json + */ +async function deleteACustomDomainForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const domainName = "custom.domain.net"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteCustomDomainAndWait( + resourceGroupName, + name, + domainName + ); + console.log(result); +} + +async function main() { + deleteACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteSample.js new file mode 100644 index 000000000000..e04fd37e2179 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a static site. + * + * @summary Description for Deletes a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSite.json + */ +async function deleteAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteUserSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteUserSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteUserSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteUserSample.js index 23d476e24c3c..2bd5e1b6ab76 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDeleteStaticSiteUserSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDeleteStaticSiteUserSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Deletes the user entry from the static site. * * @summary Description for Deletes the user entry from the static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteStaticSiteUser.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteUser.json */ async function deleteAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "aad"; const userid = "1234"; @@ -34,4 +36,8 @@ async function deleteAUserForAStaticSite() { console.log(result); } -deleteAUserForAStaticSite().catch(console.error); +async function main() { + deleteAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachStaticSiteSample.js new file mode 100644 index 000000000000..a0ff28632fc6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachStaticSiteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Detaches a static site. + * + * @summary Description for Detaches a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachStaticSite.json + */ +async function detachAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDetachStaticSiteAndWait(resourceGroupName, name); + console.log(result); +} + +async function main() { + detachAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js index 0e20b8a0babe..2d772083213d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Detach the user provided function app from the static site build * * @summary Description for Detach the user provided function app from the static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json */ async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const functionAppName = "testFunctionApp"; @@ -34,4 +36,8 @@ async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { console.log(result); } -detachTheUserProvidedFunctionAppFromTheStaticSiteBuild().catch(console.error); +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js new file mode 100644 index 000000000000..dd1c502a2683 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Detach the user provided function app from the static site + * + * @summary Description for Detach the user provided function app from the static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json + */ +async function detachTheUserProvidedFunctionAppFromTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const functionAppName = "testFunctionApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSite( + resourceGroupName, + name, + functionAppName + ); + console.log(result); +} + +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBasicAuthSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBasicAuthSample.js new file mode 100644 index 000000000000..8d82759e54ae --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBasicAuthSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site. + * + * @summary Description for Gets the basic auth properties for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBasicAuth.json + */ +async function getsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBasicAuth(resourceGroupName, name, basicAuthName); + console.log(result); +} + +async function main() { + getsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionSample.js new file mode 100644 index 000000000000..27da78937e1e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site build by name + * + * @summary Returns overview of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionWithDetailsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionWithDetailsSample.js new file mode 100644 index 000000000000..6c224ec91dd6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionWithDetailsSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site build by name + * + * @summary Returns details of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnectionWithDetails( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsSample.js new file mode 100644 index 000000000000..39e92fccd632 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site build + * + * @summary Returns overviews of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnections( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.js new file mode 100644 index 000000000000..d2d0f42aae88 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site build + * + * @summary Returns details of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnectionsWithDetails( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionSample.js new file mode 100644 index 000000000000..0a66b7cc054d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site by name + * + * @summary Returns overview of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionWithDetailsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionWithDetailsSample.js new file mode 100644 index 000000000000..1700171a28a6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionWithDetailsSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site by name + * + * @summary Returns details of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnectionWithDetails( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsSample.js new file mode 100644 index 000000000000..97139b6b4f59 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site + * + * @summary Returns overviews of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnections(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsWithDetailsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsWithDetailsSample.js new file mode 100644 index 000000000000..3d213cd1f42e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetDatabaseConnectionsWithDetailsSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site + * + * @summary Returns details of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnectionsWithDetails( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendForBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendForBuildSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendForBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendForBuildSample.js index 32ae666942f9..8c8fe7dd302d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetLinkedBackendForBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendForBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Returns the details of a linked backend linked to a static site build by name * * @summary Returns the details of a linked backend linked to a static site build by name - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetLinkedBackendForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSiteBuild.json */ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -34,4 +36,8 @@ async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName( console.log(result); } -getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName().catch(console.error); +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendSample.js new file mode 100644 index 000000000000..093237c9a43d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns the details of a linked backend linked to a static site by name + * + * @summary Returns the details of a linked backend linked to a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSite.json + */ +async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getLinkedBackend( + resourceGroupName, + name, + linkedBackendName + ); + console.log(result); +} + +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsForBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsForBuildSample.js new file mode 100644 index 000000000000..062329fe820e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsForBuildSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of all backends linked to a static site build + * + * @summary Returns details of all backends linked to a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSiteBuild.json + */ +async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listLinkedBackendsForBuild( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsSample.js new file mode 100644 index 000000000000..4744fe21f192 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetLinkedBackendsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Returns details of all backends linked to a static site + * + * @summary Returns details of all backends linked to a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSite.json + */ +async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listLinkedBackends(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionListSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionListSample.js index 10a9358585de..31c26824b0c1 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetPrivateEndpointConnectionListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionListSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the list of private endpoint connections associated with a static site * * @summary Description for Gets the list of private endpoint connections associated with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSitePrivateEndpointConnectionList.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionList.json */ async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { console.log(resArray); } -getAListOfPrivateEndpointConnectionsAssociatedWithASite().catch(console.error); +async function main() { + getAListOfPrivateEndpointConnectionsAssociatedWithASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionSample.js new file mode 100644 index 000000000000..42e617f3a88a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateEndpointConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getPrivateEndpointConnection( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateLinkResourcesSample.js new file mode 100644 index 000000000000..9aea973ec996 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetPrivateLinkResourcesSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getPrivateLinkResources(resourceGroupName, name); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildSample.js new file mode 100644 index 000000000000..ae86481e934f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the details of a static site build. + * + * @summary Description for Gets the details of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuild.json + */ +async function getAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSiteBuild( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildsSample.js new file mode 100644 index 000000000000..0f704cd12cc7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteBuildsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets all static site builds for a particular static site. + * + * @summary Description for Gets all static site builds for a particular static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuilds.json + */ +async function getAllBuildsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteBuilds(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllBuildsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteCustomDomainSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteCustomDomainSample.js new file mode 100644 index 000000000000..e18792982cfe --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteCustomDomainSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets an existing custom domain for a particular static site. + * + * @summary Description for Gets an existing custom domain for a particular static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomain.json + */ +async function getCustomDomainForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const domainName = "custom.domain.net"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSiteCustomDomain( + resourceGroupName, + name, + domainName + ); + console.log(result); +} + +async function main() { + getCustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteSample.js new file mode 100644 index 000000000000..49ab0de49a83 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSiteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the details of a static site. + * + * @summary Description for Gets the details of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSite.json + */ +async function getDetailsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSite(resourceGroupName, name); + console.log(result); +} + +async function main() { + getDetailsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSitesByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSitesByResourceGroupSample.js new file mode 100644 index 000000000000..782e94525592 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetStaticSitesByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets all static sites in the specified resource group. + * + * @summary Description for Gets all static sites in the specified resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSites.json + */ +async function getStaticSitesForAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSitesByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getStaticSitesForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js index 01f562d1e7ad..0441ba3735df 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site build * * @summary Description for Gets the details of the user provided function app registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json */ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const functionAppName = "testFunctionApp"; @@ -34,4 +36,8 @@ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBu console.log(result); } -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild().catch(console.error); +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js index 1d9c1310e849..ce024978f90a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site * * @summary Description for Gets the details of the user provided function app registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSite.json */ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() console.log(result); } -getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite().catch(console.error); +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js index 2b4e45ed1cdd..81ebc5350cf4 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site build * * @summary Description for Gets the details of the user provided function apps registered with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json */ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteB console.log(resArray); } -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild().catch(console.error); +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js index 047f734f1595..e8910e791c2a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site * * @summary Description for Gets the details of the user provided function apps registered with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetUserProvidedFunctionAppsForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSite.json */ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite( console.log(resArray); } -getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite().catch(console.error); +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendSample.js index 9ab4b277712b..41c68e47a1ec 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Link backend to a static site * * @summary Link backend to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSite.json */ async function linkABackendToAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope = { @@ -38,4 +40,8 @@ async function linkABackendToAStaticSite() { console.log(result); } -linkABackendToAStaticSite().catch(console.error); +async function main() { + linkABackendToAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendToBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendToBuildSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendToBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendToBuildSample.js index 2b418e3fed5a..38de39d774d7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesLinkBackendToBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesLinkBackendToBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Link backend to a static site build * * @summary Link backend to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSiteBuild.json */ async function linkABackendToAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -40,4 +42,8 @@ async function linkABackendToAStaticSiteBuild() { console.log(result); } -linkABackendToAStaticSiteBuild().catch(console.error); +async function main() { + linkABackendToAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListBasicAuthSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListBasicAuthSample.js new file mode 100644 index 000000000000..09eab47a75d4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListBasicAuthSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site as a collection. + * + * @summary Description for Gets the basic auth properties for a static site as a collection. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBasicAuth.json + */ +async function listsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBasicAuth(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListSample.js index da4dbb191b31..4ab3b5978f1d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all Static Sites for a subscription. * * @summary Description for Get all Static Sites for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAllStaticSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAllStaticSites.json */ async function getAllStaticSitesInASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function getAllStaticSitesInASubscription() { console.log(resArray); } -getAllStaticSitesInASubscription().catch(console.error); +async function main() { + getAllStaticSitesInASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteAppSettingsSample.js new file mode 100644 index 000000000000..32a1dcc6a802 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteAppSettingsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site. + * + * @summary Description for Gets the application settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteAppSettings.json + */ +async function getAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteAppSettings(resourceGroupName, name); + console.log(result); +} + +async function main() { + getAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js new file mode 100644 index 000000000000..fc9450659097 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildAppSettingsSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site build. + * + * @summary Description for Gets the application settings of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildAppSettings.json + */ +async function getAppSettingsOfAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteBuildAppSettings( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js new file mode 100644 index 000000000000..603ffa4185ca --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionAppSettingsSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site build. + * + * @summary Description for Gets the application settings of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctionAppSettings.json + */ +async function getFunctionAppSettingsOfAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteBuildFunctionAppSettings( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionsSample.js index 6504b1387e67..b32ec8341d16 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteBuildFunctionsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteBuildFunctionsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the functions of a particular static site build. * * @summary Description for Gets the functions of a particular static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteBuildFunctions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctions.json */ async function getsTheFunctionsOfAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function getsTheFunctionsOfAParticularStaticSiteBuild() { console.log(resArray); } -getsTheFunctionsOfAParticularStaticSiteBuild().catch(console.error); +async function main() { + getsTheFunctionsOfAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteConfiguredRolesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteConfiguredRolesSample.js new file mode 100644 index 000000000000..89b42efbd6ed --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteConfiguredRolesSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Lists the roles configured for the static site. + * + * @summary Description for Lists the roles configured for the static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteConfiguredRoles.json + */ +async function listsTheConfiguredRolesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteConfiguredRoles(resourceGroupName, name); + console.log(result); +} + +async function main() { + listsTheConfiguredRolesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteCustomDomainsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteCustomDomainsSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteCustomDomainsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteCustomDomainsSample.js index 76dba71cd644..7f6ce542cc90 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteCustomDomainsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteCustomDomainsSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets all static site custom domains for a particular static site. * * @summary Description for Gets all static site custom domains for a particular static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetStaticSiteCustomDomains.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomains.json */ async function listCustomDomainsForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -30,4 +32,8 @@ async function listCustomDomainsForAStaticSite() { console.log(resArray); } -listCustomDomainsForAStaticSite().catch(console.error); +async function main() { + listCustomDomainsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js new file mode 100644 index 000000000000..2b369009e2b2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionAppSettingsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site. + * + * @summary Description for Gets the application settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctionAppSettings.json + */ +async function getFunctionAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteFunctionAppSettings( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionsSample.js new file mode 100644 index 000000000000..20cd52db96cc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteFunctionsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the functions of a static site. + * + * @summary Description for Gets the functions of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctions.json + */ +async function getsTheFunctionsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteFunctions(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getsTheFunctionsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteSecretsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteSecretsSample.js new file mode 100644 index 000000000000..04a757d72d39 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteSecretsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Lists the secrets for an existing static site. + * + * @summary Description for Lists the secrets for an existing static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteSecrets.json + */ +async function listSecretsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteSecrets(resourceGroupName, name); + console.log(result); +} + +async function main() { + listSecretsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteUsersSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteUsersSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteUsersSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteUsersSample.js index c36cddac4707..63ba28709c7b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesListStaticSiteUsersSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesListStaticSiteUsersSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets the list of users of a static site. * * @summary Description for Gets the list of users of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListStaticSiteUsers.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteUsers.json */ async function listUsersForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "all"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function listUsersForAStaticSite() { console.log(resArray); } -listUsersForAStaticSite().catch(console.error); +async function main() { + listUsersForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesPreviewWorkflowSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesPreviewWorkflowSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesPreviewWorkflowSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesPreviewWorkflowSample.js index 8cb6be36d7d4..365b46bf69a0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesPreviewWorkflowSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesPreviewWorkflowSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Generates a preview workflow file for the static site * * @summary Description for Generates a preview workflow file for the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GenerateStaticSiteWorkflowPreview.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GenerateStaticSiteWorkflowPreview.json */ async function generatesAPreviewWorkflowFileForTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const staticSitesWorkflowPreviewRequest = { branch: "master", @@ -38,4 +40,8 @@ async function generatesAPreviewWorkflowFileForTheStaticSite() { console.log(result); } -generatesAPreviewWorkflowFileForTheStaticSite().catch(console.error); +async function main() { + generatesAPreviewWorkflowFileForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js index 954a4fad6bcd..47bd0a11221f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site build * * @summary Description for Register a user provided function app with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json */ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const functionAppName = "testFunctionApp"; @@ -46,4 +48,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSiteBuild().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js index 1443ac1c261c..6a74c8829d1d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site * * @summary Description for Register a user provided function app with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json */ async function registerAUserProvidedFunctionAppWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const isForced = true; @@ -43,4 +45,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSite() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSite().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesResetStaticSiteApiKeySample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesResetStaticSiteApiKeySample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesResetStaticSiteApiKeySample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesResetStaticSiteApiKeySample.js index 7b954cf91a6a..e3baa4ab78e3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesResetStaticSiteApiKeySample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesResetStaticSiteApiKeySample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Resets the api key for an existing static site. * * @summary Description for Resets the api key for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ResetStaticSiteApiKey.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ResetStaticSiteApiKey.json */ async function resetTheApiKeyForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const resetPropertiesEnvelope = { repositoryToken: "repoToken123", @@ -35,4 +37,8 @@ async function resetTheApiKeyForAStaticSite() { console.log(result); } -resetTheApiKeyForAStaticSite().catch(console.error); +async function main() { + resetTheApiKeyForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendFromBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendFromBuildSample.js new file mode 100644 index 000000000000..c26c704e4d54 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendFromBuildSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Unlink a backend from a static site build + * + * @summary Unlink a backend from a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSiteBuild.json + */ +async function unlinkABackendFromAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.unlinkBackendFromBuild( + resourceGroupName, + name, + environmentName, + linkedBackendName + ); + console.log(result); +} + +async function main() { + unlinkABackendFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendSample.js new file mode 100644 index 000000000000..cad50ded046d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUnlinkBackendSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Unlink a backend from a static site + * + * @summary Unlink a backend from a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSite.json + */ +async function unlinkABackendFromAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.unlinkBackend(resourceGroupName, name, linkedBackendName); + console.log(result); +} + +async function main() { + unlinkABackendFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateBuildDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateBuildDatabaseConnectionSample.js new file mode 100644 index 000000000000..66ce5ea86970 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateBuildDatabaseConnectionSample.js @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteBuildDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateDatabaseConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateDatabaseConnectionSample.js new file mode 100644 index 000000000000..efa6f701748f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateDatabaseConnectionSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteSample.js index cb12b9f90ff1..e9c43b516ed3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSite.json */ async function patchAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope = {}; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function patchAStaticSite() { console.log(result); } -patchAStaticSite().catch(console.error); +async function main() { + patchAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteUserSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteUserSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteUserSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteUserSample.js index ee05203c84e7..84542197c55e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesUpdateStaticSiteUserSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesUpdateStaticSiteUserSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Updates a user entry with the listed roles * * @summary Description for Updates a user entry with the listed roles - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateStaticSiteUser.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateStaticSiteUser.json */ async function createOrUpdateAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "aad"; const userid = "1234"; @@ -38,4 +40,8 @@ async function createOrUpdateAUserForAStaticSite() { console.log(result); } -createOrUpdateAUserForAStaticSite().catch(console.error); +async function main() { + createOrUpdateAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendForBuildSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendForBuildSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendForBuildSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendForBuildSample.js index 5965556e3fe9..76c65e4ad6d6 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendForBuildSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendForBuildSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site build * * @summary Validates that a backend can be linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSiteBuild.json */ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -40,4 +42,8 @@ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSiteBuild().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendSample.js index 5286215bdbd0..29422759edf0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateBackendSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateBackendSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site * * @summary Validates that a backend can be linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSite.json */ async function validateIfBackendCanBeLinkedToStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope = { @@ -38,4 +40,8 @@ async function validateIfBackendCanBeLinkedToStaticSite() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSite().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js index ff029209850d..f11372ab4e6f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Validates a particular custom domain can be added to a static site. * * @summary Description for Validates a particular custom domain can be added to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateStaticSiteCustomDomain.json */ async function validateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope = {}; @@ -34,4 +36,8 @@ async function validateACustomDomainForAStaticSite() { console.log(result); } -validateACustomDomainForAStaticSite().catch(console.error); +async function main() { + validateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsGetSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsGetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsGetSample.js index fb118ba3e587..6ba93ddf2bcf 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsGetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsGetSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get details of a top-level domain. * * @summary Description for Get details of a top-level domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetTopLevelDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetTopLevelDomain.json */ async function getTopLevelDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "com"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +28,8 @@ async function getTopLevelDomain() { console.log(result); } -getTopLevelDomain().catch(console.error); +async function main() { + getTopLevelDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListAgreementsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListAgreementsSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListAgreementsSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListAgreementsSample.js index ac8dd17918a4..07b7a44e7ddb 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListAgreementsSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListAgreementsSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets all legal agreements that user needs to accept before purchasing a domain. * * @summary Description for Gets all legal agreements that user needs to accept before purchasing a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomainAgreements.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomainAgreements.json */ async function listTopLevelDomainAgreements() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "in"; const agreementOption = { forTransfer: false, @@ -33,4 +35,8 @@ async function listTopLevelDomainAgreements() { console.log(resArray); } -listTopLevelDomainAgreements().catch(console.error); +async function main() { + listTopLevelDomainAgreements(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListSample.js index b543b51b6e94..14b1103df037 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/topLevelDomainsListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/topLevelDomainsListSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Get all top-level domains supported for registration. * * @summary Description for Get all top-level domains supported for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomains.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomains.json */ async function listTopLevelDomains() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +30,8 @@ async function listTopLevelDomains() { console.log(resArray); } -listTopLevelDomains().catch(console.error); +async function main() { + listTopLevelDomains(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/verifyHostingEnvironmentVnetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/verifyHostingEnvironmentVnetSample.js similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/javascript/verifyHostingEnvironmentVnetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/verifyHostingEnvironmentVnetSample.js index 43fe34c6584d..504c1769d720 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/verifyHostingEnvironmentVnetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/verifyHostingEnvironmentVnetSample.js @@ -10,15 +10,17 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. * * @summary Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/VerifyHostingEnvironmentVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/VerifyHostingEnvironmentVnet.json */ async function verifyHostingEnvironmentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters = { vnetName: "vNet123", vnetResourceGroup: "vNet123rg", @@ -30,4 +32,8 @@ async function verifyHostingEnvironmentVnet() { console.log(result); } -verifyHostingEnvironmentVnet().catch(console.error); +async function main() { + verifyHostingEnvironmentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSample.js new file mode 100644 index 000000000000..663e0948192d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostName.json + */ +async function analyzeCustomHostnameForWebapp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostname(resourceGroupName, name); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForWebapp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSlotSample.js new file mode 100644 index 000000000000..f6e765efb803 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsAnalyzeCustomHostnameSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostNameSlot.json + */ +async function analyzeCustomHostnameForSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostnameSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApplySlotConfigToProductionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApplySlotConfigToProductionSample.js new file mode 100644 index 000000000000..04e52b3f7dc3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApplySlotConfigToProductionSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Applies the configuration settings from the target slot onto the current slot. + * + * @summary Description for Applies the configuration settings from the target slot onto the current slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApplySlotConfig.json + */ +async function applyWebAppSlotConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slotSwapEntity = { + preserveVnet: true, + targetSlot: "staging", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.applySlotConfigToProduction( + resourceGroupName, + name, + slotSwapEntity + ); + console.log(result); +} + +async function main() { + applyWebAppSlotConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js index e237ef7cc5e6..5b9ca0f64bd6 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper = { @@ -40,4 +42,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js index 00899c4a819b..211c8deb864d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -42,4 +44,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsBackupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsBackupSample.js new file mode 100644 index 000000000000..c62f9b46de56 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsBackupSample.js @@ -0,0 +1,65 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates a backup of an app. + * + * @summary Description for Creates a backup of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/BackupWebApp.json + */ +async function backupWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const request = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z"), + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure", + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure", + }, + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.backup(resourceGroupName, name, request); + console.log(result); +} + +async function main() { + backupWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateConfigurationSample.js new file mode 100644 index 000000000000..1c8b009ca3b4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateConfigurationSample.js @@ -0,0 +1,87 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Updates the configuration of an app. + * + * @summary Description for Updates the configuration of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateSiteConfig.json + */ +async function updateSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteConfig = { + acrUseManagedIdentityCreds: false, + alwaysOn: false, + appCommandLine: "", + autoHealEnabled: false, + azureStorageAccounts: {}, + defaultDocuments: [ + "Default.htm", + "Default.html", + "Default.asp", + "index.htm", + "index.html", + "iisstart.htm", + "default.aspx", + "index.php", + "hostingstart.html", + ], + detailedErrorLoggingEnabled: false, + ftpsState: "AllAllowed", + functionAppScaleLimit: 0, + functionsRuntimeScaleMonitoringEnabled: false, + http20Enabled: false, + httpLoggingEnabled: false, + linuxFxVersion: "", + loadBalancing: "LeastRequests", + logsDirectorySizeLimit: 35, + managedPipelineMode: "Integrated", + minTlsVersion: "1.2", + minimumElasticInstanceCount: 0, + netFrameworkVersion: "v4.0", + nodeVersion: "", + numberOfWorkers: 1, + phpVersion: "5.6", + powerShellVersion: "", + pythonVersion: "", + remoteDebuggingEnabled: false, + requestTracingEnabled: false, + scmMinTlsVersion: "1.2", + use32BitWorkerProcess: true, + virtualApplications: [ + { physicalPath: "site\\wwwroot", preloadEnabled: false, virtualPath: "/" }, + ], + vnetName: "", + vnetPrivatePortsCount: 0, + vnetRouteAllEnabled: false, + webSocketsEnabled: false, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.createOrUpdateConfiguration( + resourceGroupName, + name, + siteConfig + ); + console.log(result); +} + +async function main() { + updateSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSample.js new file mode 100644 index 000000000000..440cc1f5536d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSample.js @@ -0,0 +1,84 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebApp.json + */ +async function cloneWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478", + sourceWebAppLocation: "West Europe", + }, + kind: "app", + location: "East US", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebApp.json + */ +async function createOrUpdateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebApp(); + createOrUpdateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSlotSample.js new file mode 100644 index 000000000000..5d02ef4d39cb --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsCreateOrUpdateSlotSample.js @@ -0,0 +1,88 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebAppSlot.json + */ +async function cloneWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478/slot/qa", + sourceWebAppLocation: "West Europe", + }, + kind: "app", + location: "East US", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebAppSlot.json + */ +async function createOrUpdateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebAppSlot(); + createOrUpdateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteBackupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteBackupSample.js new file mode 100644 index 000000000000..385318a8bb88 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteBackupSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a backup of an app by its ID. + * + * @summary Description for Deletes a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppBackup.json + */ +async function deleteWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteBackup(resourceGroupName, name, backupId); + console.log(result); +} + +async function main() { + deleteWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSample.js new file mode 100644 index 000000000000..d3b6391a8006 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json + */ +async function deleteAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginDeletePrivateEndpointConnectionAndWait( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js index e1835d363a62..a7715c53d859 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeletePrivateEndpointConnectionSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Deletes a private endpoint connection * * @summary Description for Deletes a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/DeleteSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnectionSlot.json */ async function deleteAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -34,4 +36,8 @@ async function deleteAPrivateEndpointConnectionForASite() { console.log(result); } -deleteAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSample.js new file mode 100644 index 000000000000..432992372bcd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebApp.json + */ +async function deleteWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSlotSample.js new file mode 100644 index 000000000000..59e39321463a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeleteSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppSlot.json + */ +async function deleteWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + deleteWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSample.js new file mode 100644 index 000000000000..d0ddbdfa2919 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSample.js @@ -0,0 +1,107 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteDeployWorkflowArtifacts.json + */ +async function deleteWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts = { + filesToDelete: ["test/workflow.json", "test/"], + }; + const options = { + workflowArtifacts, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts(resourceGroupName, name, options); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifacts.json + */ +async function deploysWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=", + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')", + }, + serviceProvider: { id: "/serviceProviders/eventHub" }, + }, + }, + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub", + }, + }, + splitOn: "@triggerOutputs()?['body']", + }, + }, + }, + kind: "Stateful", + }, + }, + }; + const options = { + workflowArtifacts, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts(resourceGroupName, name, options); + console.log(result); +} + +async function main() { + deleteWorkflowArtifacts(); + deploysWorkflowArtifacts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSlotSample.js new file mode 100644 index 000000000000..9dd6778a36c6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsDeployWorkflowArtifactsSlotSample.js @@ -0,0 +1,89 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifactsSlot.json + */ +async function deploysWorkflowArtifactsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "testsSlot"; + const workflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=", + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')", + }, + serviceProvider: { id: "/serviceProviders/eventHub" }, + }, + }, + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub", + }, + }, + splitOn: "@triggerOutputs()?['body']", + }, + }, + }, + kind: "Stateful", + }, + }, + }; + const options = { + workflowArtifacts, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifactsSlot( + resourceGroupName, + name, + slot, + options + ); + console.log(result); +} + +async function main() { + deploysWorkflowArtifactsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js new file mode 100644 index 000000000000..457969783455 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the config reference and status of an app + * + * @summary Description for Gets the config reference and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSetting.json + */ +async function getAzureKeyVaultAppSettingReference() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const appSettingKey = "setting"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAppSettingKeyVaultReference( + resourceGroupName, + name, + appSettingKey + ); + console.log(result); +} + +async function main() { + getAzureKeyVaultAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js new file mode 100644 index 000000000000..04651b11db3d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingKeyVaultReferenceSlotSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the config reference and status of an app + * + * @summary Description for Gets the config reference and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingSlot.json + */ +async function getAzureKeyVaultSlotAppSettingReference() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const appSettingKey = "setting"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAppSettingKeyVaultReferenceSlot( + resourceGroupName, + name, + appSettingKey, + slot + ); + console.log(result); +} + +async function main() { + getAzureKeyVaultSlotAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js new file mode 100644 index 000000000000..fc040739211c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the config reference app settings and status of an app + * + * @summary Description for Gets the config reference app settings and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettings.json + */ +async function getAzureKeyVaultReferencesForAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listAppSettingsKeyVaultReferences( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAzureKeyVaultReferencesForAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js new file mode 100644 index 000000000000..690af16cd3a3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAppSettingsKeyVaultReferencesSlotSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the config reference app settings and status of an app + * + * @summary Description for Gets the config reference app settings and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json + */ +async function getAzureKeyVaultReferencesForAppSettingsForSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listAppSettingsKeyVaultReferencesSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAzureKeyVaultReferencesForAppSettingsForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsSample.js new file mode 100644 index 000000000000..7686b6357485 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the Authentication/Authorization settings of an app. + * + * @summary Description for Gets the Authentication/Authorization settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettings.json + */ +async function listAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettings(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2Sample.js new file mode 100644 index 000000000000..a834657ec868 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2Sample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettingsV2.json + */ +async function listAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2WithoutSecretsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2WithoutSecretsSample.js new file mode 100644 index 000000000000..aed8ead30163 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetAuthSettingsV2WithoutSecretsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAuthSettingsV2WithoutSecrets.json + */ +async function listAuthSettingsWithoutSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2WithoutSecrets(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAuthSettingsWithoutSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetBackupStatusSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetBackupStatusSample.js new file mode 100644 index 000000000000..41c27b63749e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetBackupStatusSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets a backup of an app by its ID. + * + * @summary Description for Gets a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackup.json + */ +async function getWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getBackupStatus(resourceGroupName, name, backupId); + console.log(result); +} + +async function main() { + getWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetConfigurationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetConfigurationSample.js new file mode 100644 index 000000000000..6f21f41974b2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetConfigurationSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * + * @summary Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteConfig.json + */ +async function getSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getConfiguration(resourceGroupName, name); + console.log(result); +} + +async function main() { + getSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSample.js new file mode 100644 index 000000000000..ead0ef72b1f8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. + * + * @summary Description for Returns whether FTP is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json + */ +async function getFtpAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getFtpAllowed(resourceGroupName, name); + console.log(result); +} + +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSlotSample.js new file mode 100644 index 000000000000..e68eaafd9860 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetFtpAllowedSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. + * + * @summary Description for Returns whether FTP is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json + */ +async function getFtpAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getFtpAllowedSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSample.js new file mode 100644 index 000000000000..783be4e5cdc2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets all scale-out instances of an app. + * + * @summary Description for Gets all scale-out instances of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json + */ +async function getSiteInstanceInfo() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const instanceId = "134987120"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceInfo(resourceGroupName, name, instanceId); + console.log(result); +} + +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSlotSample.js new file mode 100644 index 000000000000..901c9646194c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceInfoSlotSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets all scale-out instances of an app. + * + * @summary Description for Gets all scale-out instances of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json + */ +async function getSiteInstanceInfo() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const instanceId = "134987120"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceInfoSlot( + resourceGroupName, + name, + instanceId, + slot + ); + console.log(result); +} + +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceWorkflowSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceWorkflowSlotSample.js new file mode 100644 index 000000000000..d6fe96e6bb5f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetInstanceWorkflowSlotSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflowSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceWorkflowSlot( + resourceGroupName, + name, + slot, + workflowName + ); + console.log(result); +} + +async function main() { + getAWorkflowSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSample.js index 8a123d269a6b..bc2b3aa2c221 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotSample.js index 0cd04ee64677..7e4f9a06f39b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +36,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js index 0a81c9779592..a07c53e0502a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationSlotV2Sample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +36,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationV2Sample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationV2Sample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationV2Sample.js index 5bdb9ede52e7..15b463468d08 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTraceOperationV2Sample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTraceOperationV2Sample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json */ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getTheCurrentStatusOfANetworkTraceOperationForASite() { console.log(result); } -getTheCurrentStatusOfANetworkTraceOperationForASite().catch(console.error); +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSample.js index 57b65b2d3379..b826a3e93c2e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -28,4 +30,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotSample.js index d77bf78fc117..c34a9bab9ec9 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +36,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotV2Sample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotV2Sample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotV2Sample.js index c664153f30d3..cc2a5d3b64ef 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesSlotV2Sample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesSlotV2Sample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const slot = "Production"; @@ -34,4 +36,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesV2Sample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesV2Sample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesV2Sample.js index 8e288a21580f..3b7cd36d7807 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetNetworkTracesV2Sample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetNetworkTracesV2Sample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). * * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebSiteNetworkTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json */ async function getNetworkTracesForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; const credential = new DefaultAzureCredential(); @@ -28,4 +30,8 @@ async function getNetworkTracesForASite() { console.log(result); } -getNetworkTracesForASite().catch(console.error); +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSample.js new file mode 100644 index 000000000000..9d53343e1cad --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateEndpointConnection( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js new file mode 100644 index 000000000000..77ad81a5ae55 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateEndpointConnectionSlotSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionSlot.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateEndpointConnectionSlot( + resourceGroupName, + name, + privateEndpointConnectionName, + slot + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSample.js new file mode 100644 index 000000000000..c78d00337fc3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateLinkResources(resourceGroupName, name); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSlotSample.js new file mode 100644 index 000000000000..201cad071611 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetPrivateLinkResourcesSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResourcesSlot.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateLinkResourcesSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetProductionSiteDeploymentStatusSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetProductionSiteDeploymentStatusSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetProductionSiteDeploymentStatusSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetProductionSiteDeploymentStatusSample.js index 9f8c41cf1d30..51007fc3a79a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetProductionSiteDeploymentStatusSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetProductionSiteDeploymentStatusSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). * * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatus.json */ async function getDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; const credential = new DefaultAzureCredential(); @@ -32,4 +34,8 @@ async function getDeploymentStatus() { console.log(result); } -getDeploymentStatus().catch(console.error); +async function main() { + getDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSample.js new file mode 100644 index 000000000000..9670d036f506 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebApp.json + */ +async function getWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSample.js new file mode 100644 index 000000000000..daf8b2b1afc8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. + * + * @summary Description for Returns whether Scm basic auth is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json + */ +async function getScmAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getScmAllowed(resourceGroupName, name); + console.log(result); +} + +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSlotSample.js new file mode 100644 index 000000000000..8e73ca570152 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetScmAllowedSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. + * + * @summary Description for Returns whether Scm basic auth is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json + */ +async function getScmAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getScmAllowedSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSample.js new file mode 100644 index 000000000000..ceffdc703360 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppSlot.json + */ +async function getWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js index 9a29a1d1a934..8a2a1f2a0cd0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetSlotSiteDeploymentStatusSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). * * @summary Gets the deployment status for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSiteDeploymentStatusSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatusSlot.json */ async function getDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; @@ -34,4 +36,8 @@ async function getDeploymentStatusSlot() { console.log(result); } -getDeploymentStatusSlot().catch(console.error); +async function main() { + getDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetWorkflowSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetWorkflowSample.js new file mode 100644 index 000000000000..8bb2aa0f00d5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsGetWorkflowSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflow() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getWorkflow(resourceGroupName, name, workflowName); + console.log(result); +} + +async function main() { + getAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListApplicationSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListApplicationSettingsSample.js new file mode 100644 index 000000000000..5a56cf01f375 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListApplicationSettingsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of an app. + * + * @summary Description for Gets the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppSettings.json + */ +async function listAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listApplicationSettings(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupStatusSecretsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupStatusSecretsSample.js new file mode 100644 index 000000000000..e4d0519540ad --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupStatusSecretsSample.js @@ -0,0 +1,71 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * + * @summary Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackupWithSecrets.json + */ +async function getWebAppBackupWithSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const request = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z"), + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure", + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure", + }, + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listBackupStatusSecrets( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + getWebAppBackupWithSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupsSample.js new file mode 100644 index 000000000000..65601465199c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBackupsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppBackups.json + */ +async function listWebAppBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listBackups(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js index 85c83add6c5e..dcdc522f657d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. * * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPolicies.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPolicies.json */ async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function listPublishingCredentialsPolicies() { console.log(resArray); } -listPublishingCredentialsPolicies().catch(console.error); +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js index 3749b9e46557..168c2fb77617 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListBasicPublishingCredentialsPoliciesSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. * * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListPublishingCredentialsPoliciesSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPoliciesSlot.json */ async function listPublishingCredentialsPolicies() { - const subscriptionId = "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "testsite"; const slot = "staging"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function listPublishingCredentialsPolicies() { console.log(resArray); } -listPublishingCredentialsPolicies().catch(console.error); +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListByResourceGroupSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListByResourceGroupSample.js new file mode 100644 index 000000000000..0c72ded9a5e6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListByResourceGroupSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets all web, mobile, and API apps in the specified resource group. + * + * @summary Description for Gets all web, mobile, and API apps in the specified resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppsByResourceGroup.json + */ +async function listWebAppsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listByResourceGroup(resourceGroupName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListConfigurationsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListConfigurationsSample.js new file mode 100644 index 000000000000..05ea759b9e67 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListConfigurationsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for List the configurations of an app + * + * @summary Description for List the configurations of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppConfigurations.json + */ +async function listWebAppConfigurations() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listConfigurations(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppConfigurations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListInstanceWorkflowsSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListInstanceWorkflowsSlotSample.js new file mode 100644 index 000000000000..2318e40fd2de --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListInstanceWorkflowsSlotSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflowsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listInstanceWorkflowsSlot(resourceGroupName, name, slot)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflowsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListProductionSiteDeploymentStatusesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListProductionSiteDeploymentStatusesSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListProductionSiteDeploymentStatusesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListProductionSiteDeploymentStatusesSample.js index 71dff09117b6..dab07789bc7f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListProductionSiteDeploymentStatusesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListProductionSiteDeploymentStatusesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). * * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatus.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatus.json */ async function listDeploymentStatus() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -33,4 +35,8 @@ async function listDeploymentStatus() { console.log(resArray); } -listDeploymentStatus().catch(console.error); +async function main() { + listDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSample.js new file mode 100644 index 000000000000..c3e577dd3b85 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Get all apps for a subscription. + * + * @summary Description for Get all apps for a subscription. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebApps.json + */ +async function listWebAppsForSubscription() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.list()) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSample.js new file mode 100644 index 000000000000..ef7b6c47a7cf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json + */ +async function listBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSiteBackups(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSlotSample.js new file mode 100644 index 000000000000..10f554533055 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSiteBackupsSlotSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json + */ +async function listBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSiteBackupsSlot(resourceGroupName, name, slot)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js index 42bdcc9448c2..a27fc628878d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotSiteDeploymentStatusesSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). * * @summary List deployment statuses for an app (or deployment slot, if specified). - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListSiteDeploymentStatusSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatusSlot.json */ async function listDeploymentStatusSlot() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const credential = new DefaultAzureCredential(); @@ -35,4 +37,8 @@ async function listDeploymentStatusSlot() { console.log(resArray); } -listDeploymentStatusSlot().catch(console.error); +async function main() { + listDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotsSample.js new file mode 100644 index 000000000000..6e7ee15562fc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListSlotsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Gets an app's deployment slots. + * + * @summary Description for Gets an app's deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppSlots.json + */ +async function listWebAppSlots() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSlots(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppSlots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSample.js new file mode 100644 index 000000000000..dbcaf75acdb3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnections() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnections(resourceGroupName, name); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnections(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSlotSample.js new file mode 100644 index 000000000000..c6d9d1ec7c8b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsConnectionsSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnectionsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnectionsSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnectionsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsSample.js new file mode 100644 index 000000000000..8dd290465717 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsListWorkflowsSample.js @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflows() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listWorkflows(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflows(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsRestoreSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsRestoreSample.js new file mode 100644 index 000000000000..38497bfb66a4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsRestoreSample.js @@ -0,0 +1,64 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Restores a specific backup to another app (or deployment slot, if specified). + * + * @summary Description for Restores a specific backup to another app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestoreWebAppBackup.json + */ +async function restoreWebAppFromBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "123244"; + const request = { + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure", + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure", + }, + ], + overwrite: true, + siteName: "sitef6141", + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginRestoreAndWait( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + restoreWebAppFromBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSample.js new file mode 100644 index 000000000000..543776341808 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSample.js @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Start capturing network packets for the site. + * + * @summary Description for Start capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json + */ +async function startANewNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const durationInSeconds = 60; + const options = { durationInSeconds }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginStartNetworkTraceAndWait( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSlotSample.js index 138bcd10321f..75e8ac17743c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartNetworkTraceSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartNetworkTraceSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const slot = "Production"; @@ -37,4 +39,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js new file mode 100644 index 000000000000..c6248a50438f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSample.js @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Start capturing network packets for the site. + * + * @summary Description for Start capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json + */ +async function startANewNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const durationInSeconds = 60; + const options = { + durationInSeconds, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginStartWebSiteNetworkTraceOperationAndWait( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js index 37855ccaf00a..d2a373d72e6e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStartWebSiteNetworkTraceOperationSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const slot = "Production"; @@ -37,4 +39,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSample.js new file mode 100644 index 000000000000..bbe1c9bac347 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopNetworkTrace(resourceGroupName, name); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSlotSample.js new file mode 100644 index 000000000000..1a690f112cd1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopNetworkTraceSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopNetworkTraceSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSample.js new file mode 100644 index 000000000000..72507b1d2746 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSample.js @@ -0,0 +1,36 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopWebSiteNetworkTrace(resourceGroupName, name); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js new file mode 100644 index 000000000000..37a45b272f02 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsStopWebSiteNetworkTraceSlotSample.js @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopWebSiteNetworkTraceSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateApplicationSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateApplicationSettingsSample.js new file mode 100644 index 000000000000..ed6230ac9f3e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateApplicationSettingsSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Replaces the application settings of an app. + * + * @summary Description for Replaces the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAppSettings.json + */ +async function updateAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const appSettings = { + properties: { setting1: "Value1", setting2: "Value2" }, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateApplicationSettings( + resourceGroupName, + name, + appSettings + ); + console.log(result); +} + +async function main() { + updateAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsSample.js new file mode 100644 index 000000000000..1c3d5f0653e1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsSample.js @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Updates the Authentication / Authorization settings associated with web app. + * + * @summary Description for Updates the Authentication / Authorization settings associated with web app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettings.json + */ +async function updateAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettings = { + allowedExternalRedirectUrls: ["sitef6141.customdomain.net", "sitef6141.customdomain.info"], + clientId: "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + defaultProvider: "Google", + enabled: true, + runtimeVersion: "~1", + tokenRefreshExtensionHours: 120, + tokenStoreEnabled: true, + unauthenticatedClientAction: "RedirectToLoginPage", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettings(resourceGroupName, name, siteAuthSettings); + console.log(result); +} + +async function main() { + updateAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsV2Sample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsV2Sample.js new file mode 100644 index 000000000000..fab695024633 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAuthSettingsV2Sample.js @@ -0,0 +1,87 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettingsV2.json + */ +async function updateAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettingsV2 = { + globalValidation: { + excludedPaths: ["/nosecrets/Path"], + requireAuthentication: true, + unauthenticatedClientAction: "Return403", + }, + httpSettings: { + forwardProxy: { + convention: "Standard", + customHostHeaderName: "authHeader", + customProtoHeaderName: "customProtoHeader", + }, + requireHttps: true, + routes: { apiPrefix: "/authv2/" }, + }, + identityProviders: { + google: { + enabled: true, + login: { scopes: ["admin"] }, + registration: { + clientId: "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + clientSecretSettingName: "ClientSecret", + }, + validation: { allowedAudiences: ["https://example.com"] }, + }, + }, + login: { + allowedExternalRedirectUrls: ["https://someurl.com"], + cookieExpiration: { + convention: "IdentityProviderDerived", + timeToExpiration: "2022:09-01T00:00Z", + }, + nonce: { validateNonce: true }, + preserveUrlFragmentsForLogins: true, + routes: { logoutEndpoint: "https://app.com/logout" }, + tokenStore: { + enabled: true, + fileSystem: { directory: "/wwwroot/sites/example" }, + tokenRefreshExtensionHours: 96, + }, + }, + platform: { + configFilePath: "/auth/config.json", + enabled: true, + runtimeVersion: "~1", + }, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettingsV2( + resourceGroupName, + name, + siteAuthSettingsV2 + ); + console.log(result); +} + +async function main() { + updateAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAzureStorageAccountsSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAzureStorageAccountsSample.js new file mode 100644 index 000000000000..d456180bf350 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateAzureStorageAccountsSample.js @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Updates the Azure storage account configurations of an app. + * + * @summary Description for Updates the Azure storage account configurations of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAzureStorageAccounts.json + */ +async function updateAzureStorageAccounts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const azureStorageAccounts = { + properties: { + account1: { + type: "AzureFiles", + accessKey: "26515^%@#*", + accountName: "testsa", + mountPath: "/mounts/a/files", + shareName: "web", + }, + }, + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAzureStorageAccounts( + resourceGroupName, + name, + azureStorageAccounts + ); + console.log(result); +} + +async function main() { + updateAzureStorageAccounts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSample.js index 4ce91ec2538f..138dc24de3f1 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity = { allow: true, @@ -34,4 +36,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSlotSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSlotSample.js index f2f796c9b41a..ea95be158381 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateFtpAllowedSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateFtpAllowedSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity = { @@ -36,4 +38,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSample.js new file mode 100644 index 000000000000..484aab8bc999 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebApp.json + */ +async function updateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.update(resourceGroupName, name, siteEnvelope); + console.log(result); +} + +async function main() { + updateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSample.js index d3323b3e3b5b..fa45b240e17c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity = { allow: true, @@ -34,4 +36,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSlotSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSlotSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSlotSample.js index c7b310ba724c..8376d1158f7c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/webAppsUpdateScmAllowedSlotSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateScmAllowedSlotSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity = { @@ -36,4 +38,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSlotSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSlotSample.js new file mode 100644 index 000000000000..7154844cfa22 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/webAppsUpdateSlotSample.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebAppSlot.json + */ +async function updateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp", + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateSlot(resourceGroupName, name, slot, siteEnvelope); + console.log(result); +} + +async function main() { + updateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsGetSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsGetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsGetSample.js index d086371a92ef..da753cf2cff0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsGetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsGetSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get a workflow run action repetition. * * @summary Get a workflow run action repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_Get.json */ async function getARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -38,4 +40,8 @@ async function getARepetition() { console.log(result); } -getARepetition().catch(console.error); +async function main() { + getARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js index 7a8b70768daf..b41e5ab96bcb 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListExpressionTracesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Lists a workflow run expression trace. * * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json */ async function listExpressionTracesForARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -41,4 +43,8 @@ async function listExpressionTracesForARepetition() { console.log(resArray); } -listExpressionTracesForARepetition().catch(console.error); +async function main() { + listExpressionTracesForARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListSample.js index cead88f36f44..146d2cf8ae6c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsListSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get all of a workflow run action repetitions. * * @summary Get all of a workflow run action repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_List.json */ async function listRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +41,8 @@ async function listRepetitions() { console.log(resArray); } -listRepetitions().catch(console.error); +async function main() { + listRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js index 3fa902aa70ea..5bb2e6361fe7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesGetSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Gets a workflow run repetition request history. * * @summary Gets a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json */ async function getARepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -40,4 +42,8 @@ async function getARepetitionRequestHistory() { console.log(result); } -getARepetitionRequestHistory().catch(console.error); +async function main() { + getARepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js index 1e69043e5c7b..92fe7c77a776 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionRepetitionsRequestHistoriesListSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to List a workflow run repetition request history. * * @summary List a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json */ async function listRepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -41,4 +43,8 @@ async function listRepetitionRequestHistory() { console.log(resArray); } -listRepetitionRequestHistory().catch(console.error); +async function main() { + listRepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsGetSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsGetSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsGetSample.js index 964dca52525c..cfd261042cc8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsGetSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsGetSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Get a workflow run action scoped repetition. * * @summary Get a workflow run action scoped repetition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_Get.json */ async function getAScopedRepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -38,4 +40,8 @@ async function getAScopedRepetition() { console.log(result); } -getAScopedRepetition().catch(console.error); +async function main() { + getAScopedRepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsListSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsListSample.js index 0371d72a98bc..6aa8e6b6efc9 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionScopeRepetitionsListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionScopeRepetitionsListSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to List the workflow run action scoped repetitions. * * @summary List the workflow run action scoped repetitions. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionScopeRepetitions_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_List.json */ async function listTheScopedRepetitions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +41,8 @@ async function listTheScopedRepetitions() { console.log(resArray); } -listTheScopedRepetitions().catch(console.error); +async function main() { + listTheScopedRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsGetSample.js new file mode 100644 index 000000000000..982a9a34f74f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsGetSample.js @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a workflow run action. + * + * @summary Gets a workflow run action. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_Get.json + */ +async function getAWorkflowRunAction() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const actionName = "HTTP"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRunActions.get( + resourceGroupName, + name, + workflowName, + runName, + actionName + ); + console.log(result); +} + +async function main() { + getAWorkflowRunAction(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListExpressionTracesSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListExpressionTracesSample.js similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListExpressionTracesSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListExpressionTracesSample.js index 82c0268b4d97..f69943b9d94d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowRunActionsListExpressionTracesSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListExpressionTracesSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Lists a workflow run expression trace. * * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActions_ListExpressionTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_ListExpressionTraces.json */ async function listExpressionTraces() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -39,4 +41,8 @@ async function listExpressionTraces() { console.log(resArray); } -listExpressionTraces().catch(console.error); +async function main() { + listExpressionTraces(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListSample.js new file mode 100644 index 000000000000..1b10ff14814c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunActionsListSample.js @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a list of workflow run actions. + * + * @summary Gets a list of workflow run actions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_List.json + */ +async function listAWorkflowRunActions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRunActions.list( + resourceGroupName, + name, + workflowName, + runName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAWorkflowRunActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsCancelSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsCancelSample.js new file mode 100644 index 000000000000..636ac0030981 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsCancelSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Cancels a workflow run. + * + * @summary Cancels a workflow run. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Cancel.json + */ +async function cancelAWorkflowRun() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRuns.cancel(resourceGroupName, name, workflowName, runName); + console.log(result); +} + +async function main() { + cancelAWorkflowRun(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsGetSample.js new file mode 100644 index 000000000000..02ec63c2580f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsGetSample.js @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a workflow run. + * + * @summary Gets a workflow run. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Get.json + */ +async function getARunForAWorkflow() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRuns.get(resourceGroupName, name, workflowName, runName); + console.log(result); +} + +async function main() { + getARunForAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsListSample.js new file mode 100644 index 000000000000..67dc7a4b0c10 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowRunsListSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a list of workflow runs. + * + * @summary Gets a list of workflow runs. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_List.json + */ +async function listWorkflowRuns() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRuns.list(resourceGroupName, name, workflowName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWorkflowRuns(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesGetSample.js new file mode 100644 index 000000000000..a69601b7c0f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesGetSample.js @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a workflow trigger history. + * + * @summary Gets a workflow trigger history. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Get.json + */ +async function getAWorkflowTriggerHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const triggerName = "testTriggerName"; + const historyName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggerHistories.get( + resourceGroupName, + name, + workflowName, + triggerName, + historyName + ); + console.log(result); +} + +async function main() { + getAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesListSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesListSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesListSample.js index 7e106d7c66e1..3c3dd8ea06fa 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesListSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesListSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Gets a list of workflow trigger histories. * * @summary Gets a list of workflow trigger histories. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_List.json */ async function listAWorkflowTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const triggerName = "testTriggerName"; @@ -37,4 +39,8 @@ async function listAWorkflowTriggerHistory() { console.log(resArray); } -listAWorkflowTriggerHistory().catch(console.error); +async function main() { + listAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesResubmitSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesResubmitSample.js similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesResubmitSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesResubmitSample.js index 8def4e650334..d25cd121ae1b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowTriggerHistoriesResubmitSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggerHistoriesResubmitSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Resubmits a workflow run based on the trigger history. * * @summary Resubmits a workflow run based on the trigger history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowTriggerHistories_Resubmit.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Resubmit.json */ async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testWorkflowName"; const triggerName = "testTriggerName"; @@ -36,4 +38,8 @@ async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { console.log(result); } -resubmitAWorkflowRunBasedOnTheTriggerHistory().catch(console.error); +async function main() { + resubmitAWorkflowRunBasedOnTheTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSample.js new file mode 100644 index 000000000000..d3e6add7c36e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a workflow trigger. + * + * @summary Gets a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Get.json + */ +async function getAWorkflowTrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "manual"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.get( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSchemaJsonSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSchemaJsonSample.js new file mode 100644 index 000000000000..6a7c6d05e7ab --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersGetSchemaJsonSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get the trigger schema as JSON. + * + * @summary Get the trigger schema as JSON. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_GetSchemaJson.json + */ +async function getTriggerSchema() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflow"; + const triggerName = "testTrigger"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.getSchemaJson( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getTriggerSchema(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListCallbackUrlSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListCallbackUrlSample.js new file mode 100644 index 000000000000..e6009cd0810d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListCallbackUrlSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Get the callback URL for a workflow trigger. + * + * @summary Get the callback URL for a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_ListCallbackUrl.json + */ +async function getTheCallbackUrlForATrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "manual"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.listCallbackUrl( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getTheCallbackUrlForATrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListSample.js new file mode 100644 index 000000000000..88460b85ccf7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersListSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a list of workflow triggers. + * + * @summary Gets a list of workflow triggers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_List.json + */ +async function listWorkflowTriggers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowTriggers.list(resourceGroupName, name, workflowName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWorkflowTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersRunSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersRunSample.js new file mode 100644 index 000000000000..f4614fc878f6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowTriggersRunSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Runs a workflow trigger. + * + * @summary Runs a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Run.json + */ +async function runAWorkflowTrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "recurrence"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.beginRunAndWait( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + runAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsGetSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsGetSample.js new file mode 100644 index 000000000000..c72ffa66d4de --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsGetSample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a workflow version. + * + * @summary Gets a workflow version. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_Get.json + */ +async function getAWorkflowVersion() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const versionId = "08586676824806722526"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowVersions.get( + resourceGroupName, + name, + workflowName, + versionId + ); + console.log(result); +} + +async function main() { + getAWorkflowVersion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsListSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsListSample.js new file mode 100644 index 000000000000..1aa2a96bbc96 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowVersionsListSample.js @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Gets a list of workflow versions. + * + * @summary Gets a list of workflow versions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_List.json + */ +async function listAWorkflowsVersions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowVersions.list(resourceGroupName, name, workflowName)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAWorkflowsVersions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsRegenerateAccessKeySample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsRegenerateAccessKeySample.js new file mode 100644 index 000000000000..6120ee6a3504 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsRegenerateAccessKeySample.js @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); + +/** + * This sample demonstrates how to Regenerates the callback URL access key for request triggers. + * + * @summary Regenerates the callback URL access key for request triggers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_RegenerateAccessKey.json + */ +async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const keyType = { keyType: "Primary" }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflows.regenerateAccessKey( + resourceGroupName, + name, + workflowName, + keyType + ); + console.log(result); +} + +async function main() { + regenerateTheCallbackUrlAccessKeyForRequestTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsValidateSample.js b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsValidateSample.js similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/javascript/workflowsValidateSample.js rename to sdk/appservice/arm-appservice/samples/v14/javascript/workflowsValidateSample.js index 59a1192c2495..f20162080329 100644 --- a/sdk/appservice/arm-appservice/samples/v13/javascript/workflowsValidateSample.js +++ b/sdk/appservice/arm-appservice/samples/v14/javascript/workflowsValidateSample.js @@ -10,16 +10,18 @@ // Licensed under the MIT License. const { WebSiteManagementClient } = require("@azure/arm-appservice"); const { DefaultAzureCredential } = require("@azure/identity"); +require("dotenv").config(); /** * This sample demonstrates how to Validates the workflow definition. * * @summary Validates the workflow definition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_Validate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_Validate.json */ async function validateAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const validate = { @@ -40,4 +42,8 @@ async function validateAWorkflow() { console.log(result); } -validateAWorkflow().catch(console.error); +async function main() { + validateAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/README.md b/sdk/appservice/arm-appservice/samples/v14/typescript/README.md new file mode 100644 index 000000000000..aa1cd6142a06 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/README.md @@ -0,0 +1,751 @@ +# client library samples for TypeScript + +These sample programs show how to use the TypeScript client libraries for in some common scenarios. + +| **File Name** | **Description** | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| [appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts][appservicecertificateorderscreateorupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificate.json | +| [appServiceCertificateOrdersCreateOrUpdateSample.ts][appservicecertificateorderscreateorupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersDeleteCertificateSample.ts][appservicecertificateordersdeletecertificatesample] | Description for Delete the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificate.json | +| [appServiceCertificateOrdersDeleteSample.ts][appservicecertificateordersdeletesample] | Description for Delete an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersGetCertificateSample.ts][appservicecertificateordersgetcertificatesample] | Description for Get the certificate associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificate.json | +| [appServiceCertificateOrdersGetSample.ts][appservicecertificateordersgetsample] | Description for Get a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersListByResourceGroupSample.ts][appservicecertificateorderslistbyresourcegroupsample] | Description for Get certificate orders in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json | +| [appServiceCertificateOrdersListCertificatesSample.ts][appservicecertificateorderslistcertificatessample] | Description for List all certificates associated with a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListCertificatesByAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersListSample.ts][appservicecertificateorderslistsample] | Description for List all certificate orders in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersBySubscription.json | +| [appServiceCertificateOrdersReissueSample.ts][appservicecertificateordersreissuesample] | Description for Reissue an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ReissueAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersRenewSample.ts][appservicecertificateordersrenewsample] | Description for Renew an existing certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RenewAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersResendEmailSample.ts][appservicecertificateordersresendemailsample] | Description for Resend certificate email. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendAppServiceCertificateOrderEmail.json | +| [appServiceCertificateOrdersResendRequestEmailsSample.ts][appservicecertificateordersresendrequestemailssample] | Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendDomainOwnershipVerificationEmail.json | +| [appServiceCertificateOrdersRetrieveCertificateActionsSample.ts][appservicecertificateordersretrievecertificateactionssample] | Description for Retrieve the list of certificate actions. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateOrderActions.json | +| [appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts][appservicecertificateordersretrievecertificateemailhistorysample] | Description for Retrieve email history. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateEmailHistory.json | +| [appServiceCertificateOrdersRetrieveSiteSealSample.ts][appservicecertificateordersretrievesitesealsample] | This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveSiteSeal.json | +| [appServiceCertificateOrdersUpdateCertificateSample.ts][appservicecertificateordersupdatecertificatesample] | Description for Creates or updates a certificate and associates with key vault secret. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificate.json | +| [appServiceCertificateOrdersUpdateSample.ts][appservicecertificateordersupdatesample] | Description for Create or update a certificate purchase order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificateOrder.json | +| [appServiceCertificateOrdersValidatePurchaseInformationSample.ts][appservicecertificateordersvalidatepurchaseinformationsample] | Description for Validate information for a certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json | +| [appServiceCertificateOrdersVerifyDomainOwnershipSample.ts][appservicecertificateordersverifydomainownershipsample] | Description for Verify domain ownership for this certificate order. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/VerifyDomainOwnership.json | +| [appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts][appserviceenvironmentsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json | +| [appServiceEnvironmentsChangeVnetSample.ts][appserviceenvironmentschangevnetsample] | Description for Move an App Service Environment to a different VNET. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ChangeVnet.json | +| [appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts][appserviceenvironmentscreateorupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | +| [appServiceEnvironmentsCreateOrUpdateSample.ts][appserviceenvironmentscreateorupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdate.json | +| [appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts][appserviceenvironmentscreateorupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | +| [appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample] | Delete Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts][appserviceenvironmentsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json | +| [appServiceEnvironmentsDeleteSample.ts][appserviceenvironmentsdeletesample] | Description for Delete an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Delete.json | +| [appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsgetasecustomdnssuffixconfigurationsample] | Get Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts][appserviceenvironmentsgetasev3networkingconfigurationsample] | Description for Get networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json | +| [appServiceEnvironmentsGetDiagnosticsItemSample.ts][appserviceenvironmentsgetdiagnosticsitemsample] | Description for Get a diagnostics item for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json | +| [appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts][appserviceenvironmentsgetinboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all inbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetInboundNetworkDependenciesEndpoints.json | +| [appServiceEnvironmentsGetMultiRolePoolSample.ts][appserviceenvironmentsgetmultirolepoolsample] | Description for Get properties of a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetMultiRolePool.json | +| [appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts][appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample] | Description for Get the network endpoints of all outbound dependencies of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetOutboundNetworkDependenciesEndpoints.json | +| [appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts][appserviceenvironmentsgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoints associated with a hosting environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json | +| [appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts][appserviceenvironmentsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json | +| [appServiceEnvironmentsGetPrivateLinkResourcesSample.ts][appserviceenvironmentsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json | +| [appServiceEnvironmentsGetSample.ts][appserviceenvironmentsgetsample] | Description for Get the properties of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Get.json | +| [appServiceEnvironmentsGetVipInfoSample.ts][appserviceenvironmentsgetvipinfosample] | Description for Get IP addresses assigned to an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetVipInfo.json | +| [appServiceEnvironmentsGetWorkerPoolSample.ts][appserviceenvironmentsgetworkerpoolsample] | Description for Get properties of a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetWorkerPool.json | +| [appServiceEnvironmentsListAppServicePlansSample.ts][appserviceenvironmentslistappserviceplanssample] | Description for Get all App Service plans in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListAppServicePlans.json | +| [appServiceEnvironmentsListByResourceGroupSample.ts][appserviceenvironmentslistbyresourcegroupsample] | Description for Get all App Service Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListByResourceGroup.json | +| [appServiceEnvironmentsListCapacitiesSample.ts][appserviceenvironmentslistcapacitiessample] | Description for Get the used, available, and total worker capacity an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListCapacities.json | +| [appServiceEnvironmentsListDiagnosticsSample.ts][appserviceenvironmentslistdiagnosticssample] | Description for Get diagnostic information for an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListDiagnostics.json | +| [appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts][appserviceenvironmentslistmultirolemetricdefinitionssample] | Description for Get metric definitions for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json | +| [appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts][appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json | +| [appServiceEnvironmentsListMultiRolePoolSkusSample.ts][appserviceenvironmentslistmultirolepoolskussample] | Description for Get available SKUs for scaling a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json | +| [appServiceEnvironmentsListMultiRolePoolsSample.ts][appserviceenvironmentslistmultirolepoolssample] | Description for Get all multi-role pools. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePools.json | +| [appServiceEnvironmentsListMultiRoleUsagesSample.ts][appserviceenvironmentslistmultiroleusagessample] | Description for Get usage metrics for a multi-role pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json | +| [appServiceEnvironmentsListOperationsSample.ts][appserviceenvironmentslistoperationssample] | Description for List all currently running operations on the App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListOperations.json | +| [appServiceEnvironmentsListSample.ts][appserviceenvironmentslistsample] | Description for Get all App Service Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_List.json | +| [appServiceEnvironmentsListUsagesSample.ts][appserviceenvironmentslistusagessample] | Description for Get global usage metrics of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListUsages.json | +| [appServiceEnvironmentsListWebAppsSample.ts][appserviceenvironmentslistwebappssample] | Description for Get all apps in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebApps.json | +| [appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts][appserviceenvironmentslistwebworkermetricdefinitionssample] | Description for Get metric definitions for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json | +| [appServiceEnvironmentsListWebWorkerUsagesSample.ts][appserviceenvironmentslistwebworkerusagessample] | Description for Get usage metrics for a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json | +| [appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts][appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample] | Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json | +| [appServiceEnvironmentsListWorkerPoolSkusSample.ts][appserviceenvironmentslistworkerpoolskussample] | Description for Get available SKUs for scaling a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json | +| [appServiceEnvironmentsListWorkerPoolsSample.ts][appserviceenvironmentslistworkerpoolssample] | Description for Get all worker pools of an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPools.json | +| [appServiceEnvironmentsRebootSample.ts][appserviceenvironmentsrebootsample] | Description for Reboot all machines in an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Reboot.json | +| [appServiceEnvironmentsResumeSample.ts][appserviceenvironmentsresumesample] | Description for Resume an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Resume.json | +| [appServiceEnvironmentsSuspendSample.ts][appserviceenvironmentssuspendsample] | Description for Suspend an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Suspend.json | +| [appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts][appserviceenvironmentstestupgradeavailablenotificationsample] | Send a test notification that an upgrade is available for this App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json | +| [appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts][appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample] | Update Custom Dns Suffix configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAseCustomDnsSuffixConfiguration.json | +| [appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts][appserviceenvironmentsupdateasenetworkingconfigurationsample] | Description for Update networking configuration of an App Service Environment x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json | +| [appServiceEnvironmentsUpdateMultiRolePoolSample.ts][appserviceenvironmentsupdatemultirolepoolsample] | Description for Create or update a multi-role pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json | +| [appServiceEnvironmentsUpdateSample.ts][appserviceenvironmentsupdatesample] | Description for Create or update an App Service Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Update.json | +| [appServiceEnvironmentsUpdateWorkerPoolSample.ts][appserviceenvironmentsupdateworkerpoolsample] | Description for Create or update a worker pool. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json | +| [appServiceEnvironmentsUpgradeSample.ts][appserviceenvironmentsupgradesample] | Description for Initiate an upgrade of an App Service Environment if one is available. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Upgrade.json | +| [appServicePlansCreateOrUpdateSample.ts][appserviceplanscreateorupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateAppServicePlan.json | +| [appServicePlansDeleteSample.ts][appserviceplansdeletesample] | Description for Delete an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAppServicePlan.json | +| [appServicePlansGetSample.ts][appserviceplansgetsample] | Description for Get an App Service plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAppServicePlan.json | +| [appServicePlansListByResourceGroupSample.ts][appserviceplanslistbyresourcegroupsample] | Description for Get all App Service plans in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlansByResourceGroup.json | +| [appServicePlansListSample.ts][appserviceplanslistsample] | Description for Get all App Service plans for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlans.json | +| [appServicePlansUpdateSample.ts][appserviceplansupdatesample] | Description for Creates or updates an App Service Plan. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchAppServicePlan.json | +| [certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts][certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json | +| [certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts][certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample] | Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json | +| [certificateRegistrationProviderListOperationsSample.ts][certificateregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListOperations.json | +| [certificatesCreateOrUpdateSample.ts][certificatescreateorupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateCertificate.json | +| [certificatesDeleteSample.ts][certificatesdeletesample] | Description for Delete a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteCertificate.json | +| [certificatesGetSample.ts][certificatesgetsample] | Description for Get a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetCertificate.json | +| [certificatesListByResourceGroupSample.ts][certificateslistbyresourcegroupsample] | Description for Get all certificates in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificatesByResourceGroup.json | +| [certificatesListSample.ts][certificateslistsample] | Description for Get all certificates for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificates.json | +| [certificatesUpdateSample.ts][certificatesupdatesample] | Description for Create or update a certificate. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchCertificate.json | +| [containerAppsCreateOrUpdateSample.ts][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateContainerApp.json | +| [containerAppsDeleteSample.ts][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteContainerApp.json | +| [containerAppsGetSample.ts][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetContainerApp.json | +| [containerAppsListByResourceGroupSample.ts][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsByResourceGroup.json | +| [containerAppsListBySubscriptionSample.ts][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsBySubscription.json | +| [containerAppsListSecretsSample.ts][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppSecrets.json | +| [containerAppsRevisionsActivateRevisionSample.ts][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ActivateRevision.json | +| [containerAppsRevisionsDeactivateRevisionSample.ts][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeactivateRevision.json | +| [containerAppsRevisionsGetRevisionSample.ts][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetRevision.json | +| [containerAppsRevisionsListRevisionsSample.ts][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListRevisions.json | +| [containerAppsRevisionsRestartRevisionSample.ts][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestartRevision.json | +| [deletedWebAppsGetDeletedWebAppByLocationSample.ts][deletedwebappsgetdeletedwebappbylocationsample] | Description for Get deleted app for a subscription at location. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppByLocation.json | +| [deletedWebAppsListByLocationSample.ts][deletedwebappslistbylocationsample] | Description for Get all deleted apps for a subscription at location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListDeletedWebAppsByLocation.json | +| [diagnosticsExecuteSiteAnalysisSample.ts][diagnosticsexecutesiteanalysissample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json | +| [diagnosticsExecuteSiteAnalysisSlotSample.ts][diagnosticsexecutesiteanalysisslotsample] | Description for Execute Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json | +| [diagnosticsExecuteSiteDetectorSample.ts][diagnosticsexecutesitedetectorsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json | +| [diagnosticsExecuteSiteDetectorSlotSample.ts][diagnosticsexecutesitedetectorslotsample] | Description for Execute Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json | +| [diagnosticsGetHostingEnvironmentDetectorResponseSample.ts][diagnosticsgethostingenvironmentdetectorresponsesample] | Description for Get Hosting Environment Detector Response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json | +| [diagnosticsGetSiteAnalysisSample.ts][diagnosticsgetsiteanalysissample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json | +| [diagnosticsGetSiteAnalysisSlotSample.ts][diagnosticsgetsiteanalysisslotsample] | Description for Get Site Analysis x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json | +| [diagnosticsGetSiteDetectorResponseSample.ts][diagnosticsgetsitedetectorresponsesample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json | +| [diagnosticsGetSiteDetectorResponseSlotSample.ts][diagnosticsgetsitedetectorresponseslotsample] | Description for Get site detector response x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json | +| [diagnosticsGetSiteDetectorSample.ts][diagnosticsgetsitedetectorsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json | +| [diagnosticsGetSiteDetectorSlotSample.ts][diagnosticsgetsitedetectorslotsample] | Description for Get Detector x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json | +| [diagnosticsGetSiteDiagnosticCategorySample.ts][diagnosticsgetsitediagnosticcategorysample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | +| [diagnosticsGetSiteDiagnosticCategorySlotSample.ts][diagnosticsgetsitediagnosticcategoryslotsample] | Description for Get Diagnostics Category x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json | +| [diagnosticsListHostingEnvironmentDetectorResponsesSample.ts][diagnosticslisthostingenvironmentdetectorresponsessample] | Description for List Hosting Environment Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json | +| [diagnosticsListSiteAnalysesSample.ts][diagnosticslistsiteanalysessample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json | +| [diagnosticsListSiteAnalysesSlotSample.ts][diagnosticslistsiteanalysesslotsample] | Description for Get Site Analyses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json | +| [diagnosticsListSiteDetectorResponsesSample.ts][diagnosticslistsitedetectorresponsessample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json | +| [diagnosticsListSiteDetectorResponsesSlotSample.ts][diagnosticslistsitedetectorresponsesslotsample] | Description for List Site Detector Responses x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json | +| [diagnosticsListSiteDetectorsSample.ts][diagnosticslistsitedetectorssample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json | +| [diagnosticsListSiteDetectorsSlotSample.ts][diagnosticslistsitedetectorsslotsample] | Description for Get Detectors x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json | +| [diagnosticsListSiteDiagnosticCategoriesSample.ts][diagnosticslistsitediagnosticcategoriessample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | +| [diagnosticsListSiteDiagnosticCategoriesSlotSample.ts][diagnosticslistsitediagnosticcategoriesslotsample] | Description for Get Diagnostics Categories x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json | +| [domainRegistrationProviderListOperationsSample.ts][domainregistrationproviderlistoperationssample] | Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListOperations.json | +| [domainsCheckAvailabilitySample.ts][domainscheckavailabilitysample] | Description for Check if a domain is available for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CheckDomainAvailability.json | +| [domainsCreateOrUpdateOwnershipIdentifierSample.ts][domainscreateorupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomainOwnershipIdentifier.json | +| [domainsCreateOrUpdateSample.ts][domainscreateorupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomain.json | +| [domainsDeleteOwnershipIdentifierSample.ts][domainsdeleteownershipidentifiersample] | Description for Delete ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json | +| [domainsDeleteSample.ts][domainsdeletesample] | Description for Delete a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomain.json | +| [domainsGetControlCenterSsoRequestSample.ts][domainsgetcontrolcenterssorequestsample] | Description for Generate a single sign-on request for the domain management portal. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainControlCenterSsoRequest.json | +| [domainsGetOwnershipIdentifierSample.ts][domainsgetownershipidentifiersample] | Description for Get ownership identifier for domain x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainOwnershipIdentifier.json | +| [domainsGetSample.ts][domainsgetsample] | Description for Get a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomain.json | +| [domainsListByResourceGroupSample.ts][domainslistbyresourcegroupsample] | Description for Get all domains in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsByResourceGroup.json | +| [domainsListOwnershipIdentifiersSample.ts][domainslistownershipidentifierssample] | Description for Lists domain ownership identifiers. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainOwnershipIdentifiers.json | +| [domainsListRecommendationsSample.ts][domainslistrecommendationssample] | Description for Get domain name recommendations based on keywords. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainRecommendations.json | +| [domainsListSample.ts][domainslistsample] | Description for Get all domains in a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsBySubscription.json | +| [domainsRenewSample.ts][domainsrenewsample] | Description for Renew a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/RenewDomain.json | +| [domainsTransferOutSample.ts][domainstransferoutsample] | Transfer out domain to another registrar x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/TransferOutDomain.json | +| [domainsUpdateOwnershipIdentifierSample.ts][domainsupdateownershipidentifiersample] | Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json | +| [domainsUpdateSample.ts][domainsupdatesample] | Description for Creates or updates a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomain.json | +| [globalGetDeletedWebAppSample.ts][globalgetdeletedwebappsample] | Description for Get deleted app for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebApp.json | +| [globalGetDeletedWebAppSnapshotsSample.ts][globalgetdeletedwebappsnapshotssample] | Description for Get all deleted apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppSnapshots.json | +| [globalGetSubscriptionOperationWithAsyncResponseSample.ts][globalgetsubscriptionoperationwithasyncresponsesample] | Description for Gets an operation in a subscription and given region x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSubscriptionOperationWithAsyncResponse.json | +| [kubeEnvironmentsCreateOrUpdateSample.ts][kubeenvironmentscreateorupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_CreateOrUpdate.json | +| [kubeEnvironmentsDeleteSample.ts][kubeenvironmentsdeletesample] | Description for Delete a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Delete.json | +| [kubeEnvironmentsGetSample.ts][kubeenvironmentsgetsample] | Description for Get the properties of a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Get.json | +| [kubeEnvironmentsListByResourceGroupSample.ts][kubeenvironmentslistbyresourcegroupsample] | Description for Get all the Kubernetes Environments in a resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListByResourceGroup.json | +| [kubeEnvironmentsListBySubscriptionSample.ts][kubeenvironmentslistbysubscriptionsample] | Description for Get all Kubernetes Environments for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListBySubscription.json | +| [kubeEnvironmentsUpdateSample.ts][kubeenvironmentsupdatesample] | Description for Creates or updates a Kubernetes Environment. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Update.json | +| [listCustomHostNameSitesSample.ts][listcustomhostnamesitessample] | Get custom hostnames under this subscription x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomHostNameSites.json | +| [providerGetFunctionAppStacksForLocationSample.ts][providergetfunctionappstacksforlocationsample] | Description for Get available Function app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacksForLocation.json | +| [providerGetFunctionAppStacksSample.ts][providergetfunctionappstackssample] | Description for Get available Function app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacks.json | +| [providerGetWebAppStacksForLocationSample.ts][providergetwebappstacksforlocationsample] | Description for Get available Web app frameworks and their versions for location x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacksForLocation.json | +| [providerGetWebAppStacksSample.ts][providergetwebappstackssample] | Description for Get available Web app frameworks and their versions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacks.json | +| [providerListOperationsSample.ts][providerlistoperationssample] | Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListOperations.json | +| [resourceHealthMetadataGetBySiteSample.ts][resourcehealthmetadatagetbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json | +| [resourceHealthMetadataGetBySiteSlotSample.ts][resourcehealthmetadatagetbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListByResourceGroupSample.ts][resourcehealthmetadatalistbyresourcegroupsample] | Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataByResourceGroup.json | +| [resourceHealthMetadataListBySiteSample.ts][resourcehealthmetadatalistbysitesample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListBySiteSlotSample.ts][resourcehealthmetadatalistbysiteslotsample] | Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json | +| [resourceHealthMetadataListSample.ts][resourcehealthmetadatalistsample] | Description for List all ResourceHealthMetadata for all sites in the subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySubscription.json | +| [staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts][staticsitesapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json | +| [staticSitesCreateOrUpdateBasicAuthSample.ts][staticsitescreateorupdatebasicauthsample] | Description for Adds or updates basic auth for a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBasicAuth.json | +| [staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts][staticsitescreateorupdatebuilddatabaseconnectionsample] | Description for Create or update a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildDatabaseConnection.json | +| [staticSitesCreateOrUpdateDatabaseConnectionSample.ts][staticsitescreateorupdatedatabaseconnectionsample] | Description for Create or update a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteDatabaseConnection.json | +| [staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts][staticsitescreateorupdatestaticsiteappsettingssample] | Description for Creates or updates the app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts][staticsitescreateorupdatestaticsitebuildappsettingssample] | Description for Creates or updates the app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts][staticsitescreateorupdatestaticsitebuildfunctionappsettingssample] | Description for Creates or updates the function app settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts][staticsitescreateorupdatestaticsitecustomdomainsample] | Description for Creates a new static site custom domain in an existing resource group and static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteCustomDomain.json | +| [staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts][staticsitescreateorupdatestaticsitefunctionappsettingssample] | Description for Creates or updates the function app settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json | +| [staticSitesCreateOrUpdateStaticSiteSample.ts][staticsitescreateorupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSite.json | +| [staticSitesCreateUserRolesInvitationLinkSample.ts][staticsitescreateuserrolesinvitationlinksample] | Description for Creates an invitation link for a user with the role x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateUserRolesInvitationLink.json | +| [staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts][staticsitescreatezipdeploymentforstaticsitebuildsample] | Description for Deploys zipped content to a specific environment of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteBuildZipDeploy.json | +| [staticSitesCreateZipDeploymentForStaticSiteSample.ts][staticsitescreatezipdeploymentforstaticsitesample] | Description for Deploys zipped content to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteZipDeploy.json | +| [staticSitesDeleteBuildDatabaseConnectionSample.ts][staticsitesdeletebuilddatabaseconnectionsample] | Delete a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuildDatabaseConnection.json | +| [staticSitesDeleteDatabaseConnectionSample.ts][staticsitesdeletedatabaseconnectionsample] | Delete a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteDatabaseConnection.json | +| [staticSitesDeletePrivateEndpointConnectionSample.ts][staticsitesdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json | +| [staticSitesDeleteStaticSiteBuildSample.ts][staticsitesdeletestaticsitebuildsample] | Description for Deletes a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuild.json | +| [staticSitesDeleteStaticSiteCustomDomainSample.ts][staticsitesdeletestaticsitecustomdomainsample] | Description for Deletes a custom domain. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteCustomDomain.json | +| [staticSitesDeleteStaticSiteSample.ts][staticsitesdeletestaticsitesample] | Description for Deletes a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSite.json | +| [staticSitesDeleteStaticSiteUserSample.ts][staticsitesdeletestaticsiteusersample] | Description for Deletes the user entry from the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteUser.json | +| [staticSitesDetachStaticSiteSample.ts][staticsitesdetachstaticsitesample] | Description for Detaches a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachStaticSite.json | +| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts][staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample] | Description for Detach the user provided function app from the static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json | +| [staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts][staticsitesdetachuserprovidedfunctionappfromstaticsitesample] | Description for Detach the user provided function app from the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json | +| [staticSitesGetBasicAuthSample.ts][staticsitesgetbasicauthsample] | Description for Gets the basic auth properties for a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBasicAuth.json | +| [staticSitesGetBuildDatabaseConnectionSample.ts][staticsitesgetbuilddatabaseconnectionsample] | Returns overview of a database connection for a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnection.json | +| [staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts][staticsitesgetbuilddatabaseconnectionwithdetailssample] | Returns details of a database connection for a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionWithDetails.json | +| [staticSitesGetBuildDatabaseConnectionsSample.ts][staticsitesgetbuilddatabaseconnectionssample] | Returns overviews of database connections for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnections.json | +| [staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts][staticsitesgetbuilddatabaseconnectionswithdetailssample] | Returns details of database connections for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionsWithDetails.json | +| [staticSitesGetDatabaseConnectionSample.ts][staticsitesgetdatabaseconnectionsample] | Returns overview of a database connection for a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnection.json | +| [staticSitesGetDatabaseConnectionWithDetailsSample.ts][staticsitesgetdatabaseconnectionwithdetailssample] | Returns details of a database connection for a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionWithDetails.json | +| [staticSitesGetDatabaseConnectionsSample.ts][staticsitesgetdatabaseconnectionssample] | Returns overviews of database connections for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnections.json | +| [staticSitesGetDatabaseConnectionsWithDetailsSample.ts][staticsitesgetdatabaseconnectionswithdetailssample] | Returns details of database connections for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionsWithDetails.json | +| [staticSitesGetLinkedBackendForBuildSample.ts][staticsitesgetlinkedbackendforbuildsample] | Returns the details of a linked backend linked to a static site build by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSiteBuild.json | +| [staticSitesGetLinkedBackendSample.ts][staticsitesgetlinkedbackendsample] | Returns the details of a linked backend linked to a static site by name x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSite.json | +| [staticSitesGetLinkedBackendsForBuildSample.ts][staticsitesgetlinkedbackendsforbuildsample] | Returns details of all backends linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSiteBuild.json | +| [staticSitesGetLinkedBackendsSample.ts][staticsitesgetlinkedbackendssample] | Returns details of all backends linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSite.json | +| [staticSitesGetPrivateEndpointConnectionListSample.ts][staticsitesgetprivateendpointconnectionlistsample] | Description for Gets the list of private endpoint connections associated with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionList.json | +| [staticSitesGetPrivateEndpointConnectionSample.ts][staticsitesgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json | +| [staticSitesGetPrivateLinkResourcesSample.ts][staticsitesgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json | +| [staticSitesGetStaticSiteBuildSample.ts][staticsitesgetstaticsitebuildsample] | Description for Gets the details of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuild.json | +| [staticSitesGetStaticSiteBuildsSample.ts][staticsitesgetstaticsitebuildssample] | Description for Gets all static site builds for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuilds.json | +| [staticSitesGetStaticSiteCustomDomainSample.ts][staticsitesgetstaticsitecustomdomainsample] | Description for Gets an existing custom domain for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomain.json | +| [staticSitesGetStaticSiteSample.ts][staticsitesgetstaticsitesample] | Description for Gets the details of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSite.json | +| [staticSitesGetStaticSitesByResourceGroupSample.ts][staticsitesgetstaticsitesbyresourcegroupsample] | Description for Gets all static sites in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSites.json | +| [staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts][staticsitesgetuserprovidedfunctionappforstaticsitebuildsample] | Description for Gets the details of the user provided function app registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json | +| [staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts][staticsitesgetuserprovidedfunctionappforstaticsitesample] | Description for Gets the details of the user provided function app registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSite.json | +| [staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts][staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample] | Description for Gets the details of the user provided function apps registered with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json | +| [staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts][staticsitesgetuserprovidedfunctionappsforstaticsitesample] | Description for Gets the details of the user provided function apps registered with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSite.json | +| [staticSitesLinkBackendSample.ts][staticsiteslinkbackendsample] | Link backend to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSite.json | +| [staticSitesLinkBackendToBuildSample.ts][staticsiteslinkbackendtobuildsample] | Link backend to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSiteBuild.json | +| [staticSitesListBasicAuthSample.ts][staticsiteslistbasicauthsample] | Description for Gets the basic auth properties for a static site as a collection. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBasicAuth.json | +| [staticSitesListSample.ts][staticsiteslistsample] | Description for Get all Static Sites for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAllStaticSites.json | +| [staticSitesListStaticSiteAppSettingsSample.ts][staticsitesliststaticsiteappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteAppSettings.json | +| [staticSitesListStaticSiteBuildAppSettingsSample.ts][staticsitesliststaticsitebuildappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildAppSettings.json | +| [staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts][staticsitesliststaticsitebuildfunctionappsettingssample] | Description for Gets the application settings of a static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctionAppSettings.json | +| [staticSitesListStaticSiteBuildFunctionsSample.ts][staticsitesliststaticsitebuildfunctionssample] | Description for Gets the functions of a particular static site build. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctions.json | +| [staticSitesListStaticSiteConfiguredRolesSample.ts][staticsitesliststaticsiteconfiguredrolessample] | Description for Lists the roles configured for the static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteConfiguredRoles.json | +| [staticSitesListStaticSiteCustomDomainsSample.ts][staticsitesliststaticsitecustomdomainssample] | Description for Gets all static site custom domains for a particular static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomains.json | +| [staticSitesListStaticSiteFunctionAppSettingsSample.ts][staticsitesliststaticsitefunctionappsettingssample] | Description for Gets the application settings of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctionAppSettings.json | +| [staticSitesListStaticSiteFunctionsSample.ts][staticsitesliststaticsitefunctionssample] | Description for Gets the functions of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctions.json | +| [staticSitesListStaticSiteSecretsSample.ts][staticsitesliststaticsitesecretssample] | Description for Lists the secrets for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteSecrets.json | +| [staticSitesListStaticSiteUsersSample.ts][staticsitesliststaticsiteuserssample] | Description for Gets the list of users of a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteUsers.json | +| [staticSitesPreviewWorkflowSample.ts][staticsitespreviewworkflowsample] | Description for Generates a preview workflow file for the static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GenerateStaticSiteWorkflowPreview.json | +| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts][staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample] | Description for Register a user provided function app with a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json | +| [staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts][staticsitesregisteruserprovidedfunctionappwithstaticsitesample] | Description for Register a user provided function app with a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json | +| [staticSitesResetStaticSiteApiKeySample.ts][staticsitesresetstaticsiteapikeysample] | Description for Resets the api key for an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ResetStaticSiteApiKey.json | +| [staticSitesUnlinkBackendFromBuildSample.ts][staticsitesunlinkbackendfrombuildsample] | Unlink a backend from a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSiteBuild.json | +| [staticSitesUnlinkBackendSample.ts][staticsitesunlinkbackendsample] | Unlink a backend from a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSite.json | +| [staticSitesUpdateBuildDatabaseConnectionSample.ts][staticsitesupdatebuilddatabaseconnectionsample] | Description for Create or update a database connection for a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteBuildDatabaseConnection.json | +| [staticSitesUpdateDatabaseConnectionSample.ts][staticsitesupdatedatabaseconnectionsample] | Description for Create or update a database connection for a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteDatabaseConnection.json | +| [staticSitesUpdateStaticSiteSample.ts][staticsitesupdatestaticsitesample] | Description for Creates a new static site in an existing resource group, or updates an existing static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSite.json | +| [staticSitesUpdateStaticSiteUserSample.ts][staticsitesupdatestaticsiteusersample] | Description for Updates a user entry with the listed roles x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateStaticSiteUser.json | +| [staticSitesValidateBackendForBuildSample.ts][staticsitesvalidatebackendforbuildsample] | Validates that a backend can be linked to a static site build x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSiteBuild.json | +| [staticSitesValidateBackendSample.ts][staticsitesvalidatebackendsample] | Validates that a backend can be linked to a static site x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSite.json | +| [staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts][staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample] | Description for Validates a particular custom domain can be added to a static site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateStaticSiteCustomDomain.json | +| [topLevelDomainsGetSample.ts][topleveldomainsgetsample] | Description for Get details of a top-level domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetTopLevelDomain.json | +| [topLevelDomainsListAgreementsSample.ts][topleveldomainslistagreementssample] | Description for Gets all legal agreements that user needs to accept before purchasing a domain. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomainAgreements.json | +| [topLevelDomainsListSample.ts][topleveldomainslistsample] | Description for Get all top-level domains supported for registration. x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomains.json | +| [verifyHostingEnvironmentVnetSample.ts][verifyhostingenvironmentvnetsample] | Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/VerifyHostingEnvironmentVnet.json | +| [webAppsAnalyzeCustomHostnameSample.ts][webappsanalyzecustomhostnamesample] | Description for Analyze a custom hostname. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostName.json | +| [webAppsAnalyzeCustomHostnameSlotSample.ts][webappsanalyzecustomhostnameslotsample] | Description for Analyze a custom hostname. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostNameSlot.json | +| [webAppsApplySlotConfigToProductionSample.ts][webappsapplyslotconfigtoproductionsample] | Description for Applies the configuration settings from the target slot onto the current slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApplySlotConfig.json | +| [webAppsApproveOrRejectPrivateEndpointConnectionSample.ts][webappsapproveorrejectprivateendpointconnectionsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json | +| [webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts][webappsapproveorrejectprivateendpointconnectionslotsample] | Description for Approves or rejects a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json | +| [webAppsBackupSample.ts][webappsbackupsample] | Description for Creates a backup of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/BackupWebApp.json | +| [webAppsCreateOrUpdateConfigurationSample.ts][webappscreateorupdateconfigurationsample] | Description for Updates the configuration of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateSiteConfig.json | +| [webAppsCreateOrUpdateSample.ts][webappscreateorupdatesample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebApp.json | +| [webAppsCreateOrUpdateSlotSample.ts][webappscreateorupdateslotsample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebAppSlot.json | +| [webAppsDeleteBackupSample.ts][webappsdeletebackupsample] | Description for Deletes a backup of an app by its ID. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppBackup.json | +| [webAppsDeletePrivateEndpointConnectionSample.ts][webappsdeleteprivateendpointconnectionsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json | +| [webAppsDeletePrivateEndpointConnectionSlotSample.ts][webappsdeleteprivateendpointconnectionslotsample] | Description for Deletes a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnectionSlot.json | +| [webAppsDeleteSample.ts][webappsdeletesample] | Description for Deletes a web, mobile, or API app, or one of the deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebApp.json | +| [webAppsDeleteSlotSample.ts][webappsdeleteslotsample] | Description for Deletes a web, mobile, or API app, or one of the deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppSlot.json | +| [webAppsDeployWorkflowArtifactsSample.ts][webappsdeployworkflowartifactssample] | Description for Creates the artifacts for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteDeployWorkflowArtifacts.json | +| [webAppsDeployWorkflowArtifactsSlotSample.ts][webappsdeployworkflowartifactsslotsample] | Description for Creates the artifacts for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifactsSlot.json | +| [webAppsGetAppSettingKeyVaultReferenceSample.ts][webappsgetappsettingkeyvaultreferencesample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSetting.json | +| [webAppsGetAppSettingKeyVaultReferenceSlotSample.ts][webappsgetappsettingkeyvaultreferenceslotsample] | Description for Gets the config reference and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingSlot.json | +| [webAppsGetAppSettingsKeyVaultReferencesSample.ts][webappsgetappsettingskeyvaultreferencessample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettings.json | +| [webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts][webappsgetappsettingskeyvaultreferencesslotsample] | Description for Gets the config reference app settings and status of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json | +| [webAppsGetAuthSettingsSample.ts][webappsgetauthsettingssample] | Description for Gets the Authentication/Authorization settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettings.json | +| [webAppsGetAuthSettingsV2Sample.ts][webappsgetauthsettingsv2sample] | Description for Gets site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettingsV2.json | +| [webAppsGetAuthSettingsV2WithoutSecretsSample.ts][webappsgetauthsettingsv2withoutsecretssample] | Description for Gets site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAuthSettingsV2WithoutSecrets.json | +| [webAppsGetBackupStatusSample.ts][webappsgetbackupstatussample] | Description for Gets a backup of an app by its ID. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackup.json | +| [webAppsGetConfigurationSample.ts][webappsgetconfigurationsample] | Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteConfig.json | +| [webAppsGetFtpAllowedSample.ts][webappsgetftpallowedsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json | +| [webAppsGetFtpAllowedSlotSample.ts][webappsgetftpallowedslotsample] | Description for Returns whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json | +| [webAppsGetInstanceInfoSample.ts][webappsgetinstanceinfosample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json | +| [webAppsGetInstanceInfoSlotSample.ts][webappsgetinstanceinfoslotsample] | Description for Gets all scale-out instances of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json | +| [webAppsGetInstanceWorkflowSlotSample.ts][webappsgetinstanceworkflowslotsample] | Get workflow information by its ID for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json | +| [webAppsGetNetworkTraceOperationSample.ts][webappsgetnetworktraceoperationsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationSlotSample.ts][webappsgetnetworktraceoperationslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationSlotV2Sample.ts][webappsgetnetworktraceoperationslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTraceOperationV2Sample.ts][webappsgetnetworktraceoperationv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json | +| [webAppsGetNetworkTracesSample.ts][webappsgetnetworktracessample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesSlotSample.ts][webappsgetnetworktracesslotsample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesSlotV2Sample.ts][webappsgetnetworktracesslotv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetNetworkTracesV2Sample.ts][webappsgetnetworktracesv2sample] | Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json | +| [webAppsGetPrivateEndpointConnectionSample.ts][webappsgetprivateendpointconnectionsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json | +| [webAppsGetPrivateEndpointConnectionSlotSample.ts][webappsgetprivateendpointconnectionslotsample] | Description for Gets a private endpoint connection x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionSlot.json | +| [webAppsGetPrivateLinkResourcesSample.ts][webappsgetprivatelinkresourcessample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json | +| [webAppsGetPrivateLinkResourcesSlotSample.ts][webappsgetprivatelinkresourcesslotsample] | Description for Gets the private link resources x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResourcesSlot.json | +| [webAppsGetProductionSiteDeploymentStatusSample.ts][webappsgetproductionsitedeploymentstatussample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatus.json | +| [webAppsGetSample.ts][webappsgetsample] | Description for Gets the details of a web, mobile, or API app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebApp.json | +| [webAppsGetScmAllowedSample.ts][webappsgetscmallowedsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json | +| [webAppsGetScmAllowedSlotSample.ts][webappsgetscmallowedslotsample] | Description for Returns whether Scm basic auth is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json | +| [webAppsGetSlotSample.ts][webappsgetslotsample] | Description for Gets the details of a web, mobile, or API app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppSlot.json | +| [webAppsGetSlotSiteDeploymentStatusSlotSample.ts][webappsgetslotsitedeploymentstatusslotsample] | Gets the deployment status for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatusSlot.json | +| [webAppsGetWorkflowSample.ts][webappsgetworkflowsample] | Get workflow information by its ID for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json | +| [webAppsListApplicationSettingsSample.ts][webappslistapplicationsettingssample] | Description for Gets the application settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppSettings.json | +| [webAppsListBackupStatusSecretsSample.ts][webappslistbackupstatussecretssample] | Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackupWithSecrets.json | +| [webAppsListBackupsSample.ts][webappslistbackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppBackups.json | +| [webAppsListBasicPublishingCredentialsPoliciesSample.ts][webappslistbasicpublishingcredentialspoliciessample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPolicies.json | +| [webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts][webappslistbasicpublishingcredentialspoliciesslotsample] | Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPoliciesSlot.json | +| [webAppsListByResourceGroupSample.ts][webappslistbyresourcegroupsample] | Description for Gets all web, mobile, and API apps in the specified resource group. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppsByResourceGroup.json | +| [webAppsListConfigurationsSample.ts][webappslistconfigurationssample] | Description for List the configurations of an app x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppConfigurations.json | +| [webAppsListInstanceWorkflowsSlotSample.ts][webappslistinstanceworkflowsslotsample] | List the workflows for a web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json | +| [webAppsListProductionSiteDeploymentStatusesSample.ts][webappslistproductionsitedeploymentstatusessample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatus.json | +| [webAppsListSample.ts][webappslistsample] | Description for Get all apps for a subscription. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebApps.json | +| [webAppsListSiteBackupsSample.ts][webappslistsitebackupssample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json | +| [webAppsListSiteBackupsSlotSample.ts][webappslistsitebackupsslotsample] | Description for Gets existing backups of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json | +| [webAppsListSlotSiteDeploymentStatusesSlotSample.ts][webappslistslotsitedeploymentstatusesslotsample] | List deployment statuses for an app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatusSlot.json | +| [webAppsListSlotsSample.ts][webappslistslotssample] | Description for Gets an app's deployment slots. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppSlots.json | +| [webAppsListWorkflowsConnectionsSample.ts][webappslistworkflowsconnectionssample] | Lists logic app's connections for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json | +| [webAppsListWorkflowsConnectionsSlotSample.ts][webappslistworkflowsconnectionsslotsample] | Lists logic app's connections for web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json | +| [webAppsListWorkflowsSample.ts][webappslistworkflowssample] | List the workflows for a web site, or a deployment slot. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json | +| [webAppsRestoreSample.ts][webappsrestoresample] | Description for Restores a specific backup to another app (or deployment slot, if specified). x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestoreWebAppBackup.json | +| [webAppsStartNetworkTraceSample.ts][webappsstartnetworktracesample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartNetworkTraceSlotSample.ts][webappsstartnetworktraceslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartWebSiteNetworkTraceOperationSample.ts][webappsstartwebsitenetworktraceoperationsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStartWebSiteNetworkTraceOperationSlotSample.ts][webappsstartwebsitenetworktraceoperationslotsample] | Description for Start capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json | +| [webAppsStopNetworkTraceSample.ts][webappsstopnetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopNetworkTraceSlotSample.ts][webappsstopnetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopWebSiteNetworkTraceSample.ts][webappsstopwebsitenetworktracesample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsStopWebSiteNetworkTraceSlotSample.ts][webappsstopwebsitenetworktraceslotsample] | Description for Stop ongoing capturing network packets for the site. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json | +| [webAppsUpdateApplicationSettingsSample.ts][webappsupdateapplicationsettingssample] | Description for Replaces the application settings of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAppSettings.json | +| [webAppsUpdateAuthSettingsSample.ts][webappsupdateauthsettingssample] | Description for Updates the Authentication / Authorization settings associated with web app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettings.json | +| [webAppsUpdateAuthSettingsV2Sample.ts][webappsupdateauthsettingsv2sample] | Description for Updates site's Authentication / Authorization settings for apps via the V2 format x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettingsV2.json | +| [webAppsUpdateAzureStorageAccountsSample.ts][webappsupdateazurestorageaccountssample] | Description for Updates the Azure storage account configurations of an app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAzureStorageAccounts.json | +| [webAppsUpdateFtpAllowedSample.ts][webappsupdateftpallowedsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json | +| [webAppsUpdateFtpAllowedSlotSample.ts][webappsupdateftpallowedslotsample] | Description for Updates whether FTP is allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json | +| [webAppsUpdateSample.ts][webappsupdatesample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebApp.json | +| [webAppsUpdateScmAllowedSample.ts][webappsupdatescmallowedsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json | +| [webAppsUpdateScmAllowedSlotSample.ts][webappsupdatescmallowedslotsample] | Description for Updates whether user publishing credentials are allowed on the site or not. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json | +| [webAppsUpdateSlotSample.ts][webappsupdateslotsample] | Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebAppSlot.json | +| [workflowRunActionRepetitionsGetSample.ts][workflowrunactionrepetitionsgetsample] | Get a workflow run action repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_Get.json | +| [workflowRunActionRepetitionsListExpressionTracesSample.ts][workflowrunactionrepetitionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json | +| [workflowRunActionRepetitionsListSample.ts][workflowrunactionrepetitionslistsample] | Get all of a workflow run action repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_List.json | +| [workflowRunActionRepetitionsRequestHistoriesGetSample.ts][workflowrunactionrepetitionsrequesthistoriesgetsample] | Gets a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json | +| [workflowRunActionRepetitionsRequestHistoriesListSample.ts][workflowrunactionrepetitionsrequesthistorieslistsample] | List a workflow run repetition request history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json | +| [workflowRunActionScopeRepetitionsGetSample.ts][workflowrunactionscoperepetitionsgetsample] | Get a workflow run action scoped repetition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_Get.json | +| [workflowRunActionScopeRepetitionsListSample.ts][workflowrunactionscoperepetitionslistsample] | List the workflow run action scoped repetitions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_List.json | +| [workflowRunActionsGetSample.ts][workflowrunactionsgetsample] | Gets a workflow run action. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_Get.json | +| [workflowRunActionsListExpressionTracesSample.ts][workflowrunactionslistexpressiontracessample] | Lists a workflow run expression trace. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_ListExpressionTraces.json | +| [workflowRunActionsListSample.ts][workflowrunactionslistsample] | Gets a list of workflow run actions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_List.json | +| [workflowRunsCancelSample.ts][workflowrunscancelsample] | Cancels a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Cancel.json | +| [workflowRunsGetSample.ts][workflowrunsgetsample] | Gets a workflow run. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Get.json | +| [workflowRunsListSample.ts][workflowrunslistsample] | Gets a list of workflow runs. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_List.json | +| [workflowTriggerHistoriesGetSample.ts][workflowtriggerhistoriesgetsample] | Gets a workflow trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Get.json | +| [workflowTriggerHistoriesListSample.ts][workflowtriggerhistorieslistsample] | Gets a list of workflow trigger histories. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_List.json | +| [workflowTriggerHistoriesResubmitSample.ts][workflowtriggerhistoriesresubmitsample] | Resubmits a workflow run based on the trigger history. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Resubmit.json | +| [workflowTriggersGetSample.ts][workflowtriggersgetsample] | Gets a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Get.json | +| [workflowTriggersGetSchemaJsonSample.ts][workflowtriggersgetschemajsonsample] | Get the trigger schema as JSON. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_GetSchemaJson.json | +| [workflowTriggersListCallbackUrlSample.ts][workflowtriggerslistcallbackurlsample] | Get the callback URL for a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_ListCallbackUrl.json | +| [workflowTriggersListSample.ts][workflowtriggerslistsample] | Gets a list of workflow triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_List.json | +| [workflowTriggersRunSample.ts][workflowtriggersrunsample] | Runs a workflow trigger. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Run.json | +| [workflowVersionsGetSample.ts][workflowversionsgetsample] | Gets a workflow version. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_Get.json | +| [workflowVersionsListSample.ts][workflowversionslistsample] | Gets a list of workflow versions. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_List.json | +| [workflowsRegenerateAccessKeySample.ts][workflowsregenerateaccesskeysample] | Regenerates the callback URL access key for request triggers. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_RegenerateAccessKey.json | +| [workflowsValidateSample.ts][workflowsvalidatesample] | Validates the workflow definition. x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_Validate.json | + +## Prerequisites + +The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule). + +Before running the samples in Node, they must be compiled to JavaScript using the TypeScript compiler. For more information on TypeScript, see the [TypeScript documentation][typescript]. Install the TypeScript compiler using: + +```bash +npm install -g typescript +``` + +You need [an Azure subscription][freesub] to run these sample programs. + +Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function. + +Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package]. + +## Setup + +To run the samples using the published version of the package: + +1. Install the dependencies using `npm`: + +```bash +npm install +``` + +2. Compile the samples: + +```bash +npm run build +``` + +3. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically. + +4. Run whichever samples you like (note that some samples may require additional setup, see the table above): + +```bash +node dist/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +``` + +Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): + +```bash +npx cross-env APPSERVICE_SUBSCRIPTION_ID="" APPSERVICE_RESOURCE_GROUP="" node dist/appServiceCertificateOrdersCreateOrUpdateCertificateSample.js +``` + +## Next Steps + +Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. + +[appservicecertificateorderscreateorupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts +[appservicecertificateorderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts +[appservicecertificateordersdeletecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts +[appservicecertificateordersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteSample.ts +[appservicecertificateordersgetcertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts +[appservicecertificateordersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetSample.ts +[appservicecertificateorderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts +[appservicecertificateorderslistcertificatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts +[appservicecertificateorderslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListSample.ts +[appservicecertificateordersreissuesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersReissueSample.ts +[appservicecertificateordersrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRenewSample.ts +[appservicecertificateordersresendemailsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendEmailSample.ts +[appservicecertificateordersresendrequestemailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts +[appservicecertificateordersretrievecertificateactionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts +[appservicecertificateordersretrievecertificateemailhistorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts +[appservicecertificateordersretrievesitesealsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts +[appservicecertificateordersupdatecertificatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts +[appservicecertificateordersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateSample.ts +[appservicecertificateordersvalidatepurchaseinformationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts +[appservicecertificateordersverifydomainownershipsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts +[appserviceenvironmentsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts +[appserviceenvironmentschangevnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsChangeVnetSample.ts +[appserviceenvironmentscreateorupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts +[appserviceenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts +[appserviceenvironmentscreateorupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts +[appserviceenvironmentsdeleteasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts +[appserviceenvironmentsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts +[appserviceenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteSample.ts +[appserviceenvironmentsgetasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts +[appserviceenvironmentsgetasev3networkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts +[appserviceenvironmentsgetdiagnosticsitemsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts +[appserviceenvironmentsgetinboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts +[appserviceenvironmentsgetmultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts +[appserviceenvironmentsgetoutboundnetworkdependenciesendpointssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts +[appserviceenvironmentsgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts +[appserviceenvironmentsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts +[appserviceenvironmentsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts +[appserviceenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetSample.ts +[appserviceenvironmentsgetvipinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts +[appserviceenvironmentsgetworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts +[appserviceenvironmentslistappserviceplanssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts +[appserviceenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts +[appserviceenvironmentslistcapacitiessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts +[appserviceenvironmentslistdiagnosticssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts +[appserviceenvironmentslistmultirolemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts +[appserviceenvironmentslistmultirolepoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts +[appserviceenvironmentslistmultirolepoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts +[appserviceenvironmentslistmultirolepoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts +[appserviceenvironmentslistmultiroleusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts +[appserviceenvironmentslistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListOperationsSample.ts +[appserviceenvironmentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListSample.ts +[appserviceenvironmentslistusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListUsagesSample.ts +[appserviceenvironmentslistwebappssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebAppsSample.ts +[appserviceenvironmentslistwebworkermetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts +[appserviceenvironmentslistwebworkerusagessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts +[appserviceenvironmentslistworkerpoolinstancemetricdefinitionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts +[appserviceenvironmentslistworkerpoolskussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts +[appserviceenvironmentslistworkerpoolssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts +[appserviceenvironmentsrebootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsRebootSample.ts +[appserviceenvironmentsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsResumeSample.ts +[appserviceenvironmentssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsSuspendSample.ts +[appserviceenvironmentstestupgradeavailablenotificationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts +[appserviceenvironmentsupdateasecustomdnssuffixconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts +[appserviceenvironmentsupdateasenetworkingconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts +[appserviceenvironmentsupdatemultirolepoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts +[appserviceenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateSample.ts +[appserviceenvironmentsupdateworkerpoolsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts +[appserviceenvironmentsupgradesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpgradeSample.ts +[appserviceplanscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansCreateOrUpdateSample.ts +[appserviceplansdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansDeleteSample.ts +[appserviceplansgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansGetSample.ts +[appserviceplanslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListByResourceGroupSample.ts +[appserviceplanslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListSample.ts +[appserviceplansupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansUpdateSample.ts +[certificateordersdiagnosticsgetappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts +[certificateordersdiagnosticslistappservicecertificateorderdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts +[certificateregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateRegistrationProviderListOperationsSample.ts +[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesCreateOrUpdateSample.ts +[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesDeleteSample.ts +[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesGetSample.ts +[certificateslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListByResourceGroupSample.ts +[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListSample.ts +[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesUpdateSample.ts +[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsCreateOrUpdateSample.ts +[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsDeleteSample.ts +[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsGetSample.ts +[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListByResourceGroupSample.ts +[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListBySubscriptionSample.ts +[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListSecretsSample.ts +[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsActivateRevisionSample.ts +[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts +[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsGetRevisionSample.ts +[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsListRevisionsSample.ts +[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsRestartRevisionSample.ts +[deletedwebappsgetdeletedwebappbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts +[deletedwebappslistbylocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsListByLocationSample.ts +[diagnosticsexecutesiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts +[diagnosticsexecutesiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts +[diagnosticsexecutesitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSample.ts +[diagnosticsexecutesitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts +[diagnosticsgethostingenvironmentdetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts +[diagnosticsgetsiteanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSample.ts +[diagnosticsgetsiteanalysisslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts +[diagnosticsgetsitedetectorresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts +[diagnosticsgetsitedetectorresponseslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts +[diagnosticsgetsitedetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSample.ts +[diagnosticsgetsitedetectorslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts +[diagnosticsgetsitediagnosticcategorysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts +[diagnosticsgetsitediagnosticcategoryslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts +[diagnosticslisthostingenvironmentdetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts +[diagnosticslistsiteanalysessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSample.ts +[diagnosticslistsiteanalysesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts +[diagnosticslistsitedetectorresponsessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts +[diagnosticslistsitedetectorresponsesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts +[diagnosticslistsitedetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSample.ts +[diagnosticslistsitedetectorsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts +[diagnosticslistsitediagnosticcategoriessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts +[diagnosticslistsitediagnosticcategoriesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts +[domainregistrationproviderlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainRegistrationProviderListOperationsSample.ts +[domainscheckavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCheckAvailabilitySample.ts +[domainscreateorupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts +[domainscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateSample.ts +[domainsdeleteownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteOwnershipIdentifierSample.ts +[domainsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteSample.ts +[domainsgetcontrolcenterssorequestsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetControlCenterSsoRequestSample.ts +[domainsgetownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetOwnershipIdentifierSample.ts +[domainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetSample.ts +[domainslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListByResourceGroupSample.ts +[domainslistownershipidentifierssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListOwnershipIdentifiersSample.ts +[domainslistrecommendationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListRecommendationsSample.ts +[domainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListSample.ts +[domainsrenewsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsRenewSample.ts +[domainstransferoutsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsTransferOutSample.ts +[domainsupdateownershipidentifiersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateOwnershipIdentifierSample.ts +[domainsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateSample.ts +[globalgetdeletedwebappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSample.ts +[globalgetdeletedwebappsnapshotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts +[globalgetsubscriptionoperationwithasyncresponsesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts +[kubeenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts +[kubeenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsDeleteSample.ts +[kubeenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsGetSample.ts +[kubeenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts +[kubeenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts +[kubeenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsUpdateSample.ts +[listcustomhostnamesitessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/listCustomHostNameSitesSample.ts +[providergetfunctionappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksForLocationSample.ts +[providergetfunctionappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksSample.ts +[providergetwebappstacksforlocationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksForLocationSample.ts +[providergetwebappstackssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksSample.ts +[providerlistoperationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerListOperationsSample.ts +[resourcehealthmetadatagetbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSample.ts +[resourcehealthmetadatagetbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts +[resourcehealthmetadatalistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts +[resourcehealthmetadatalistbysitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSample.ts +[resourcehealthmetadatalistbysiteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts +[resourcehealthmetadatalistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListSample.ts +[staticsitesapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts +[staticsitescreateorupdatebasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBasicAuthSample.ts +[staticsitescreateorupdatebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts +[staticsitescreateorupdatedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateDatabaseConnectionSample.ts +[staticsitescreateorupdatestaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts +[staticsitescreateorupdatestaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts +[staticsitescreateorupdatestaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts +[staticsitescreateorupdatestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts +[staticsitescreateorupdatestaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts +[staticsitescreateorupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts +[staticsitescreateuserrolesinvitationlinksample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts +[staticsitescreatezipdeploymentforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts +[staticsitescreatezipdeploymentforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts +[staticsitesdeletebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteBuildDatabaseConnectionSample.ts +[staticsitesdeletedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteDatabaseConnectionSample.ts +[staticsitesdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts +[staticsitesdeletestaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts +[staticsitesdeletestaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts +[staticsitesdeletestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteSample.ts +[staticsitesdeletestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteUserSample.ts +[staticsitesdetachstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachStaticSiteSample.ts +[staticsitesdetachuserprovidedfunctionappfromstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts +[staticsitesdetachuserprovidedfunctionappfromstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts +[staticsitesgetbasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBasicAuthSample.ts +[staticsitesgetbuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionSample.ts +[staticsitesgetbuilddatabaseconnectionwithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts +[staticsitesgetbuilddatabaseconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsSample.ts +[staticsitesgetbuilddatabaseconnectionswithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts +[staticsitesgetdatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionSample.ts +[staticsitesgetdatabaseconnectionwithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionWithDetailsSample.ts +[staticsitesgetdatabaseconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsSample.ts +[staticsitesgetdatabaseconnectionswithdetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsWithDetailsSample.ts +[staticsitesgetlinkedbackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts +[staticsitesgetlinkedbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendSample.ts +[staticsitesgetlinkedbackendsforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts +[staticsitesgetlinkedbackendssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsSample.ts +[staticsitesgetprivateendpointconnectionlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts +[staticsitesgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts +[staticsitesgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts +[staticsitesgetstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildSample.ts +[staticsitesgetstaticsitebuildssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildsSample.ts +[staticsitesgetstaticsitecustomdomainsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts +[staticsitesgetstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteSample.ts +[staticsitesgetstaticsitesbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts +[staticsitesgetuserprovidedfunctionappforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts +[staticsitesgetuserprovidedfunctionappforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts +[staticsitesgetuserprovidedfunctionappsforstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts +[staticsitesgetuserprovidedfunctionappsforstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts +[staticsiteslinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendSample.ts +[staticsiteslinkbackendtobuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendToBuildSample.ts +[staticsiteslistbasicauthsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListBasicAuthSample.ts +[staticsiteslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListSample.ts +[staticsitesliststaticsiteappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts +[staticsitesliststaticsitebuildappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts +[staticsitesliststaticsitebuildfunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts +[staticsitesliststaticsitebuildfunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts +[staticsitesliststaticsiteconfiguredrolessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts +[staticsitesliststaticsitecustomdomainssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts +[staticsitesliststaticsitefunctionappsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts +[staticsitesliststaticsitefunctionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionsSample.ts +[staticsitesliststaticsitesecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteSecretsSample.ts +[staticsitesliststaticsiteuserssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteUsersSample.ts +[staticsitespreviewworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesPreviewWorkflowSample.ts +[staticsitesregisteruserprovidedfunctionappwithstaticsitebuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts +[staticsitesregisteruserprovidedfunctionappwithstaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts +[staticsitesresetstaticsiteapikeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesResetStaticSiteApiKeySample.ts +[staticsitesunlinkbackendfrombuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts +[staticsitesunlinkbackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendSample.ts +[staticsitesupdatebuilddatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateBuildDatabaseConnectionSample.ts +[staticsitesupdatedatabaseconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateDatabaseConnectionSample.ts +[staticsitesupdatestaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteSample.ts +[staticsitesupdatestaticsiteusersample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteUserSample.ts +[staticsitesvalidatebackendforbuildsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendForBuildSample.ts +[staticsitesvalidatebackendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendSample.ts +[staticsitesvalidatecustomdomaincanbeaddedtostaticsitesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts +[topleveldomainsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsGetSample.ts +[topleveldomainslistagreementssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListAgreementsSample.ts +[topleveldomainslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListSample.ts +[verifyhostingenvironmentvnetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/verifyHostingEnvironmentVnetSample.ts +[webappsanalyzecustomhostnamesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSample.ts +[webappsanalyzecustomhostnameslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSlotSample.ts +[webappsapplyslotconfigtoproductionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApplySlotConfigToProductionSample.ts +[webappsapproveorrejectprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts +[webappsapproveorrejectprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts +[webappsbackupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsBackupSample.ts +[webappscreateorupdateconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateConfigurationSample.ts +[webappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSample.ts +[webappscreateorupdateslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSlotSample.ts +[webappsdeletebackupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteBackupSample.ts +[webappsdeleteprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts +[webappsdeleteprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts +[webappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSample.ts +[webappsdeleteslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSlotSample.ts +[webappsdeployworkflowartifactssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSample.ts +[webappsdeployworkflowartifactsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSlotSample.ts +[webappsgetappsettingkeyvaultreferencesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts +[webappsgetappsettingkeyvaultreferenceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts +[webappsgetappsettingskeyvaultreferencessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts +[webappsgetappsettingskeyvaultreferencesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts +[webappsgetauthsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsSample.ts +[webappsgetauthsettingsv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2Sample.ts +[webappsgetauthsettingsv2withoutsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2WithoutSecretsSample.ts +[webappsgetbackupstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetBackupStatusSample.ts +[webappsgetconfigurationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetConfigurationSample.ts +[webappsgetftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSample.ts +[webappsgetftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSlotSample.ts +[webappsgetinstanceinfosample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSample.ts +[webappsgetinstanceinfoslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSlotSample.ts +[webappsgetinstanceworkflowslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceWorkflowSlotSample.ts +[webappsgetnetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSample.ts +[webappsgetnetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts +[webappsgetnetworktraceoperationslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts +[webappsgetnetworktraceoperationv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts +[webappsgetnetworktracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSample.ts +[webappsgetnetworktracesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotSample.ts +[webappsgetnetworktracesslotv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts +[webappsgetnetworktracesv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesV2Sample.ts +[webappsgetprivateendpointconnectionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts +[webappsgetprivateendpointconnectionslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts +[webappsgetprivatelinkresourcessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSample.ts +[webappsgetprivatelinkresourcesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts +[webappsgetproductionsitedeploymentstatussample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts +[webappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSample.ts +[webappsgetscmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSample.ts +[webappsgetscmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSlotSample.ts +[webappsgetslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSample.ts +[webappsgetslotsitedeploymentstatusslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts +[webappsgetworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetWorkflowSample.ts +[webappslistapplicationsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListApplicationSettingsSample.ts +[webappslistbackupstatussecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupStatusSecretsSample.ts +[webappslistbackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupsSample.ts +[webappslistbasicpublishingcredentialspoliciessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts +[webappslistbasicpublishingcredentialspoliciesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts +[webappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListByResourceGroupSample.ts +[webappslistconfigurationssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListConfigurationsSample.ts +[webappslistinstanceworkflowsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListInstanceWorkflowsSlotSample.ts +[webappslistproductionsitedeploymentstatusessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts +[webappslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSample.ts +[webappslistsitebackupssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSample.ts +[webappslistsitebackupsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSlotSample.ts +[webappslistslotsitedeploymentstatusesslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts +[webappslistslotssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotsSample.ts +[webappslistworkflowsconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSample.ts +[webappslistworkflowsconnectionsslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSlotSample.ts +[webappslistworkflowssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsSample.ts +[webappsrestoresample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsRestoreSample.ts +[webappsstartnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSample.ts +[webappsstartnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSlotSample.ts +[webappsstartwebsitenetworktraceoperationsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts +[webappsstartwebsitenetworktraceoperationslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts +[webappsstopnetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSample.ts +[webappsstopnetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSlotSample.ts +[webappsstopwebsitenetworktracesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts +[webappsstopwebsitenetworktraceslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts +[webappsupdateapplicationsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateApplicationSettingsSample.ts +[webappsupdateauthsettingssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsSample.ts +[webappsupdateauthsettingsv2sample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsV2Sample.ts +[webappsupdateazurestorageaccountssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAzureStorageAccountsSample.ts +[webappsupdateftpallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSample.ts +[webappsupdateftpallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts +[webappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSample.ts +[webappsupdatescmallowedsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSample.ts +[webappsupdatescmallowedslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSlotSample.ts +[webappsupdateslotsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSlotSample.ts +[workflowrunactionrepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsGetSample.ts +[workflowrunactionrepetitionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts +[workflowrunactionrepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListSample.ts +[workflowrunactionrepetitionsrequesthistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts +[workflowrunactionrepetitionsrequesthistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts +[workflowrunactionscoperepetitionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts +[workflowrunactionscoperepetitionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsListSample.ts +[workflowrunactionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsGetSample.ts +[workflowrunactionslistexpressiontracessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListExpressionTracesSample.ts +[workflowrunactionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListSample.ts +[workflowrunscancelsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsCancelSample.ts +[workflowrunsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsGetSample.ts +[workflowrunslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsListSample.ts +[workflowtriggerhistoriesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesGetSample.ts +[workflowtriggerhistorieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesListSample.ts +[workflowtriggerhistoriesresubmitsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesResubmitSample.ts +[workflowtriggersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSample.ts +[workflowtriggersgetschemajsonsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSchemaJsonSample.ts +[workflowtriggerslistcallbackurlsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListCallbackUrlSample.ts +[workflowtriggerslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListSample.ts +[workflowtriggersrunsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersRunSample.ts +[workflowversionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsGetSample.ts +[workflowversionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsListSample.ts +[workflowsregenerateaccesskeysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsRegenerateAccessKeySample.ts +[workflowsvalidatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsValidateSample.ts +[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-appservice?view=azure-node-preview +[freesub]: https://azure.microsoft.com/free/ +[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice/README.md +[typescript]: https://www.typescriptlang.org/docs/home.html diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/package.json b/sdk/appservice/arm-appservice/samples/v14/typescript/package.json similarity index 97% rename from sdk/appservice/arm-appservice/samples/v13/typescript/package.json rename to sdk/appservice/arm-appservice/samples/v14/typescript/package.json index 578162455f21..8324b5b9c78f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/package.json +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/package.json @@ -35,7 +35,7 @@ }, "devDependencies": { "@types/node": "^14.0.0", - "typescript": "~4.4.0", + "typescript": "~4.8.0", "rimraf": "latest" } } diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/sample.env b/sdk/appservice/arm-appservice/samples/v14/typescript/sample.env similarity index 100% rename from sdk/appservice/arm-appservice/samples/v13/typescript/sample.env rename to sdk/appservice/arm-appservice/samples/v14/typescript/sample.env diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts index acf62a99a3da..cd6d4818638e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateCertificateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificate.json */ async function createCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate: AppServiceCertificateResource = { @@ -42,4 +48,8 @@ async function createCertificate() { console.log(result); } -createCertificate().catch(console.error); +async function main() { + createCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts similarity index 82% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts index 7499b4b43629..25bf1e810e06 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersCreateOrUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/CreateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/CreateAppServiceCertificateOrder.json */ async function createCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName: AppServiceCertificateOrder = { autoRenew: true, @@ -54,4 +60,8 @@ async function createCertificateOrder() { console.log(result); } -createCertificateOrder().catch(console.error); +async function main() { + createCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts new file mode 100644 index 000000000000..b32252ef0c6d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteCertificateSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete the certificate associated with a certificate order. + * + * @summary Description for Delete the certificate associated with a certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificate.json + */ +async function deleteAppServiceCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const name = "SampleCertName1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.deleteCertificate( + resourceGroupName, + certificateOrderName, + name + ); + console.log(result); +} + +async function main() { + deleteAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteSample.ts new file mode 100644 index 000000000000..a000c0e45243 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersDeleteSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete an existing certificate order. + * + * @summary Description for Delete an existing certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/DeleteAppServiceCertificateOrder.json + */ +async function deleteAppServiceCertificateOrder() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.delete( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + deleteAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts new file mode 100644 index 000000000000..22fc06a06de7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetCertificateSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the certificate associated with a certificate order. + * + * @summary Description for Get the certificate associated with a certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificate.json + */ +async function getAppServiceCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const name = "SampleCertName1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.getCertificate( + resourceGroupName, + certificateOrderName, + name + ); + console.log(result); +} + +async function main() { + getAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetSample.ts new file mode 100644 index 000000000000..6254d66de3bb --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersGetSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get a certificate order. + * + * @summary Description for Get a certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/GetAppServiceCertificateOrder.json + */ +async function getAppServiceCertificateOrder() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.get( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + getAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts new file mode 100644 index 000000000000..313779edd359 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get certificate orders in a resource group. + * + * @summary Description for Get certificate orders in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersByResourceGroup.json + */ +async function listAppServiceCertificateOrdersByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceCertificateOrders.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppServiceCertificateOrdersByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts new file mode 100644 index 000000000000..69e1cd47adc4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListCertificatesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List all certificates associated with a certificate order. + * + * @summary Description for List all certificates associated with a certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListCertificatesByAppServiceCertificateOrder.json + */ +async function listCertificatesByAppServiceCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceCertificateOrders.listCertificates( + resourceGroupName, + certificateOrderName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listCertificatesByAppServiceCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListSample.ts index 5a98b07d23b9..47774c306cc1 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all certificate orders in a subscription. * * @summary Description for List all certificate orders in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListAppServiceCertificateOrdersBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListAppServiceCertificateOrdersBySubscription.json */ async function listAppServiceCertificateOrdersBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listAppServiceCertificateOrdersBySubscription() { console.log(resArray); } -listAppServiceCertificateOrdersBySubscription().catch(console.error); +async function main() { + listAppServiceCertificateOrdersBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersReissueSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersReissueSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersReissueSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersReissueSample.ts index cba9fe28aff1..2a1649d30b74 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersReissueSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersReissueSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Reissue an existing certificate order. * * @summary Description for Reissue an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ReissueAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ReissueAppServiceCertificateOrder.json */ async function reissueAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const reissueCertificateOrderRequest: ReissueCertificateOrderRequest = { csr: "CSR1223238Value", @@ -40,4 +46,8 @@ async function reissueAppServiceCertificateOrder() { console.log(result); } -reissueAppServiceCertificateOrder().catch(console.error); +async function main() { + reissueAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRenewSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRenewSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRenewSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRenewSample.ts index eacf061fd3bf..7f1f6bf78321 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRenewSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRenewSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Renew an existing certificate order. * * @summary Description for Renew an existing certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RenewAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RenewAppServiceCertificateOrder.json */ async function renewAppServiceCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const renewCertificateOrderRequest: RenewCertificateOrderRequest = { csr: "CSR1223238Value", @@ -39,4 +45,8 @@ async function renewAppServiceCertificateOrder() { console.log(result); } -renewAppServiceCertificateOrder().catch(console.error); +async function main() { + renewAppServiceCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendEmailSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendEmailSample.ts new file mode 100644 index 000000000000..2bed7e6e7dc3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendEmailSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Resend certificate email. + * + * @summary Description for Resend certificate email. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendAppServiceCertificateOrderEmail.json + */ +async function resendAppServiceCertificateOrderEmail() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.resendEmail( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + resendAppServiceCertificateOrderEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts index b4fbc327641a..410878d361f0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersResendRequestEmailsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { NameIdentifier, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order * * @summary Resend domain verification ownership email containing steps on how to verify a domain for a given certificate order - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ResendDomainOwnershipVerificationEmail.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ResendDomainOwnershipVerificationEmail.json */ async function resendDomainOwnershipVerificationEmail() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const nameIdentifier: NameIdentifier = { name: "Domain name" }; const credential = new DefaultAzureCredential(); @@ -32,4 +38,8 @@ async function resendDomainOwnershipVerificationEmail() { console.log(result); } -resendDomainOwnershipVerificationEmail().catch(console.error); +async function main() { + resendDomainOwnershipVerificationEmail(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts new file mode 100644 index 000000000000..ec2a839de825 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateActionsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Retrieve the list of certificate actions. + * + * @summary Description for Retrieve the list of certificate actions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateOrderActions.json + */ +async function retrieveCertificateOrderActions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleCertOrder"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.retrieveCertificateActions( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + retrieveCertificateOrderActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts new file mode 100644 index 000000000000..f1fbb9d74af3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveCertificateEmailHistorySample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Retrieve email history. + * + * @summary Description for Retrieve email history. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveCertificateEmailHistory.json + */ +async function retrieveCertificateEmailHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleCertOrder"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.retrieveCertificateEmailHistory( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + retrieveCertificateEmailHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts similarity index 85% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts index 0d7db52b0fe6..aea65a1d6d6b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersRetrieveSiteSealSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. * * @summary This method is used to obtain the site seal information for an issued certificate. A site seal is a graphic that the certificate purchaser can embed on their web site to show their visitors information about their SSL certificate. If a web site visitor clicks on the site seal image, a pop-up page is displayed that contains detailed information about the SSL certificate. The site seal token is used to link the site seal graphic image to the appropriate certificate details pop-up page display when a user clicks on the site seal. The site seal images are expected to be static images and hosted by the reseller, to minimize delays for customer page load times. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/RetrieveSiteSeal.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/RetrieveSiteSeal.json */ async function retrieveSiteSeal() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertOrder"; const siteSealRequest: SiteSealRequest = { lightTheme: true, @@ -38,4 +44,8 @@ async function retrieveSiteSeal() { console.log(result); } -retrieveSiteSeal().catch(console.error); +async function main() { + retrieveSiteSeal(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts index 1c706b2e95b5..a1da6f0cb4cb 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateCertificateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a certificate and associates with key vault secret. * * @summary Description for Creates or updates a certificate and associates with key vault secret. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificate.json */ async function updateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const name = "SampleCertName1"; const keyVaultCertificate: AppServiceCertificatePatchResource = { @@ -41,4 +47,8 @@ async function updateCertificate() { console.log(result); } -updateCertificate().catch(console.error); +async function main() { + updateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateSample.ts similarity index 82% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateSample.ts index 4dd2967027c4..4687c83e3651 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a certificate purchase order. * * @summary Description for Create or update a certificate purchase order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/UpdateAppServiceCertificateOrder.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/UpdateAppServiceCertificateOrder.json */ async function updateCertificateOrder() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const certificateOrderName = "SampleCertificateOrderName"; const certificateDistinguishedName: AppServiceCertificateOrderPatchResource = { autoRenew: true, @@ -53,4 +59,8 @@ async function updateCertificateOrder() { console.log(result); } -updateCertificateOrder().catch(console.error); +async function main() { + updateCertificateOrder(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts similarity index 84% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts index a984eb8d27a4..b750acdaa5c0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersValidatePurchaseInformationSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Validate information for a certificate order. * * @summary Description for Validate information for a certificate order. - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ValidateAppServiceCertificatePurchaseInformationBySubscription.json */ async function validateAppServiceCertificatePurchaseInformationBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const appServiceCertificateOrder: AppServiceCertificateOrder = { autoRenew: true, certificates: { @@ -50,6 +55,8 @@ async function validateAppServiceCertificatePurchaseInformationBySubscription() console.log(result); } -validateAppServiceCertificatePurchaseInformationBySubscription().catch( - console.error -); +async function main() { + validateAppServiceCertificatePurchaseInformationBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts new file mode 100644 index 000000000000..09f9649b69ec --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceCertificateOrdersVerifyDomainOwnershipSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Verify domain ownership for this certificate order. + * + * @summary Description for Verify domain ownership for this certificate order. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/VerifyDomainOwnership.json + */ +async function verifyDomainOwnership() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceCertificateOrders.verifyDomainOwnership( + resourceGroupName, + certificateOrderName + ); + console.log(result); +} + +async function main() { + verifyDomainOwnership(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts index 2bd1f6456589..41e7232b0bc9 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ApproveOrRejectPrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnection() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -42,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnection() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnection().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsChangeVnetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsChangeVnetSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsChangeVnetSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsChangeVnetSample.ts index 2d21f0f74ba0..7c68a5cd34ae 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsChangeVnetSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsChangeVnetSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Move an App Service Environment to a different VNET. * * @summary Description for Move an App Service Environment to a different VNET. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ChangeVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ChangeVnet.json */ async function moveAnAppServiceEnvironmentToADifferentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const vnetInfo: VirtualNetworkProfile = { id: @@ -41,4 +47,8 @@ async function moveAnAppServiceEnvironmentToADifferentVnet() { console.log(resArray); } -moveAnAppServiceEnvironmentToADifferentVnet().catch(console.error); +async function main() { + moveAnAppServiceEnvironmentToADifferentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts new file mode 100644 index 000000000000..3184f29c330f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateMultiRolePoolSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkerPoolResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a multi-role pool. + * + * @summary Description for Create or update a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + */ +async function createOrUpdateAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const multiRolePoolEnvelope: WorkerPoolResource = { + workerCount: 3, + workerSize: "Medium" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginCreateOrUpdateMultiRolePoolAndWait( + resourceGroupName, + name, + multiRolePoolEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts index a7dde7c05402..e9ed5ac17811 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_CreateOrUpdate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdate.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope: AppServiceEnvironmentResource = { kind: "Asev3", @@ -42,4 +48,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts new file mode 100644 index 000000000000..5ba2fa250fa7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsCreateOrUpdateWorkerPoolSample.ts @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkerPoolResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a worker pool. + * + * @summary Description for Create or update a worker pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + */ +async function getPropertiesOfAWorkerPool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "0"; + const workerPoolEnvelope: WorkerPoolResource = { + workerCount: 3, + workerSize: "Small" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginCreateOrUpdateWorkerPoolAndWait( + resourceGroupName, + name, + workerPoolName, + workerPoolEnvelope + ); + console.log(result); +} + +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts new file mode 100644 index 000000000000..2d3cba0b2dd3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteAseCustomDnsSuffixConfigurationSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Delete Custom Dns Suffix configuration of an App Service Environment + * + * @summary Delete Custom Dns Suffix configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAseCustomDnsSuffixConfiguration.json + */ +async function deleteAseCustomDnsSuffixConfiguration() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.deleteAseCustomDnsSuffixConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..b740a212c515 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeletePrivateEndpointConnectionSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_DeletePrivateEndpointConnection.json + */ +async function deletesAPrivateEndpointConnection() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginDeletePrivateEndpointConnectionAndWait( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + deletesAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteSample.ts new file mode 100644 index 000000000000..ff955f26b1e9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsDeleteSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete an App Service Environment. + * + * @summary Description for Delete an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Delete.json + */ +async function deleteAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginDeleteAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts new file mode 100644 index 000000000000..994754b73915 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseCustomDnsSuffixConfigurationSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get Custom Dns Suffix configuration of an App Service Environment + * + * @summary Get Custom Dns Suffix configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAseCustomDnsSuffixConfiguration.json + */ +async function getAseCustomDnsSuffixConfiguration() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getAseCustomDnsSuffixConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts new file mode 100644 index 000000000000..41b5c16efc24 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetAseV3NetworkingConfigurationSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get networking configuration of an App Service Environment + * + * @summary Description for Get networking configuration of an App Service Environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetAseV3NetworkingConfiguration.json + */ +async function getNetworkingConfigurationOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getAseV3NetworkingConfiguration( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts new file mode 100644 index 000000000000..77eab217ef94 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetDiagnosticsItemSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get a diagnostics item for an App Service Environment. + * + * @summary Description for Get a diagnostics item for an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetDiagnosticsItem.json + */ +async function getADiagnosticsItemForAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const diagnosticsName = "test-diagnostic"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getDiagnosticsItem( + resourceGroupName, + name, + diagnosticsName + ); + console.log(result); +} + +async function main() { + getADiagnosticsItemForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts new file mode 100644 index 000000000000..9e159d846f0c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetInboundNetworkDependenciesEndpointsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the network endpoints of all inbound dependencies of an App Service Environment. + * + * @summary Description for Get the network endpoints of all inbound dependencies of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetInboundNetworkDependenciesEndpoints.json + */ +async function getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAse"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listInboundNetworkDependenciesEndpoints( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheNetworkEndpointsOfAllInboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts new file mode 100644 index 000000000000..6bcf465e1524 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetMultiRolePoolSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get properties of a multi-role pool. + * + * @summary Description for Get properties of a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetMultiRolePool.json + */ +async function getPropertiesOfAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getMultiRolePool( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getPropertiesOfAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts new file mode 100644 index 000000000000..8abf6a516823 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetOutboundNetworkDependenciesEndpointsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the network endpoints of all outbound dependencies of an App Service Environment. + * + * @summary Description for Get the network endpoints of all outbound dependencies of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetOutboundNetworkDependenciesEndpoints.json + */ +async function getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAse"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listOutboundNetworkDependenciesEndpoints( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheNetworkEndpointsOfAllOutboundDependenciesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts new file mode 100644 index 000000000000..f3d76232323e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionListSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the list of private endpoints associated with a hosting environment + * + * @summary Description for Gets the list of private endpoints associated with a hosting environment + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnectionList.json + */ +async function getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listPrivateEndpointConnectionList( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getsTheListOfPrivateEndpointsAssociatedWithAHostingEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..9e9041015f5c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateEndpointConnectionSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateEndpointConnection.json + */ +async function getsAPrivateEndpointConnection() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const privateEndpointConnectionName = "fa38656c-034e-43d8-adce-fe06ce039c98"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getPrivateEndpointConnection( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + getsAPrivateEndpointConnection(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts new file mode 100644 index 000000000000..065c95489ea6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetPrivateLinkResourcesSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetPrivateLinkResources.json + */ +async function getsThePrivateLinkResources() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getPrivateLinkResources( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getsThePrivateLinkResources(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetSample.ts new file mode 100644 index 000000000000..583df5bbfc8d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the properties of an App Service Environment. + * + * @summary Description for Get the properties of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Get.json + */ +async function getThePropertiesOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.get( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getThePropertiesOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts new file mode 100644 index 000000000000..bb6be66e1646 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetVipInfoSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get IP addresses assigned to an App Service Environment. + * + * @summary Description for Get IP addresses assigned to an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetVipInfo.json + */ +async function getIPAddressesAssignedToAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getVipInfo( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getIPAddressesAssignedToAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts new file mode 100644 index 000000000000..bd8eb507c722 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsGetWorkerPoolSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get properties of a worker pool. + * + * @summary Description for Get properties of a worker pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_GetWorkerPool.json + */ +async function getPropertiesOfAWorkerPool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "workerPool1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.getWorkerPool( + resourceGroupName, + name, + workerPoolName + ); + console.log(result); +} + +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts new file mode 100644 index 000000000000..e11c666799d7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListAppServicePlansSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all App Service plans in an App Service Environment. + * + * @summary Description for Get all App Service plans in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListAppServicePlans.json + */ +async function getAllAppServicePlansInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listAppServicePlans( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppServicePlansInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts new file mode 100644 index 000000000000..f565c82b26b2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all App Service Environments in a resource group. + * + * @summary Description for Get all App Service Environments in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListByResourceGroup.json + */ +async function getAllAppServiceEnvironmentsInAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppServiceEnvironmentsInAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts new file mode 100644 index 000000000000..d397ae9b18d9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListCapacitiesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the used, available, and total worker capacity an App Service Environment. + * + * @summary Description for Get the used, available, and total worker capacity an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListCapacities.json + */ +async function getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listCapacities( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getTheUsedAvailableAndTotalWorkerCapacityAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts new file mode 100644 index 000000000000..e197b7e8cb0f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListDiagnosticsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get diagnostic information for an App Service Environment. + * + * @summary Description for Get diagnostic information for an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListDiagnostics.json + */ +async function getDiagnosticInformationForAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.listDiagnostics( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getDiagnosticInformationForAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts new file mode 100644 index 000000000000..4ec594b6850b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleMetricDefinitionsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get metric definitions for a multi-role pool of an App Service Environment. + * + * @summary Description for Get metric definitions for a multi-role pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleMetricDefinitions.json + */ +async function getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRoleMetricDefinitions( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getMetricDefinitionsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts new file mode 100644 index 000000000000..650781118656 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolInstanceMetricDefinitionsSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. + * + * @summary Description for Get metric definitions for a specific instance of a multi-role pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolInstanceMetricDefinitions.json + */ +async function getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const instance = "10.7.1.8"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRolePoolInstanceMetricDefinitions( + resourceGroupName, + name, + instance + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getMetricDefinitionsForASpecificInstanceOfAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts new file mode 100644 index 000000000000..1f1530433615 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolSkusSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get available SKUs for scaling a multi-role pool. + * + * @summary Description for Get available SKUs for scaling a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePoolSkus.json + */ +async function getAvailableSkUsForScalingAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRolePoolSkus( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAvailableSkUsForScalingAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts new file mode 100644 index 000000000000..be8974e3f889 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRolePoolsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all multi-role pools. + * + * @summary Description for Get all multi-role pools. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRolePools.json + */ +async function getAllMultiRolePools() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRolePools( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllMultiRolePools(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts new file mode 100644 index 000000000000..51025f1b6bf3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListMultiRoleUsagesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get usage metrics for a multi-role pool of an App Service Environment. + * + * @summary Description for Get usage metrics for a multi-role pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListMultiRoleUsages.json + */ +async function getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listMultiRoleUsages( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getUsageMetricsForAMultiRolePoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListOperationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListOperationsSample.ts new file mode 100644 index 000000000000..3ad10b91b6f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListOperationsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List all currently running operations on the App Service Environment. + * + * @summary Description for List all currently running operations on the App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListOperations.json + */ +async function listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.listOperations( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAllCurrentlyRunningOperationsOnTheAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListSample.ts index 5e410501d081..16624930c453 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service Environments for a subscription. * * @summary Description for Get all App Service Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_List.json */ async function getAllAppServiceEnvironmentsForASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getAllAppServiceEnvironmentsForASubscription() { console.log(resArray); } -getAllAppServiceEnvironmentsForASubscription().catch(console.error); +async function main() { + getAllAppServiceEnvironmentsForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListUsagesSample.ts new file mode 100644 index 000000000000..d2ad7d985d10 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListUsagesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get global usage metrics of an App Service Environment. + * + * @summary Description for Get global usage metrics of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListUsages.json + */ +async function getGlobalUsageMetricsOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listUsages( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getGlobalUsageMetricsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebAppsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebAppsSample.ts new file mode 100644 index 000000000000..39204abedcfa --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebAppsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all apps in an App Service Environment. + * + * @summary Description for Get all apps in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebApps.json + */ +async function getAllAppsInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWebApps( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllAppsInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts new file mode 100644 index 000000000000..b7c49fb44795 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerMetricDefinitionsSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get metric definitions for a worker pool of an App Service Environment. + * + * @summary Description for Get metric definitions for a worker pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerMetricDefinitions.json + */ +async function getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWebWorkerMetricDefinitions( + resourceGroupName, + name, + workerPoolName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getMetricDefinitionsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts new file mode 100644 index 000000000000..d8093ba6adeb --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWebWorkerUsagesSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get usage metrics for a worker pool of an App Service Environment. + * + * @summary Description for Get usage metrics for a worker pool of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWebWorkerUsages.json + */ +async function getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWebWorkerUsages( + resourceGroupName, + name, + workerPoolName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getUsageMetricsForAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts index 6697e0aa9403..61b0338538d3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolInstanceMetricDefinitionsSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. * * @summary Description for Get metric definitions for a specific instance of a worker pool of an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolInstanceMetricDefinitions.json */ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const workerPoolName = "0"; const instance = "10.8.0.7"; @@ -37,6 +43,8 @@ async function getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServi console.log(resArray); } -getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment().catch( - console.error -); +async function main() { + getMetricDefinitionsForASpecificInstanceOfAWorkerPoolOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts new file mode 100644 index 000000000000..2e38ec565fdd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolSkusSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get available SKUs for scaling a worker pool. + * + * @summary Description for Get available SKUs for scaling a worker pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPoolSkus.json + */ +async function getAvailableSkUsForScalingAWorkerPool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "workerPool1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWorkerPoolSkus( + resourceGroupName, + name, + workerPoolName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAvailableSkUsForScalingAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts new file mode 100644 index 000000000000..d906f74d8c51 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsListWorkerPoolsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all worker pools of an App Service Environment. + * + * @summary Description for Get all worker pools of an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_ListWorkerPools.json + */ +async function getAllWorkerPoolsOfAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.listWorkerPools( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllWorkerPoolsOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsRebootSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsRebootSample.ts new file mode 100644 index 000000000000..c786376320bf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsRebootSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Reboot all machines in an App Service Environment. + * + * @summary Description for Reboot all machines in an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Reboot.json + */ +async function rebootAllMachinesInAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.reboot( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + rebootAllMachinesInAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsResumeSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsResumeSample.ts new file mode 100644 index 000000000000..7995dd0456fe --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsResumeSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Resume an App Service Environment. + * + * @summary Description for Resume an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Resume.json + */ +async function resumeAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.beginListResumeAndWait( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + resumeAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsSuspendSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsSuspendSample.ts new file mode 100644 index 000000000000..b28d3d301e41 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsSuspendSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Suspend an App Service Environment. + * + * @summary Description for Suspend an App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Suspend.json + */ +async function suspendAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServiceEnvironments.beginListSuspendAndWait( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + suspendAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts new file mode 100644 index 000000000000..1a1f089c0778 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsTestUpgradeAvailableNotificationSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Send a test notification that an upgrade is available for this App Service Environment. + * + * @summary Send a test notification that an upgrade is available for this App Service Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_TestUpgradeAvailableNotification.json + */ +async function sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "SampleHostingEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.testUpgradeAvailableNotification( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + sendATestNotificationThatAnUpgradeIsAvailableForThisAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts index 54b0e2024f3c..33437097e47a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseCustomDnsSuffixConfigurationSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Update Custom Dns Suffix configuration of an App Service Environment * * @summary Update Custom Dns Suffix configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateAseCustomDnsSuffixConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAseCustomDnsSuffixConfiguration.json */ async function updateAseCustomDnsSuffixConfiguration() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const customDnsSuffixConfiguration: CustomDnsSuffixConfiguration = { certificateUrl: "https://test-kv.vault.azure.net/secrets/contosocert", @@ -40,4 +46,8 @@ async function updateAseCustomDnsSuffixConfiguration() { console.log(result); } -updateAseCustomDnsSuffixConfiguration().catch(console.error); +async function main() { + updateAseCustomDnsSuffixConfiguration(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts index 4cd7f88e627e..d96aa7f6a9a9 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateAseNetworkingConfigurationSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Update networking configuration of an App Service Environment * * @summary Description for Update networking configuration of an App Service Environment - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_UpdateAseNetworkingConfiguration.json */ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const aseNetworkingConfiguration: AseV3NetworkingConfiguration = { ftpEnabled: true, @@ -38,4 +44,8 @@ async function updateNetworkingConfigurationOfAnAppServiceEnvironment() { console.log(result); } -updateNetworkingConfigurationOfAnAppServiceEnvironment().catch(console.error); +async function main() { + updateNetworkingConfigurationOfAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts new file mode 100644 index 000000000000..dbe7d698c5ec --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateMultiRolePoolSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkerPoolResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a multi-role pool. + * + * @summary Description for Create or update a multi-role pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json + */ +async function createOrUpdateAMultiRolePool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const multiRolePoolEnvelope: WorkerPoolResource = { + workerCount: 3, + workerSize: "Medium" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.updateMultiRolePool( + resourceGroupName, + name, + multiRolePoolEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateAMultiRolePool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateSample.ts index 1a8f72443296..608f7aadb0bc 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServiceEnvironmentsUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update an App Service Environment. * * @summary Description for Create or update an App Service Environment. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/AppServiceEnvironments_Update.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Update.json */ async function createOrUpdateAnAppServiceEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; const name = "test-ase"; const hostingEnvironmentEnvelope: AppServiceEnvironmentPatchResource = { frontEndScaleFactor: 20, @@ -41,4 +47,8 @@ async function createOrUpdateAnAppServiceEnvironment() { console.log(result); } -createOrUpdateAnAppServiceEnvironment().catch(console.error); +async function main() { + createOrUpdateAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts new file mode 100644 index 000000000000..d5bae2349dc9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpdateWorkerPoolSample.ts @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkerPoolResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a worker pool. + * + * @summary Description for Create or update a worker pool. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_CreateOrUpdateWorkerPool.json + */ +async function getPropertiesOfAWorkerPool() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-rg"; + const name = "test-ase"; + const workerPoolName = "0"; + const workerPoolEnvelope: WorkerPoolResource = { + workerCount: 3, + workerSize: "Small" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.updateWorkerPool( + resourceGroupName, + name, + workerPoolName, + workerPoolEnvelope + ); + console.log(result); +} + +async function main() { + getPropertiesOfAWorkerPool(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpgradeSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpgradeSample.ts new file mode 100644 index 000000000000..3837caacf86b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServiceEnvironmentsUpgradeSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Initiate an upgrade of an App Service Environment if one is available. + * + * @summary Description for Initiate an upgrade of an App Service Environment if one is available. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AppServiceEnvironments_Upgrade.json + */ +async function initiateAnUpgradeOnAnAppServiceEnvironment() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "SampleHostingEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServiceEnvironments.beginUpgradeAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + initiateAnUpgradeOnAnAppServiceEnvironment(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansCreateOrUpdateSample.ts new file mode 100644 index 000000000000..f370294e600b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansCreateOrUpdateSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { AppServicePlan, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates an App Service Plan. + * + * @summary Description for Creates or updates an App Service Plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateAppServicePlan.json + */ +async function createOrUpdateAppServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const appServicePlan: AppServicePlan = { + kind: "app", + location: "East US", + sku: { name: "P1", capacity: 1, family: "P", size: "P1", tier: "Premium" } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + appServicePlan + ); + console.log(result); +} + +async function main() { + createOrUpdateAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansDeleteSample.ts new file mode 100644 index 000000000000..84dce044b637 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansDeleteSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete an App Service plan. + * + * @summary Description for Delete an App Service plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteAppServicePlan.json + */ +async function deleteAppServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansGetSample.ts new file mode 100644 index 000000000000..a50b975f8415 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get an App Service plan. + * + * @summary Description for Get an App Service plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAppServicePlan.json + */ +async function getAppServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getAppServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListByResourceGroupSample.ts new file mode 100644 index 000000000000..4ba752300f06 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all App Service plans in a resource group. + * + * @summary Description for Get all App Service plans in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlansByResourceGroup.json + */ +async function listAppServicePlansByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.appServicePlans.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppServicePlansByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListSample.ts index 2048e93e1a8e..5dfb0204cc4f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/appServicePlansListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all App Service plans for a subscription. * * @summary Description for Get all App Service plans for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListAppServicePlans.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppServicePlans.json */ async function listAppServicePlans() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listAppServicePlans() { console.log(resArray); } -listAppServicePlans().catch(console.error); +async function main() { + listAppServicePlans(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansUpdateSample.ts new file mode 100644 index 000000000000..33f8e46b416b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/appServicePlansUpdateSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + AppServicePlanPatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates an App Service Plan. + * + * @summary Description for Creates or updates an App Service Plan. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchAppServicePlan.json + */ +async function patchServicePlan() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsf6141"; + const appServicePlan: AppServicePlanPatchResource = { kind: "app" }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.appServicePlans.update( + resourceGroupName, + name, + appServicePlan + ); + console.log(result); +} + +async function main() { + patchServicePlan(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts new file mode 100644 index 000000000000..c4b15f388a91 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsGetAppServiceCertificateOrderDetectorResponseSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. + * + * @summary Description for Microsoft.CertificateRegistration call to get a detector response from App Lens. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_GetAppServiceCertificateOrderDetectorResponse.json + */ +async function getAppServiceCertificateOrderDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const certificateOrderName = "SampleCertificateOrderName"; + const detectorName = "AutoRenewStatus"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificateOrdersDiagnostics.getAppServiceCertificateOrderDetectorResponse( + resourceGroupName, + certificateOrderName, + detectorName + ); + console.log(result); +} + +async function main() { + getAppServiceCertificateOrderDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts new file mode 100644 index 000000000000..2edccd224880 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateOrdersDiagnosticsListAppServiceCertificateOrderDetectorResponseSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. + * + * @summary Description for Microsoft.CertificateRegistration to get the list of detectors for this RP. + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/Diagnostics_ListAppServiceCertificateOrderDetectorResponse.json + */ +async function listAppServiceCertificateDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "5700fc96-77b4-4f8d-afce-c353d8c443bd"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const certificateOrderName = "SampleCertificateOrderName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.certificateOrdersDiagnostics.listAppServiceCertificateOrderDetectorResponse( + resourceGroupName, + certificateOrderName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppServiceCertificateDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateRegistrationProviderListOperationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateRegistrationProviderListOperationsSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateRegistrationProviderListOperationsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateRegistrationProviderListOperationsSample.ts index f819a6a640df..b62002afacf8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificateRegistrationProviderListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificateRegistrationProviderListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.CertificateRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesCreateOrUpdateSample.ts new file mode 100644 index 000000000000..97b5ef924329 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesCreateOrUpdateSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { Certificate, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a certificate. + * + * @summary Description for Create or update a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateCertificate.json + */ +async function createOrUpdateCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const certificateEnvelope: Certificate = { + hostNames: ["ServerCert"], + location: "East US", + password: "" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.createOrUpdate( + resourceGroupName, + name, + certificateEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesDeleteSample.ts new file mode 100644 index 000000000000..d344f9959c79 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesDeleteSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete a certificate. + * + * @summary Description for Delete a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteCertificate.json + */ +async function deleteCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesGetSample.ts new file mode 100644 index 000000000000..d952721a7349 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get a certificate. + * + * @summary Description for Get a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetCertificate.json + */ +async function getCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListByResourceGroupSample.ts new file mode 100644 index 000000000000..6f25e8c28e31 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all certificates in a resource group. + * + * @summary Description for Get all certificates in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificatesByResourceGroup.json + */ +async function listCertificatesByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.certificates.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listCertificatesByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListSample.ts index 2fdcbc3b6206..64769c9de825 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/certificatesListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all certificates for a subscription. * * @summary Description for Get all certificates for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCertificates.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCertificates.json */ async function listCertificatesForSubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listCertificatesForSubscription() { console.log(resArray); } -listCertificatesForSubscription().catch(console.error); +async function main() { + listCertificatesForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesUpdateSample.ts new file mode 100644 index 000000000000..c82ed000398f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/certificatesUpdateSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + CertificatePatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a certificate. + * + * @summary Description for Create or update a certificate. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchCertificate.json + */ +async function patchCertificate() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const certificateEnvelope: CertificatePatchResource = { + password: "" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.certificates.update( + resourceGroupName, + name, + certificateEnvelope + ); + console.log(result); +} + +async function main() { + patchCertificate(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsCreateOrUpdateSample.ts similarity index 81% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsCreateOrUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsCreateOrUpdateSample.ts index dfaef18bf1f5..1a2458c7324b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsCreateOrUpdateSample.ts @@ -10,16 +10,21 @@ // Licensed under the MIT License. import { ContainerApp, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Create or update a Container App. * * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateContainerApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateContainerApp.json */ async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testcontainerApp0"; const containerAppEnvelope: ContainerApp = { configuration: { ingress: { external: true, targetPort: 3000 } }, @@ -54,4 +59,8 @@ async function createOrUpdateContainerApp() { console.log(result); } -createOrUpdateContainerApp().catch(console.error); +async function main() { + createOrUpdateContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsDeleteSample.ts new file mode 100644 index 000000000000..2e367e589fe1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsDeleteSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete a Container App. + * + * @summary Description for Delete a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteContainerApp.json + */ +async function deleteContainerApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testWorkerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerApps.beginDeleteAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsGetSample.ts new file mode 100644 index 000000000000..53f5820dd6fa --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsGetSample.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get the properties of a Container App. + * + * @summary Get the properties of a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetContainerApp.json + */ +async function getContainerApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testcontainerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerApps.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getContainerApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListByResourceGroupSample.ts new file mode 100644 index 000000000000..112643122573 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListByResourceGroupSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get the Container Apps in a given resource group. + * + * @summary Get the Container Apps in a given resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsByResourceGroup.json + */ +async function listContainerAppsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.containerApps.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListBySubscriptionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListBySubscriptionSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListBySubscriptionSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListBySubscriptionSample.ts index f66567943df3..a16c56377452 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/containerAppsListBySubscriptionSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListBySubscriptionSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get the Container Apps in a given subscription. * * @summary Get the Container Apps in a given subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListContainerAppsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppsBySubscription.json */ async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listContainerAppsByResourceGroup() { console.log(resArray); } -listContainerAppsByResourceGroup().catch(console.error); +async function main() { + listContainerAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListSecretsSample.ts new file mode 100644 index 000000000000..a8b3196ca30e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsListSecretsSample.ts @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List secrets for a container app + * + * @summary List secrets for a container app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListContainerAppSecrets.json + */ +async function listContainerAppsSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const name = "testcontainerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerApps.listSecrets(name); + console.log(result); +} + +async function main() { + listContainerAppsSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsActivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsActivateRevisionSample.ts new file mode 100644 index 000000000000..e70c650b422c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsActivateRevisionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Activates a revision for a Container App + * + * @summary Activates a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ActivateRevision.json + */ +async function activateContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.activateRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + activateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts new file mode 100644 index 000000000000..4e8ae11e6b28 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Deactivates a revision for a Container App + * + * @summary Deactivates a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeactivateRevision.json + */ +async function deactivateContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.deactivateRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + deactivateContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsGetRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsGetRevisionSample.ts new file mode 100644 index 000000000000..b09856b13f67 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsGetRevisionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get a revision of a Container App. + * + * @summary Get a revision of a Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetRevision.json + */ +async function getContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.getRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + getContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsListRevisionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsListRevisionsSample.ts new file mode 100644 index 000000000000..ed67075ee49b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsListRevisionsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get the Revisions for a given Container App. + * + * @summary Get the Revisions for a given Container App. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListRevisions.json + */ +async function listContainerAppRevisions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testcontainerApp0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.containerAppsRevisions.listRevisions( + resourceGroupName, + containerAppName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listContainerAppRevisions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsRestartRevisionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsRestartRevisionSample.ts new file mode 100644 index 000000000000..b06d53d8fbf2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/containerAppsRevisionsRestartRevisionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Restarts a revision for a Container App + * + * @summary Restarts a revision for a Container App + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestartRevision.json + */ +async function restartContainerAppRevision() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const containerAppName = "testStaticSite0"; + const name = "testcontainerApp0-pjxhsye"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.containerAppsRevisions.restartRevision( + resourceGroupName, + containerAppName, + name + ); + console.log(result); +} + +async function main() { + restartContainerAppRevision(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts index 53867240e106..8f558733cb54 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsGetDeletedWebAppByLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription at location. * * @summary Description for Get deleted app for a subscription at location. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppByLocation.json */ async function getDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); @@ -30,4 +35,8 @@ async function getDeletedWebAppByLocation() { console.log(result); } -getDeletedWebAppByLocation().catch(console.error); +async function main() { + getDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsListByLocationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsListByLocationSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsListByLocationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsListByLocationSample.ts index ced0e45e7206..964957c76d00 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/deletedWebAppsListByLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/deletedWebAppsListByLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription at location * * @summary Description for Get all deleted apps for a subscription at location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListDeletedWebAppsByLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListDeletedWebAppsByLocation.json */ async function listDeletedWebAppByLocation() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -29,4 +34,8 @@ async function listDeletedWebAppByLocation() { console.log(resArray); } -listDeletedWebAppByLocation().catch(console.error); +async function main() { + listDeletedWebAppByLocation(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts new file mode 100644 index 000000000000..e103753648ae --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json + */ +async function executeSiteAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + */ +async function executeSiteSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts new file mode 100644 index 000000000000..44008363f0de --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteAnalysisSlotSample.ts @@ -0,0 +1,78 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysis.json + */ +async function executeSiteAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Analysis + * + * @summary Description for Execute Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteAnalysisSlot.json + */ +async function executeSiteSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "apprestartanalyses"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +async function main() { + executeSiteAnalysis(); + executeSiteSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSample.ts new file mode 100644 index 000000000000..9193b07f48b6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json + */ +async function executeSiteDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetector( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + */ +async function executeSiteSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetector( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory + ); + console.log(result); +} + +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts new file mode 100644 index 000000000000..b40ac8a10a1e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsExecuteSiteDetectorSlotSample.ts @@ -0,0 +1,78 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetector.json + */ +async function executeSiteDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetectorSlot( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Execute Detector + * + * @summary Description for Execute Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ExecuteSiteDetectorSlot.json + */ +async function executeSiteSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "sitecrashes"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.executeSiteDetectorSlot( + resourceGroupName, + siteName, + detectorName, + diagnosticCategory, + slot + ); + console.log(result); +} + +async function main() { + executeSiteDetector(); + executeSiteSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts new file mode 100644 index 000000000000..830503b5703a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetHostingEnvironmentDetectorResponseSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Hosting Environment Detector Response + * + * @summary Description for Get Hosting Environment Detector Response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetHostingEnvironmentDetectorResponse.json + */ +async function getAppServiceEnvironmentDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAppServiceEnvironment"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getHostingEnvironmentDetectorResponse( + resourceGroupName, + name, + detectorName + ); + console.log(result); +} + +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSample.ts new file mode 100644 index 000000000000..bc35ed7dbcfe --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json + */ +async function getAppAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json + */ +async function getAppSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysis( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName + ); + console.log(result); +} + +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts new file mode 100644 index 000000000000..286a4f23df49 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteAnalysisSlotSample.ts @@ -0,0 +1,78 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysis.json + */ +async function getAppAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Site Analysis + * + * @summary Description for Get Site Analysis + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteAnalysisSlot.json + */ +async function getAppSlotAnalysis() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const analysisName = "appanalysis"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteAnalysisSlot( + resourceGroupName, + siteName, + diagnosticCategory, + analysisName, + slot + ); + console.log(result); +} + +async function main() { + getAppAnalysis(); + getAppSlotAnalysis(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts new file mode 100644 index 000000000000..5c496b49cfb8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSample.ts @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json + */ +async function getAppDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponse( + resourceGroupName, + siteName, + detectorName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + */ +async function getAppSlotDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponse( + resourceGroupName, + siteName, + detectorName + ); + console.log(result); +} + +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts new file mode 100644 index 000000000000..64249140317d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorResponseSlotSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponse.json + */ +async function getAppDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponseSlot( + resourceGroupName, + siteName, + detectorName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get site detector response + * + * @summary Description for Get site detector response + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorResponseSlot.json + */ +async function getAppSlotDetectorResponse() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const detectorName = "runtimeavailability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorResponseSlot( + resourceGroupName, + siteName, + detectorName, + slot + ); + console.log(result); +} + +async function main() { + getAppDetectorResponse(); + getAppSlotDetectorResponse(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSample.ts new file mode 100644 index 000000000000..70681221411a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json + */ +async function getAppDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetector( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json + */ +async function getAppSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetector( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName + ); + console.log(result); +} + +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts new file mode 100644 index 000000000000..adfa8d5fa501 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDetectorSlotSample.ts @@ -0,0 +1,78 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetector.json + */ +async function getAppDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorSlot( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Detector + * + * @summary Description for Get Detector + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDetectorSlot.json + */ +async function getAppSlotDetector() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const detectorName = "sitecrashes"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDetectorSlot( + resourceGroupName, + siteName, + diagnosticCategory, + detectorName, + slot + ); + console.log(result); +} + +async function main() { + getAppDetector(); + getAppSlotDetector(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts new file mode 100644 index 000000000000..2d5d10ecabf2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySample.ts @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + */ +async function getAppDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategory( + resourceGroupName, + siteName, + diagnosticCategory + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + */ +async function getAppSlotDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategory( + resourceGroupName, + siteName, + diagnosticCategory + ); + console.log(result); +} + +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts new file mode 100644 index 000000000000..8787b6ceaa42 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsGetSiteDiagnosticCategorySlotSample.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategory.json + */ +async function getAppDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategorySlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Category + * + * @summary Description for Get Diagnostics Category + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_GetSiteDiagnosticCategorySlot.json + */ +async function getAppSlotDiagnosticCategory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.diagnostics.getSiteDiagnosticCategorySlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + ); + console.log(result); +} + +async function main() { + getAppDiagnosticCategory(); + getAppSlotDiagnosticCategory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts new file mode 100644 index 000000000000..11f71e712676 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListHostingEnvironmentDetectorResponsesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List Hosting Environment Detector Responses + * + * @summary Description for List Hosting Environment Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListHostingEnvironmentDetectorResponses.json + */ +async function getAppServiceEnvironmentDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const name = "SampleAppServiceEnvironment"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listHostingEnvironmentDetectorResponses( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppServiceEnvironmentDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSample.ts new file mode 100644 index 000000000000..d0bc699ffa9a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSample.ts @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json + */ +async function listAppAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalyses( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json + */ +async function listAppSlotAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalyses( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts new file mode 100644 index 000000000000..a70f6cb395ef --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteAnalysesSlotSample.ts @@ -0,0 +1,80 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalyses.json + */ +async function listAppAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalysesSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Site Analyses + * + * @summary Description for Get Site Analyses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteAnalysesSlot.json + */ +async function listAppSlotAnalyses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteAnalysesSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppAnalyses(); + listAppSlotAnalyses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts new file mode 100644 index 000000000000..ea96e16ddd69 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSample.ts @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json + */ +async function getAppDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponses( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + */ +async function getAppSlotDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponses( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts new file mode 100644 index 000000000000..b8aff47f81e4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorResponsesSlotSample.ts @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponses.json + */ +async function getAppDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for List Site Detector Responses + * + * @summary Description for List Site Detector Responses + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorResponsesSlot.json + */ +async function getAppSlotDetectorResponses() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorResponsesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAppDetectorResponses(); + getAppSlotDetectorResponses(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSample.ts new file mode 100644 index 000000000000..12f4b3f0bdfa --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSample.ts @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json + */ +async function listAppDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectors( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json + */ +async function listAppSlotDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectors( + resourceGroupName, + siteName, + diagnosticCategory + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts new file mode 100644 index 000000000000..7cd1926eab3f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDetectorsSlotSample.ts @@ -0,0 +1,80 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectors.json + */ +async function listAppDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorsSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Detectors + * + * @summary Description for Get Detectors + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDetectorsSlot.json + */ +async function listAppSlotDetectors() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const diagnosticCategory = "availability"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDetectorsSlot( + resourceGroupName, + siteName, + diagnosticCategory, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDetectors(); + listAppSlotDetectors(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts new file mode 100644 index 000000000000..9644765ebb14 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSample.ts @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + */ +async function listAppDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategories( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + */ +async function listAppSlotDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategories( + resourceGroupName, + siteName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts new file mode 100644 index 000000000000..d31a2c8c6844 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/diagnosticsListSiteDiagnosticCategoriesSlotSample.ts @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategories.json + */ +async function listAppDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +/** + * This sample demonstrates how to Description for Get Diagnostics Categories + * + * @summary Description for Get Diagnostics Categories + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Diagnostics_ListSiteDiagnosticCategoriesSlot.json + */ +async function listAppSlotDiagnosticCategories() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Sample-WestUSResourceGroup"; + const siteName = "SampleApp"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.diagnostics.listSiteDiagnosticCategoriesSlot( + resourceGroupName, + siteName, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAppDiagnosticCategories(); + listAppSlotDiagnosticCategories(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainRegistrationProviderListOperationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainRegistrationProviderListOperationsSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainRegistrationProviderListOperationsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainRegistrationProviderListOperationsSample.ts index 3c33da4a6db4..be860901c655 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainRegistrationProviderListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainRegistrationProviderListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider * * @summary Description for Implements Csm operations Api to exposes the list of available Csm Apis under the resource provider - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCheckAvailabilitySample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCheckAvailabilitySample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCheckAvailabilitySample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCheckAvailabilitySample.ts index 55978d0d7819..50d91bfe6203 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCheckAvailabilitySample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCheckAvailabilitySample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { NameIdentifier, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Check if a domain is available for registration. * * @summary Description for Check if a domain is available for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CheckDomainAvailability.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CheckDomainAvailability.json */ async function checkDomainAvailability() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const identifier: NameIdentifier = { name: "abcd.com" }; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function checkDomainAvailability() { console.log(result); } -checkDomainAvailability().catch(console.error); +async function main() { + checkDomainAvailability(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts index 7a379e167a39..cc19d3c9a601 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateOwnershipIdentifierSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomainOwnershipIdentifier.json */ async function createAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier: DomainOwnershipIdentifier = { @@ -39,4 +45,8 @@ async function createAppServiceDomainOwnershipIdentifier() { console.log(result); } -createAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + createAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateSample.ts similarity index 88% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateSample.ts index 23b3e22a553e..f4613b8108c7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsCreateOrUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsCreateOrUpdateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { Domain, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/CreateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/CreateAppServiceDomain.json */ async function createAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain: Domain = { authCode: "exampleAuthCode", @@ -112,4 +118,8 @@ async function createAppServiceDomain() { console.log(result); } -createAppServiceDomain().catch(console.error); +async function main() { + createAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteOwnershipIdentifierSample.ts new file mode 100644 index 000000000000..a00779ffc024 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteOwnershipIdentifierSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete ownership identifier for domain + * + * @summary Description for Delete ownership identifier for domain + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomainOwnershipIdentifier.json + */ +async function deleteAppServiceDomainOwnershipIdentifier() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const name = "ownershipIdentifier"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.deleteOwnershipIdentifier( + resourceGroupName, + domainName, + name + ); + console.log(result); +} + +async function main() { + deleteAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteSample.ts new file mode 100644 index 000000000000..0fef1a42c331 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsDeleteSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DomainsDeleteOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete a domain. + * + * @summary Description for Delete a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/DeleteAppServiceDomain.json + */ +async function deleteAppServiceDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const forceHardDeleteDomain = true; + const options: DomainsDeleteOptionalParams = { forceHardDeleteDomain }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.delete( + resourceGroupName, + domainName, + options + ); + console.log(result); +} + +async function main() { + deleteAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetControlCenterSsoRequestSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetControlCenterSsoRequestSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetControlCenterSsoRequestSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetControlCenterSsoRequestSample.ts index a92d0e9d44a7..dba35039e430 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsGetControlCenterSsoRequestSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetControlCenterSsoRequestSample.ts @@ -10,19 +10,28 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Generate a single sign-on request for the domain management portal. * * @summary Description for Generate a single sign-on request for the domain management portal. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/GetDomainControlCenterSsoRequest.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainControlCenterSsoRequest.json */ async function getDomainControlCenterSsoRequest() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const result = await client.domains.getControlCenterSsoRequest(); console.log(result); } -getDomainControlCenterSsoRequest().catch(console.error); +async function main() { + getDomainControlCenterSsoRequest(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetOwnershipIdentifierSample.ts new file mode 100644 index 000000000000..e80f6e2e1d16 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetOwnershipIdentifierSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get ownership identifier for domain + * + * @summary Description for Get ownership identifier for domain + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomainOwnershipIdentifier.json + */ +async function getDomainOwnershipIdentifier() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const name = "SampleOwnershipId"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.getOwnershipIdentifier( + resourceGroupName, + domainName, + name + ); + console.log(result); +} + +async function main() { + getDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetSample.ts new file mode 100644 index 000000000000..d94234bc2a1a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get a domain. + * + * @summary Description for Get a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetDomain.json + */ +async function getDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.get(resourceGroupName, domainName); + console.log(result); +} + +async function main() { + getDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListByResourceGroupSample.ts new file mode 100644 index 000000000000..29209e943934 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all domains in a resource group. + * + * @summary Description for Get all domains in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsByResourceGroup.json + */ +async function listDomainsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.domains.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDomainsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListOwnershipIdentifiersSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListOwnershipIdentifiersSample.ts new file mode 100644 index 000000000000..5a36373ea533 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListOwnershipIdentifiersSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Lists domain ownership identifiers. + * + * @summary Description for Lists domain ownership identifiers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainOwnershipIdentifiers.json + */ +async function listDomainOwnershipIdentifiers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.domains.listOwnershipIdentifiers( + resourceGroupName, + domainName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDomainOwnershipIdentifiers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListRecommendationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListRecommendationsSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListRecommendationsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListRecommendationsSample.ts index 95333b118653..5b83a381ea5c 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListRecommendationsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListRecommendationsSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get domain name recommendations based on keywords. * * @summary Description for Get domain name recommendations based on keywords. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainRecommendations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainRecommendations.json */ async function listDomainRecommendations() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters: DomainRecommendationSearchParameters = { keywords: "example1", maxDomainRecommendations: 10 @@ -35,4 +40,8 @@ async function listDomainRecommendations() { console.log(resArray); } -listDomainRecommendations().catch(console.error); +async function main() { + listDomainRecommendations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListSample.ts index b5f3ef2192be..fdb596b8c9b2 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all domains in a subscription. * * @summary Description for Get all domains in a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListDomainsBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListDomainsBySubscription.json */ async function listDomainsBySubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listDomainsBySubscription() { console.log(resArray); } -listDomainsBySubscription().catch(console.error); +async function main() { + listDomainsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsRenewSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsRenewSample.ts new file mode 100644 index 000000000000..5c2d2047a046 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsRenewSample.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Renew a domain. + * + * @summary Description for Renew a domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/RenewDomain.json + */ +async function renewAnExistingDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3dddfa4f-cedf-4dc0-ba29-b6d1a69ab545"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "RG"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.renew(resourceGroupName, domainName); + console.log(result); +} + +async function main() { + renewAnExistingDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsTransferOutSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsTransferOutSample.ts new file mode 100644 index 000000000000..e7973f70479c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsTransferOutSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Transfer out domain to another registrar + * + * @summary Transfer out domain to another registrar + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/TransferOutDomain.json + */ +async function transferOutDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const domainName = "example.com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.domains.transferOut( + resourceGroupName, + domainName + ); + console.log(result); +} + +async function main() { + transferOutDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateOwnershipIdentifierSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateOwnershipIdentifierSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateOwnershipIdentifierSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateOwnershipIdentifierSample.ts index 50de2f0a0aa2..25a29d725a56 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateOwnershipIdentifierSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateOwnershipIdentifierSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier * * @summary Description for Creates an ownership identifier for a domain or updates identifier details for an existing identifier - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomainOwnershipIdentifier.json */ async function updateAppServiceDomainOwnershipIdentifier() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const name = "SampleOwnershipId"; const domainOwnershipIdentifier: DomainOwnershipIdentifier = { @@ -39,4 +45,8 @@ async function updateAppServiceDomainOwnershipIdentifier() { console.log(result); } -updateAppServiceDomainOwnershipIdentifier().catch(console.error); +async function main() { + updateAppServiceDomainOwnershipIdentifier(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateSample.ts similarity index 88% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateSample.ts index 2ab9501f3c02..17116da52fe1 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/domainsUpdateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/domainsUpdateSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates a domain. * * @summary Description for Creates or updates a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/UpdateAppServiceDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/UpdateAppServiceDomain.json */ async function updateAppServiceDomain() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const domainName = "example.com"; const domain: DomainPatchResource = { authCode: "exampleAuthCode", @@ -113,4 +119,8 @@ async function updateAppServiceDomain() { console.log(result); } -updateAppServiceDomain().catch(console.error); +async function main() { + updateAppServiceDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSample.ts index ca63723f7a8f..75cf3c2d73ec 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get deleted app for a subscription. * * @summary Description for Get deleted app for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebApp.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebApp.json */ async function getDeletedWebApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function getDeletedWebApp() { console.log(result); } -getDeletedWebApp().catch(console.error); +async function main() { + getDeletedWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts index e9bd6a44e324..d11cbfadd5a0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetDeletedWebAppSnapshotsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all deleted apps for a subscription. * * @summary Description for Get all deleted apps for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetDeletedWebAppSnapshots.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetDeletedWebAppSnapshots.json */ async function getDeletedWebAppSnapshots() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const deletedSiteId = "9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -26,4 +31,8 @@ async function getDeletedWebAppSnapshots() { console.log(result); } -getDeletedWebAppSnapshots().catch(console.error); +async function main() { + getDeletedWebAppSnapshots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts index f062faba65d7..651a82031c81 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/globalGetSubscriptionOperationWithAsyncResponseSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets an operation in a subscription and given region * * @summary Description for Gets an operation in a subscription and given region - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetSubscriptionOperationWithAsyncResponse.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSubscriptionOperationWithAsyncResponse.json */ async function getsAnOperationInASubscriptionAndGivenRegion() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US"; const operationId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab5d5"; const credential = new DefaultAzureCredential(); @@ -30,4 +35,8 @@ async function getsAnOperationInASubscriptionAndGivenRegion() { console.log(result); } -getsAnOperationInASubscriptionAndGivenRegion().catch(console.error); +async function main() { + getsAnOperationInASubscriptionAndGivenRegion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts new file mode 100644 index 000000000000..810a9722591a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsCreateOrUpdateSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + KubeEnvironment, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. + * + * @summary Description for Creates or updates a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_CreateOrUpdate.json + */ +async function createKubeEnvironments() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "testkubeenv"; + const kubeEnvironmentEnvelope: KubeEnvironment = { + location: "East US", + staticIp: "1.2.3.4" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + kubeEnvironmentEnvelope + ); + console.log(result); +} + +async function main() { + createKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsDeleteSample.ts new file mode 100644 index 000000000000..be5e24a7ada0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsDeleteSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Delete a Kubernetes Environment. + * + * @summary Description for Delete a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Delete.json + */ +async function deleteKubeEnvironmentByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "examplekenv"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.beginDeleteAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteKubeEnvironmentByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsGetSample.ts new file mode 100644 index 000000000000..abc4b1c3f278 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get the properties of a Kubernetes Environment. + * + * @summary Description for Get the properties of a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Get.json + */ +async function getKubeEnvironmentsByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "jlaw-demo1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getKubeEnvironmentsByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts new file mode 100644 index 000000000000..d5ca206af83d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all the Kubernetes Environments in a resource group. + * + * @summary Description for Get all the Kubernetes Environments in a resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListByResourceGroup.json + */ +async function listKubeEnvironmentsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.kubeEnvironments.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listKubeEnvironmentsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts index a3e38cac991c..8292fa869cb3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsListBySubscriptionSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all Kubernetes Environments for a subscription. * * @summary Description for Get all Kubernetes Environments for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/KubeEnvironments_ListBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_ListBySubscription.json */ async function listKubeEnvironmentsBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "8efdecc5-919e-44eb-b179-915dca89ebf9"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listKubeEnvironmentsBySubscription() { console.log(resArray); } -listKubeEnvironmentsBySubscription().catch(console.error); +async function main() { + listKubeEnvironmentsBySubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsUpdateSample.ts new file mode 100644 index 000000000000..77dd09dfdc03 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/kubeEnvironmentsUpdateSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + KubeEnvironmentPatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates a Kubernetes Environment. + * + * @summary Description for Creates or updates a Kubernetes Environment. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/KubeEnvironments_Update.json + */ +async function updateKubeEnvironments() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "examplerg"; + const name = "testkubeenv"; + const kubeEnvironmentEnvelope: KubeEnvironmentPatchResource = { + staticIp: "1.2.3.4" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.kubeEnvironments.update( + resourceGroupName, + name, + kubeEnvironmentEnvelope + ); + console.log(result); +} + +async function main() { + updateKubeEnvironments(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/listCustomHostNameSitesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/listCustomHostNameSitesSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/listCustomHostNameSitesSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/listCustomHostNameSitesSample.ts index fc9e9fac8b4c..01b4c1432574 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/listCustomHostNameSitesSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/listCustomHostNameSitesSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomHostNameSites.json */ async function getCustomHostnamesUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -31,16 +36,16 @@ async function getCustomHostnamesUnderSubscription() { console.log(resArray); } -getCustomHostnamesUnderSubscription().catch(console.error); - /** * This sample demonstrates how to Get custom hostnames under this subscription * * @summary Get custom hostnames under this subscription - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListCustomSpecificHostNameSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListCustomSpecificHostNameSites.json */ async function getSpecificCustomHostnameUnderSubscription() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const hostname = "www.example.com"; const options: ListCustomHostNameSitesOptionalParams = { hostname }; const credential = new DefaultAzureCredential(); @@ -52,4 +57,9 @@ async function getSpecificCustomHostnameUnderSubscription() { console.log(resArray); } -getSpecificCustomHostnameUnderSubscription().catch(console.error); +async function main() { + getCustomHostnamesUnderSubscription(); + getSpecificCustomHostnameUnderSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksForLocationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksForLocationSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksForLocationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksForLocationSample.ts index 21b629932e40..ffe3ad3e8f4e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksForLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksForLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions for location * * @summary Description for Get available Function app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacksForLocation.json */ async function getLocationsFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -31,4 +36,8 @@ async function getLocationsFunctionAppStacks() { console.log(resArray); } -getLocationsFunctionAppStacks().catch(console.error); +async function main() { + getLocationsFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksSample.ts index 6a107c69ab4f..34ac7f81949e 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetFunctionAppStacksSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetFunctionAppStacksSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Function app frameworks and their versions * * @summary Description for Get available Function app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetFunctionAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetFunctionAppStacks.json */ async function getFunctionAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getFunctionAppStacks() { console.log(resArray); } -getFunctionAppStacks().catch(console.error); +async function main() { + getFunctionAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksForLocationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksForLocationSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksForLocationSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksForLocationSample.ts index 5d3ea94b4baf..75b9585d9d96 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksForLocationSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksForLocationSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions for location * * @summary Description for Get available Web app frameworks and their versions for location - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacksForLocation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacksForLocation.json */ async function getLocationsWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const location = "westus"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); @@ -31,4 +36,8 @@ async function getLocationsWebAppStacks() { console.log(resArray); } -getLocationsWebAppStacks().catch(console.error); +async function main() { + getLocationsWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksSample.ts index e8a1b8a2d0fe..80f97dad8712 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerGetWebAppStacksSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerGetWebAppStacksSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get available Web app frameworks and their versions * * @summary Description for Get available Web app frameworks and their versions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetWebAppStacks.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppStacks.json */ async function getWebAppStacks() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getWebAppStacks() { console.log(resArray); } -getWebAppStacks().catch(console.error); +async function main() { + getWebAppStacks(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerListOperationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerListOperationsSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/providerListOperationsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/providerListOperationsSample.ts index cc6b42623e20..afdb759e7631 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/providerListOperationsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/providerListOperationsSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions * * @summary Description for Gets all available operations for the Microsoft.Web resource provider. Also exposes resource metric definitions - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListOperations.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListOperations.json */ async function listOperations() { - const subscriptionId = "00000000-0000-0000-0000-000000000000"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "00000000-0000-0000-0000-000000000000"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listOperations() { console.log(resArray); } -listOperations().catch(console.error); +async function main() { + listOperations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSample.ts new file mode 100644 index 000000000000..06938bba2a8b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json + */ +async function getResourceHealthMetadata() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.resourceHealthMetadataOperations.getBySite( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts new file mode 100644 index 000000000000..955e0752da77 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataGetBySiteSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetResourceHealthMetadataBySite.json + */ +async function getResourceHealthMetadata() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.resourceHealthMetadataOperations.getBySiteSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + getResourceHealthMetadata(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts new file mode 100644 index 000000000000..0947d6d95897 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. + * + * @summary Description for List all ResourceHealthMetadata for all sites in the resource group in the subscription. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataByResourceGroup.json + */ +async function listResourceHealthMetadataForAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.resourceHealthMetadataOperations.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listResourceHealthMetadataForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSample.ts new file mode 100644 index 000000000000..156605f0366e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json + */ +async function listResourceHealthMetadataForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.resourceHealthMetadataOperations.listBySite( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts new file mode 100644 index 000000000000..8921c8eda8d0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListBySiteSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * + * @summary Description for Gets the category of ResourceHealthMetadata to use for the given site as a collection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySite.json + */ +async function listResourceHealthMetadataForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "Default-Web-NorthCentralUS"; + const name = "newsiteinnewASE-NCUS"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.resourceHealthMetadataOperations.listBySiteSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listResourceHealthMetadataForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListSample.ts index 86ffdaf0fe46..3230fa63d254 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/resourceHealthMetadataListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/resourceHealthMetadataListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for List all ResourceHealthMetadata for all sites in the subscription. * * @summary Description for List all ResourceHealthMetadata for all sites in the subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ListResourceHealthMetadataBySubscription.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListResourceHealthMetadataBySubscription.json */ async function listResourceHealthMetadataForASubscription() { - const subscriptionId = "4adb32ad-8327-4cbb-b775-b84b4465bb38"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "4adb32ad-8327-4cbb-b775-b84b4465bb38"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listResourceHealthMetadataForASubscription() { console.log(resArray); } -listResourceHealthMetadataForASubscription().catch(console.error); +async function main() { + listResourceHealthMetadataForASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts index 91e1a613676b..8c83fa1b8b53 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -43,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBasicAuthSample.ts new file mode 100644 index 000000000000..beb8d2f42aa8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBasicAuthSample.ts @@ -0,0 +1,54 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StaticSiteBasicAuthPropertiesARMResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Adds or updates basic auth for a static site. + * + * @summary Description for Adds or updates basic auth for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBasicAuth.json + */ +async function createsOrUpdatesBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const basicAuthEnvelope: StaticSiteBasicAuthPropertiesARMResource = { + applicableEnvironmentsMode: "AllEnvironments", + environments: [], + password: "**********************", + secretUrl: undefined + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBasicAuth( + resourceGroupName, + name, + basicAuthName, + basicAuthEnvelope + ); + console.log(result); +} + +async function main() { + createsOrUpdatesBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..2740fd21056f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateBuildDatabaseConnectionSample.ts @@ -0,0 +1,58 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnection, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnection = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateDatabaseConnectionSample.ts new file mode 100644 index 000000000000..1bfb048ba32c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateDatabaseConnectionSample.ts @@ -0,0 +1,56 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnection, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteDatabaseConnection.json + */ +async function createOrUpdateADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnection = { + connectionIdentity: "SystemAssigned", + connectionString: + "AccountEndpoint=https://exampleDatabaseName.documents.azure.com:443/;Database=mydb;", + region: "West US 2", + resourceId: + "/subscription/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/databaseRG/providers/Microsoft.DocumentDB/databaseAccounts/exampleDatabaseName" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + createOrUpdateADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts new file mode 100644 index 000000000000..c56b55b2396e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteAppSettingsSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StringDictionary, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates the app settings of a static site. + * + * @summary Description for Creates or updates the app settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteAppSettings.json + */ +async function createsOrUpdatesTheAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const appSettings: StringDictionary = { + properties: { setting1: "someval", setting2: "someval2" } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateStaticSiteAppSettings( + resourceGroupName, + name, + appSettings + ); + console.log(result); +} + +async function main() { + createsOrUpdatesTheAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts index 84ca329fb593..21ce208b5006 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the app settings of a static site build. * * @summary Description for Creates or updates the app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings: StringDictionary = { @@ -39,4 +44,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts index 91884f984044..486596604caf 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates or updates the function app settings of a static site build. * * @summary Description for Creates or updates the function app settings of a static site build. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteBuildFunctionAppSettings.json */ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const appSettings: StringDictionary = { @@ -39,4 +44,8 @@ async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild() { console.log(result); } -createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild().catch(console.error); +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts index b5616dfa3585..0bb0c8dfd8e2 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteCustomDomainSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site custom domain in an existing resource group and static site. * * @summary Description for Creates a new static site custom domain in an existing resource group and static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteCustomDomain.json */ async function createOrUpdateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource = {}; @@ -37,4 +42,8 @@ async function createOrUpdateACustomDomainForAStaticSite() { console.log(result); } -createOrUpdateACustomDomainForAStaticSite().catch(console.error); +async function main() { + createOrUpdateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts new file mode 100644 index 000000000000..73b6586483a3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteFunctionAppSettingsSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StringDictionary, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates or updates the function app settings of a static site. + * + * @summary Description for Creates or updates the function app settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSiteFunctionAppSettings.json + */ +async function createsOrUpdatesTheFunctionAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const appSettings: StringDictionary = { + properties: { setting1: "someval", setting2: "someval2" } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.createOrUpdateStaticSiteFunctionAppSettings( + resourceGroupName, + name, + appSettings + ); + console.log(result); +} + +async function main() { + createsOrUpdatesTheFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts index 3baefc5c97f8..9df209399bef 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateOrUpdateStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateOrUpdateStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateStaticSite.json */ async function createOrUpdateAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope: StaticSiteARMResource = { branch: "master", @@ -46,4 +51,8 @@ async function createOrUpdateAStaticSite() { console.log(result); } -createOrUpdateAStaticSite().catch(console.error); +async function main() { + createOrUpdateAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts index 7ef564b29a54..cb44ba236eb3 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateUserRolesInvitationLinkSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates an invitation link for a user with the role * * @summary Description for Creates an invitation link for a user with the role - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/CreateUserRolesInvitationLink.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateUserRolesInvitationLink.json */ async function createAnInvitationLinkForAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteUserRolesInvitationEnvelope: StaticSiteUserInvitationRequestResource = { domain: "happy-sea-15afae3e.azurestaticwebsites.net", @@ -41,4 +46,8 @@ async function createAnInvitationLinkForAUserForAStaticSite() { console.log(result); } -createAnInvitationLinkForAUserForAStaticSite().catch(console.error); +async function main() { + createAnInvitationLinkForAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts index 859d225f3498..a9ce16106706 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deploys zipped content to a specific environment of a static site. * * @summary Description for Deploys zipped content to a specific environment of a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteBuildZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteBuildZipDeploy.json */ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "12"; const staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource = { @@ -45,6 +50,8 @@ async function deployASiteFromAZippedPackageToAParticularStaticSiteBuild() { console.log(result); } -deployASiteFromAZippedPackageToAParticularStaticSiteBuild().catch( - console.error -); +async function main() { + deployASiteFromAZippedPackageToAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts index e908a8022863..961e8f82eed0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesCreateZipDeploymentForStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Deploys zipped content to a static site. * * @summary Description for Deploys zipped content to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StaticSiteZipDeploy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StaticSiteZipDeploy.json */ async function deployASiteFromAZippedPackage() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource = { apiZipUrl: @@ -43,4 +48,8 @@ async function deployASiteFromAZippedPackage() { console.log(result); } -deployASiteFromAZippedPackage().catch(console.error); +async function main() { + deployASiteFromAZippedPackage(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..a88760377508 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteBuildDatabaseConnectionSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site build + * + * @summary Delete a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuildDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteDatabaseConnectionSample.ts new file mode 100644 index 000000000000..2f781151e287 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteDatabaseConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Delete a database connection for a static site + * + * @summary Delete a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteDatabaseConnection.json + */ +async function deleteADatabaseConnectionFromAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + deleteADatabaseConnectionFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..dc97c2bae4e5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeletePrivateEndpointConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json + */ +async function deleteAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeletePrivateEndpointConnectionAndWait( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts new file mode 100644 index 000000000000..75d71bcdbb62 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteBuildSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a static site build. + * + * @summary Description for Deletes a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteBuild.json + */ +async function deleteAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteBuildAndWait( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + deleteAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts new file mode 100644 index 000000000000..25ca3a7d6f9b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteCustomDomainSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a custom domain. + * + * @summary Description for Deletes a custom domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteCustomDomain.json + */ +async function deleteACustomDomainForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const domainName = "custom.domain.net"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteCustomDomainAndWait( + resourceGroupName, + name, + domainName + ); + console.log(result); +} + +async function main() { + deleteACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteSample.ts new file mode 100644 index 000000000000..4dd2e73420d4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a static site. + * + * @summary Description for Deletes a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSite.json + */ +async function deleteAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDeleteStaticSiteAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + deleteAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteUserSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteUserSample.ts new file mode 100644 index 000000000000..80d87c0eb0dd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDeleteStaticSiteUserSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes the user entry from the static site. + * + * @summary Description for Deletes the user entry from the static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteStaticSiteUser.json + */ +async function deleteAUserForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const authprovider = "aad"; + const userid = "1234"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.deleteStaticSiteUser( + resourceGroupName, + name, + authprovider, + userid + ); + console.log(result); +} + +async function main() { + deleteAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachStaticSiteSample.ts new file mode 100644 index 000000000000..e01be5554c61 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachStaticSiteSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Detaches a static site. + * + * @summary Description for Detaches a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachStaticSite.json + */ +async function detachAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.beginDetachStaticSiteAndWait( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + detachAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts new file mode 100644 index 000000000000..09130cd984a7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteBuildSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Detach the user provided function app from the static site build + * + * @summary Description for Detach the user provided function app from the static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSiteBuild.json + */ +async function detachTheUserProvidedFunctionAppFromTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const functionAppName = "testFunctionApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSiteBuild( + resourceGroupName, + name, + environmentName, + functionAppName + ); + console.log(result); +} + +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts new file mode 100644 index 000000000000..ddf7070b23b2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesDetachUserProvidedFunctionAppFromStaticSiteSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Detach the user provided function app from the static site + * + * @summary Description for Detach the user provided function app from the static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DetachUserProvidedFunctionAppFromStaticSite.json + */ +async function detachTheUserProvidedFunctionAppFromTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const functionAppName = "testFunctionApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.detachUserProvidedFunctionAppFromStaticSite( + resourceGroupName, + name, + functionAppName + ); + console.log(result); +} + +async function main() { + detachTheUserProvidedFunctionAppFromTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBasicAuthSample.ts new file mode 100644 index 000000000000..59383ce2a48d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBasicAuthSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site. + * + * @summary Description for Gets the basic auth properties for a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBasicAuth.json + */ +async function getsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const basicAuthName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBasicAuth( + resourceGroupName, + name, + basicAuthName + ); + console.log(result); +} + +async function main() { + getsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..d5806206d128 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site build by name + * + * @summary Returns overview of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts new file mode 100644 index 000000000000..89ed5a783922 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionWithDetailsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site build by name + * + * @summary Returns details of a database connection for a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getBuildDatabaseConnectionWithDetails( + resourceGroupName, + name, + environmentName, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsSample.ts new file mode 100644 index 000000000000..a708828aa6bc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site build + * + * @summary Returns overviews of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnections( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts new file mode 100644 index 000000000000..89582d796c52 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetBuildDatabaseConnectionsWithDetailsSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site build + * + * @summary Returns details of database connections for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuildDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBuildDatabaseConnectionsWithDetails( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionSample.ts new file mode 100644 index 000000000000..b0afdb68946f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overview of a database connection for a static site by name + * + * @summary Returns overview of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnection.json + */ +async function getOverviewOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getOverviewOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionWithDetailsSample.ts new file mode 100644 index 000000000000..7c5e6fd40e8e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionWithDetailsSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of a database connection for a static site by name + * + * @summary Returns details of a database connection for a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionWithDetails.json + */ +async function getDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getDatabaseConnectionWithDetails( + resourceGroupName, + name, + databaseConnectionName + ); + console.log(result); +} + +async function main() { + getDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsSample.ts new file mode 100644 index 000000000000..9c1718e6fbb5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns overviews of database connections for a static site + * + * @summary Returns overviews of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnections.json + */ +async function listOverviewsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnections( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listOverviewsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsWithDetailsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsWithDetailsSample.ts new file mode 100644 index 000000000000..46c771b1b976 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetDatabaseConnectionsWithDetailsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of database connections for a static site + * + * @summary Returns details of database connections for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteDatabaseConnectionsWithDetails.json + */ +async function listFullDetailsOfDatabaseConnectionsForTheStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listDatabaseConnectionsWithDetails( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listFullDetailsOfDatabaseConnectionsForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts new file mode 100644 index 000000000000..7f059983a187 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendForBuildSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns the details of a linked backend linked to a static site build by name + * + * @summary Returns the details of a linked backend linked to a static site build by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSiteBuild.json + */ +async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getLinkedBackendForBuild( + resourceGroupName, + name, + environmentName, + linkedBackendName + ); + console.log(result); +} + +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteBuildByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendSample.ts new file mode 100644 index 000000000000..b684f2eae615 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns the details of a linked backend linked to a static site by name + * + * @summary Returns the details of a linked backend linked to a static site by name + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendForStaticSite.json + */ +async function getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getLinkedBackend( + resourceGroupName, + name, + linkedBackendName + ); + console.log(result); +} + +async function main() { + getDetailsOfTheLinkedBackendRegisteredWithAStaticSiteByName(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts new file mode 100644 index 000000000000..e266597c9bd7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsForBuildSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of all backends linked to a static site build + * + * @summary Returns details of all backends linked to a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSiteBuild.json + */ +async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listLinkedBackendsForBuild( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsSample.ts new file mode 100644 index 000000000000..5a45c17c6e7c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetLinkedBackendsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Returns details of all backends linked to a static site + * + * @summary Returns details of all backends linked to a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetLinkedBackendsForStaticSite.json + */ +async function getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listLinkedBackends( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheLinkedBackendsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts new file mode 100644 index 000000000000..72a325374b00 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionListSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the list of private endpoint connections associated with a static site + * + * @summary Description for Gets the list of private endpoint connections associated with a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionList.json + */ +async function getAListOfPrivateEndpointConnectionsAssociatedWithASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listPrivateEndpointConnectionList( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAListOfPrivateEndpointConnectionsAssociatedWithASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..23a59bd9d656 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateEndpointConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getPrivateEndpointConnection( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts new file mode 100644 index 000000000000..ead4c8009b00 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetPrivateLinkResourcesSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getPrivateLinkResources( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildSample.ts new file mode 100644 index 000000000000..7e5ab3552d2e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a static site build. + * + * @summary Description for Gets the details of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuild.json + */ +async function getAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSiteBuild( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildsSample.ts new file mode 100644 index 000000000000..74891349da12 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteBuildsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all static site builds for a particular static site. + * + * @summary Description for Gets all static site builds for a particular static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteBuilds.json + */ +async function getAllBuildsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteBuilds( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAllBuildsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts new file mode 100644 index 000000000000..c3a7dbe7810e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteCustomDomainSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets an existing custom domain for a particular static site. + * + * @summary Description for Gets an existing custom domain for a particular static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomain.json + */ +async function getCustomDomainForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const domainName = "custom.domain.net"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSiteCustomDomain( + resourceGroupName, + name, + domainName + ); + console.log(result); +} + +async function main() { + getCustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteSample.ts new file mode 100644 index 000000000000..999ebdcc2bbb --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSiteSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a static site. + * + * @summary Description for Gets the details of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSite.json + */ +async function getDetailsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getStaticSite( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getDetailsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts new file mode 100644 index 000000000000..8cd43772b855 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetStaticSitesByResourceGroupSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all static sites in the specified resource group. + * + * @summary Description for Gets all static sites in the specified resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSites.json + */ +async function getStaticSitesForAResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSitesByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getStaticSitesForAResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts new file mode 100644 index 000000000000..1e9b3b65a5df --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteBuildSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site build + * + * @summary Description for Gets the details of the user provided function app registered with a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSiteBuild.json + */ +async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const functionAppName = "testFunctionApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getUserProvidedFunctionAppForStaticSiteBuild( + resourceGroupName, + name, + environmentName, + functionAppName + ); + console.log(result); +} + +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts new file mode 100644 index 000000000000..6dd6dc4ccf06 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppForStaticSiteSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of the user provided function app registered with a static site + * + * @summary Description for Gets the details of the user provided function app registered with a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppForStaticSite.json + */ +async function getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const functionAppName = "testFunctionApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.getUserProvidedFunctionAppForStaticSite( + resourceGroupName, + name, + functionAppName + ); + console.log(result); +} + +async function main() { + getDetailsOfTheUserProvidedFunctionAppRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts new file mode 100644 index 000000000000..a2e69c095345 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteBuildSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site build + * + * @summary Description for Gets the details of the user provided function apps registered with a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSiteBuild.json + */ +async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listUserProvidedFunctionAppsForStaticSiteBuild( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts new file mode 100644 index 000000000000..1e973fd45129 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesGetUserProvidedFunctionAppsForStaticSiteSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of the user provided function apps registered with a static site + * + * @summary Description for Gets the details of the user provided function apps registered with a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetUserProvidedFunctionAppsForStaticSite.json + */ +async function getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listUserProvidedFunctionAppsForStaticSite( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getDetailsOfTheUserProvidedFunctionAppsRegisteredWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendSample.ts index 3d7d36495cf9..18ee28092997 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Link backend to a static site * * @summary Link backend to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSite.json */ async function linkABackendToAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource = { @@ -41,4 +46,8 @@ async function linkABackendToAStaticSite() { console.log(result); } -linkABackendToAStaticSite().catch(console.error); +async function main() { + linkABackendToAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendToBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendToBuildSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendToBuildSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendToBuildSample.ts index f437a4367482..e6ee36386ea6 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesLinkBackendToBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesLinkBackendToBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Link backend to a static site build * * @summary Link backend to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/LinkBackendToStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/LinkBackendToStaticSiteBuild.json */ async function linkABackendToAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -43,4 +48,8 @@ async function linkABackendToAStaticSiteBuild() { console.log(result); } -linkABackendToAStaticSiteBuild().catch(console.error); +async function main() { + linkABackendToAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListBasicAuthSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListBasicAuthSample.ts new file mode 100644 index 000000000000..56baa3466ef5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListBasicAuthSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the basic auth properties for a static site as a collection. + * + * @summary Description for Gets the basic auth properties for a static site as a collection. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBasicAuth.json + */ +async function listsTheBasicAuthPropertiesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listBasicAuth( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listsTheBasicAuthPropertiesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListSample.ts index 0c3a4059dcf4..6829606f7dea 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all Static Sites for a subscription. * * @summary Description for Get all Static Sites for a subscription. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GetAllStaticSites.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAllStaticSites.json */ async function getAllStaticSitesInASubscription() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function getAllStaticSitesInASubscription() { console.log(resArray); } -getAllStaticSitesInASubscription().catch(console.error); +async function main() { + getAllStaticSitesInASubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts new file mode 100644 index 000000000000..18975d2ffaa4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteAppSettingsSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site. + * + * @summary Description for Gets the application settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteAppSettings.json + */ +async function getAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteAppSettings( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts new file mode 100644 index 000000000000..a5e2a149a5bc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildAppSettingsSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site build. + * + * @summary Description for Gets the application settings of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildAppSettings.json + */ +async function getAppSettingsOfAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteBuildAppSettings( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts new file mode 100644 index 000000000000..9e87df11e8d0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionAppSettingsSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site build. + * + * @summary Description for Gets the application settings of a static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctionAppSettings.json + */ +async function getFunctionAppSettingsOfAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteBuildFunctionAppSettings( + resourceGroupName, + name, + environmentName + ); + console.log(result); +} + +async function main() { + getFunctionAppSettingsOfAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts new file mode 100644 index 000000000000..3db0dc1bf14e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteBuildFunctionsSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the functions of a particular static site build. + * + * @summary Description for Gets the functions of a particular static site build. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteBuildFunctions.json + */ +async function getsTheFunctionsOfAParticularStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteBuildFunctions( + resourceGroupName, + name, + environmentName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getsTheFunctionsOfAParticularStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts new file mode 100644 index 000000000000..3d4c71461f82 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteConfiguredRolesSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Lists the roles configured for the static site. + * + * @summary Description for Lists the roles configured for the static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteConfiguredRoles.json + */ +async function listsTheConfiguredRolesForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteConfiguredRoles( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listsTheConfiguredRolesForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts new file mode 100644 index 000000000000..dd7cbc3f8ab3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteCustomDomainsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all static site custom domains for a particular static site. + * + * @summary Description for Gets all static site custom domains for a particular static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetStaticSiteCustomDomains.json + */ +async function listCustomDomainsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteCustomDomains( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listCustomDomainsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts new file mode 100644 index 000000000000..6a01fa85688f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionAppSettingsSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of a static site. + * + * @summary Description for Gets the application settings of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctionAppSettings.json + */ +async function getFunctionAppSettingsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteFunctionAppSettings( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getFunctionAppSettingsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionsSample.ts new file mode 100644 index 000000000000..5d47a36a8990 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteFunctionsSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the functions of a static site. + * + * @summary Description for Gets the functions of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteFunctions.json + */ +async function getsTheFunctionsOfAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteFunctions( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getsTheFunctionsOfAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteSecretsSample.ts new file mode 100644 index 000000000000..5f474bb78910 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteSecretsSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Lists the secrets for an existing static site. + * + * @summary Description for Lists the secrets for an existing static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteSecrets.json + */ +async function listSecretsForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.listStaticSiteSecrets( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listSecretsForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteUsersSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteUsersSample.ts new file mode 100644 index 000000000000..c002846e17a3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesListStaticSiteUsersSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the list of users of a static site. + * + * @summary Description for Gets the list of users of a static site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListStaticSiteUsers.json + */ +async function listUsersForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const authprovider = "all"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.staticSites.listStaticSiteUsers( + resourceGroupName, + name, + authprovider + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listUsersForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesPreviewWorkflowSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesPreviewWorkflowSample.ts similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesPreviewWorkflowSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesPreviewWorkflowSample.ts index ea592ef44094..cb5936bf915d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesPreviewWorkflowSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesPreviewWorkflowSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Generates a preview workflow file for the static site * * @summary Description for Generates a preview workflow file for the static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/GenerateStaticSiteWorkflowPreview.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GenerateStaticSiteWorkflowPreview.json */ async function generatesAPreviewWorkflowFileForTheStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const location = "West US 2"; const staticSitesWorkflowPreviewRequest: StaticSitesWorkflowPreviewRequest = { branch: "master", @@ -41,4 +46,8 @@ async function generatesAPreviewWorkflowFileForTheStaticSite() { console.log(result); } -generatesAPreviewWorkflowFileForTheStaticSite().catch(console.error); +async function main() { + generatesAPreviewWorkflowFileForTheStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts similarity index 81% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts index 6b70555ee974..4fc262f2fd71 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildSample.ts @@ -14,16 +14,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site build * * @summary Description for Register a user provided function app with a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSiteBuild.json */ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const functionAppName = "testFunctionApp"; @@ -49,4 +54,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSiteBuild() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSiteBuild().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts index 1fd612b47830..cfd088ec60a1 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesRegisterUserProvidedFunctionAppWithStaticSiteSample.ts @@ -14,16 +14,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Register a user provided function app with a static site * * @summary Description for Register a user provided function app with a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RegisterUserProvidedFunctionAppWithStaticSite.json */ async function registerAUserProvidedFunctionAppWithAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const functionAppName = "testFunctionApp"; const isForced = true; @@ -47,4 +52,8 @@ async function registerAUserProvidedFunctionAppWithAStaticSite() { console.log(result); } -registerAUserProvidedFunctionAppWithAStaticSite().catch(console.error); +async function main() { + registerAUserProvidedFunctionAppWithAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesResetStaticSiteApiKeySample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesResetStaticSiteApiKeySample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesResetStaticSiteApiKeySample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesResetStaticSiteApiKeySample.ts index 85324c7ed49d..0f6435fdc45f 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesResetStaticSiteApiKeySample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesResetStaticSiteApiKeySample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Resets the api key for an existing static site. * * @summary Description for Resets the api key for an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ResetStaticSiteApiKey.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ResetStaticSiteApiKey.json */ async function resetTheApiKeyForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const resetPropertiesEnvelope: StaticSiteResetPropertiesARMResource = { repositoryToken: "repoToken123", @@ -38,4 +43,8 @@ async function resetTheApiKeyForAStaticSite() { console.log(result); } -resetTheApiKeyForAStaticSite().catch(console.error); +async function main() { + resetTheApiKeyForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts new file mode 100644 index 000000000000..9eb3eb73b01e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendFromBuildSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Unlink a backend from a static site build + * + * @summary Unlink a backend from a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSiteBuild.json + */ +async function unlinkABackendFromAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "12"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.unlinkBackendFromBuild( + resourceGroupName, + name, + environmentName, + linkedBackendName + ); + console.log(result); +} + +async function main() { + unlinkABackendFromAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendSample.ts new file mode 100644 index 000000000000..b84a24a3b76d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUnlinkBackendSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Unlink a backend from a static site + * + * @summary Unlink a backend from a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UnlinkBackendFromStaticSite.json + */ +async function unlinkABackendFromAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const linkedBackendName = "testBackend"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.unlinkBackend( + resourceGroupName, + name, + linkedBackendName + ); + console.log(result); +} + +async function main() { + unlinkABackendFromAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateBuildDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateBuildDatabaseConnectionSample.ts new file mode 100644 index 000000000000..cc1d650ce55d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateBuildDatabaseConnectionSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnectionPatchRequest, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site build + * + * @summary Description for Create or update a database connection for a static site build + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteBuildDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSiteBuild() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const environmentName = "default"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateBuildDatabaseConnection( + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateDatabaseConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateDatabaseConnectionSample.ts new file mode 100644 index 000000000000..82cf428681ff --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateDatabaseConnectionSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + DatabaseConnectionPatchRequest, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Create or update a database connection for a static site + * + * @summary Description for Create or update a database connection for a static site + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSiteDatabaseConnection.json + */ +async function patchADatabaseConnectionForAStaticSite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testStaticSite0"; + const databaseConnectionName = "default"; + const databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest = {}; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.staticSites.updateDatabaseConnection( + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope + ); + console.log(result); +} + +async function main() { + patchADatabaseConnectionForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteSample.ts index 2cca115e60dd..b39b370fd60a 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Creates a new static site in an existing resource group, or updates an existing static site. * * @summary Description for Creates a new static site in an existing resource group, or updates an existing static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/PatchStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PatchStaticSite.json */ async function patchAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const staticSiteEnvelope: StaticSitePatchResource = {}; const credential = new DefaultAzureCredential(); @@ -35,4 +40,8 @@ async function patchAStaticSite() { console.log(result); } -patchAStaticSite().catch(console.error); +async function main() { + patchAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteUserSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteUserSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteUserSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteUserSample.ts index b40fffcfbb0b..efff06972428 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesUpdateStaticSiteUserSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesUpdateStaticSiteUserSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates a user entry with the listed roles * * @summary Description for Updates a user entry with the listed roles - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdateStaticSiteUser.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateStaticSiteUser.json */ async function createOrUpdateAUserForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const authprovider = "aad"; const userid = "1234"; @@ -41,4 +46,8 @@ async function createOrUpdateAUserForAStaticSite() { console.log(result); } -createOrUpdateAUserForAStaticSite().catch(console.error); +async function main() { + createOrUpdateAUserForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendForBuildSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendForBuildSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendForBuildSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendForBuildSample.ts index 81bbd89fd34b..a891d41a1703 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendForBuildSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendForBuildSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site build * * @summary Validates that a backend can be linked to a static site build - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSiteBuild.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSiteBuild.json */ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const environmentName = "default"; const linkedBackendName = "testBackend"; @@ -43,4 +48,8 @@ async function validateIfBackendCanBeLinkedToStaticSiteBuild() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSiteBuild().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSiteBuild(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendSample.ts index a68feb596daf..53e147d740b0 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateBackendSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateBackendSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates that a backend can be linked to a static site * * @summary Validates that a backend can be linked to a static site - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateLinkedBackendForStaticSite.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateLinkedBackendForStaticSite.json */ async function validateIfBackendCanBeLinkedToStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const linkedBackendName = "testBackend"; const staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource = { @@ -41,4 +46,8 @@ async function validateIfBackendCanBeLinkedToStaticSite() { console.log(result); } -validateIfBackendCanBeLinkedToStaticSite().catch(console.error); +async function main() { + validateIfBackendCanBeLinkedToStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts index 591d3b4d0cf8..7e77d584d943 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/staticSitesValidateCustomDomainCanBeAddedToStaticSiteSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Validates a particular custom domain can be added to a static site. * * @summary Description for Validates a particular custom domain can be added to a static site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ValidateStaticSiteCustomDomain.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ValidateStaticSiteCustomDomain.json */ async function validateACustomDomainForAStaticSite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testStaticSite0"; const domainName = "custom.domain.net"; const staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource = {}; @@ -37,4 +42,8 @@ async function validateACustomDomainForAStaticSite() { console.log(result); } -validateACustomDomainForAStaticSite().catch(console.error); +async function main() { + validateACustomDomainForAStaticSite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsGetSample.ts new file mode 100644 index 000000000000..a9b1ba3a0de1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsGetSample.ts @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get details of a top-level domain. + * + * @summary Description for Get details of a top-level domain. + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/GetTopLevelDomain.json + */ +async function getTopLevelDomain() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const name = "com"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.topLevelDomains.get(name); + console.log(result); +} + +async function main() { + getTopLevelDomain(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListAgreementsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListAgreementsSample.ts similarity index 80% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListAgreementsSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListAgreementsSample.ts index f0a47c08a7a3..c7ca45f1b500 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListAgreementsSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListAgreementsSample.ts @@ -13,15 +13,20 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Gets all legal agreements that user needs to accept before purchasing a domain. * * @summary Description for Gets all legal agreements that user needs to accept before purchasing a domain. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomainAgreements.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomainAgreements.json */ async function listTopLevelDomainAgreements() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const name = "in"; const agreementOption: TopLevelDomainAgreementOption = { forTransfer: false, @@ -39,4 +44,8 @@ async function listTopLevelDomainAgreements() { console.log(resArray); } -listTopLevelDomainAgreements().catch(console.error); +async function main() { + listTopLevelDomainAgreements(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListSample.ts index ebbf654f6e8d..5a1601c0c5d5 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/topLevelDomainsListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/topLevelDomainsListSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Get all top-level domains supported for registration. * * @summary Description for Get all top-level domains supported for registration. - * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-03-01/examples/ListTopLevelDomains.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.DomainRegistration/stable/2022-09-01/examples/ListTopLevelDomains.json */ async function listTopLevelDomains() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const credential = new DefaultAzureCredential(); const client = new WebSiteManagementClient(credential, subscriptionId); const resArray = new Array(); @@ -28,4 +33,8 @@ async function listTopLevelDomains() { console.log(resArray); } -listTopLevelDomains().catch(console.error); +async function main() { + listTopLevelDomains(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/verifyHostingEnvironmentVnetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/verifyHostingEnvironmentVnetSample.ts similarity index 79% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/verifyHostingEnvironmentVnetSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/verifyHostingEnvironmentVnetSample.ts index 10cf15881fc2..9476536652f8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/verifyHostingEnvironmentVnetSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/verifyHostingEnvironmentVnetSample.ts @@ -10,15 +10,20 @@ // Licensed under the MIT License. import { VnetParameters, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. * * @summary Description for Verifies if this VNET is compatible with an App Service Environment by analyzing the Network Security Group rules. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/VerifyHostingEnvironmentVnet.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/VerifyHostingEnvironmentVnet.json */ async function verifyHostingEnvironmentVnet() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; const parameters: VnetParameters = { vnetName: "vNet123", vnetResourceGroup: "vNet123rg", @@ -30,4 +35,8 @@ async function verifyHostingEnvironmentVnet() { console.log(result); } -verifyHostingEnvironmentVnet().catch(console.error); +async function main() { + verifyHostingEnvironmentVnet(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSample.ts new file mode 100644 index 000000000000..bcad087a48dc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostName.json + */ +async function analyzeCustomHostnameForWebapp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostname( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForWebapp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSlotSample.ts new file mode 100644 index 000000000000..0d40d71bb32d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsAnalyzeCustomHostnameSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Analyze a custom hostname. + * + * @summary Description for Analyze a custom hostname. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/AnalyzeCustomHostNameSlot.json + */ +async function analyzeCustomHostnameForSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.analyzeCustomHostnameSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + analyzeCustomHostnameForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApplySlotConfigToProductionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApplySlotConfigToProductionSample.ts new file mode 100644 index 000000000000..4e8bd9175b21 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApplySlotConfigToProductionSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { CsmSlotEntity, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Applies the configuration settings from the target slot onto the current slot. + * + * @summary Description for Applies the configuration settings from the target slot onto the current slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApplySlotConfig.json + */ +async function applyWebAppSlotConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slotSwapEntity: CsmSlotEntity = { + preserveVnet: true, + targetSlot: "staging" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.applySlotConfigToProduction( + resourceGroupName, + name, + slotSwapEntity + ); + console.log(result); +} + +async function main() { + applyWebAppSlotConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts similarity index 77% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts index f4d0ec7095c8..b99f5282fb79 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnection.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnection.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource = { @@ -43,4 +48,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts similarity index 78% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts index a8c65aeaa6a0..1ed3bdfe2fd7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsApproveOrRejectPrivateEndpointConnectionSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Approves or rejects a private endpoint connection * * @summary Description for Approves or rejects a private endpoint connection - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ApproveRejectSitePrivateEndpointConnectionSlot.json */ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const privateEndpointConnectionName = "connection"; const slot = "stage"; @@ -45,4 +50,8 @@ async function approvesOrRejectsAPrivateEndpointConnectionForASite() { console.log(result); } -approvesOrRejectsAPrivateEndpointConnectionForASite().catch(console.error); +async function main() { + approvesOrRejectsAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsBackupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsBackupSample.ts new file mode 100644 index 000000000000..8766e5f3d81c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsBackupSample.ts @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { BackupRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a backup of an app. + * + * @summary Description for Creates a backup of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/BackupWebApp.json + */ +async function backupWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const request: BackupRequest = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z") + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.backup(resourceGroupName, name, request); + console.log(result); +} + +async function main() { + backupWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateConfigurationSample.ts new file mode 100644 index 000000000000..14513b3693fe --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateConfigurationSample.ts @@ -0,0 +1,94 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteConfigResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the configuration of an app. + * + * @summary Description for Updates the configuration of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateSiteConfig.json + */ +async function updateSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteConfig: SiteConfigResource = { + acrUseManagedIdentityCreds: false, + alwaysOn: false, + appCommandLine: "", + autoHealEnabled: false, + azureStorageAccounts: {}, + defaultDocuments: [ + "Default.htm", + "Default.html", + "Default.asp", + "index.htm", + "index.html", + "iisstart.htm", + "default.aspx", + "index.php", + "hostingstart.html" + ], + detailedErrorLoggingEnabled: false, + ftpsState: "AllAllowed", + functionAppScaleLimit: 0, + functionsRuntimeScaleMonitoringEnabled: false, + http20Enabled: false, + httpLoggingEnabled: false, + linuxFxVersion: "", + loadBalancing: "LeastRequests", + logsDirectorySizeLimit: 35, + managedPipelineMode: "Integrated", + minTlsVersion: "1.2", + minimumElasticInstanceCount: 0, + netFrameworkVersion: "v4.0", + nodeVersion: "", + numberOfWorkers: 1, + phpVersion: "5.6", + powerShellVersion: "", + pythonVersion: "", + remoteDebuggingEnabled: false, + requestTracingEnabled: false, + scmMinTlsVersion: "1.2", + use32BitWorkerProcess: true, + virtualApplications: [ + { physicalPath: "site\\wwwroot", preloadEnabled: false, virtualPath: "/" } + ], + vnetName: "", + vnetPrivatePortsCount: 0, + vnetRouteAllEnabled: false, + webSocketsEnabled: false + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.createOrUpdateConfiguration( + resourceGroupName, + name, + siteConfig + ); + console.log(result); +} + +async function main() { + updateSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSample.ts new file mode 100644 index 000000000000..25f0711154a9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSample.ts @@ -0,0 +1,90 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { Site, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebApp.json + */ +async function cloneWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: Site = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478", + sourceWebAppLocation: "West Europe" + }, + kind: "app", + location: "East US" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebApp.json + */ +async function createOrUpdateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: Site = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateAndWait( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebApp(); + createOrUpdateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSlotSample.ts new file mode 100644 index 000000000000..e562df125ec1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsCreateOrUpdateSlotSample.ts @@ -0,0 +1,94 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { Site, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CloneWebAppSlot.json + */ +async function cloneWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: Site = { + cloningInfo: { + appSettingsOverrides: { setting1: "NewValue1", setting3: "NewValue5" }, + cloneCustomHostNames: true, + cloneSourceControl: true, + configureLoadBalancing: false, + hostingEnvironment: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites", + overwrite: false, + sourceWebAppId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478/slot/qa", + sourceWebAppLocation: "West Europe" + }, + kind: "app", + location: "East US" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/CreateOrUpdateWebAppSlot.json + */ +async function createOrUpdateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: Site = { + kind: "app", + location: "East US", + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginCreateOrUpdateSlotAndWait( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +async function main() { + cloneWebAppSlot(); + createOrUpdateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteBackupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteBackupSample.ts new file mode 100644 index 000000000000..e97ea1fff74c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteBackupSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a backup of an app by its ID. + * + * @summary Description for Deletes a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppBackup.json + */ +async function deleteWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteBackup( + resourceGroupName, + name, + backupId + ); + console.log(result); +} + +async function main() { + deleteWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..7586afdecdf0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnection.json + */ +async function deleteAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginDeletePrivateEndpointConnectionAndWait( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts new file mode 100644 index 000000000000..74b674a4922a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeletePrivateEndpointConnectionSlotSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a private endpoint connection + * + * @summary Description for Deletes a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteSitePrivateEndpointConnectionSlot.json + */ +async function deleteAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginDeletePrivateEndpointConnectionSlotAndWait( + resourceGroupName, + name, + privateEndpointConnectionName, + slot + ); + console.log(result); +} + +async function main() { + deleteAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSample.ts new file mode 100644 index 000000000000..1763530f2c50 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebApp.json + */ +async function deleteWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.delete(resourceGroupName, name); + console.log(result); +} + +async function main() { + deleteWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSlotSample.ts new file mode 100644 index 000000000000..47a8f7941adc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeleteSlotSample.ts @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * + * @summary Description for Deletes a web, mobile, or API app, or one of the deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteWebAppSlot.json + */ +async function deleteWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deleteSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + deleteWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSample.ts new file mode 100644 index 000000000000..32c5bce632cf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSample.ts @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkflowArtifacts, + WebAppsDeployWorkflowArtifactsOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/DeleteDeployWorkflowArtifacts.json + */ +async function deleteWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts: WorkflowArtifacts = { + filesToDelete: ["test/workflow.json", "test/"] + }; + const options: WebAppsDeployWorkflowArtifactsOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts( + resourceGroupName, + name, + options + ); + console.log(result); +} + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifacts.json + */ +async function deploysWorkflowArtifacts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowArtifacts: WorkflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=" + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')" + }, + serviceProvider: { id: "/serviceProviders/eventHub" } + } + } + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub" + } + }, + splitOn: "@triggerOutputs()?['body']" + } + } + }, + kind: "Stateful" + } + } + }; + const options: WebAppsDeployWorkflowArtifactsOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifacts( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + deleteWorkflowArtifacts(); + deploysWorkflowArtifacts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSlotSample.ts new file mode 100644 index 000000000000..bd486e4bb1e7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsDeployWorkflowArtifactsSlotSample.ts @@ -0,0 +1,97 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WorkflowArtifacts, + WebAppsDeployWorkflowArtifactsSlotOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates the artifacts for web site, or a deployment slot. + * + * @summary Description for Creates the artifacts for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/PostDeployWorkflowArtifactsSlot.json + */ +async function deploysWorkflowArtifactsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "testsSlot"; + const workflowArtifacts: WorkflowArtifacts = { + appSettings: { + eventHub_connectionString: + "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=" + }, + files: { + connectionsJson: { + managedApiConnections: {}, + serviceProviderConnections: { + eventHub: { + displayName: "example1", + parameterValues: { + connectionString: "@appsetting('eventHub_connectionString')" + }, + serviceProvider: { id: "/serviceProviders/eventHub" } + } + } + }, + "test1/workflowJson": { + definition: { + $schema: + "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", + actions: {}, + contentVersion: "1.0.0.0", + outputs: {}, + triggers: { + When_events_are_available_in_Event_hub: { + type: "ServiceProvider", + inputs: { + parameters: { eventHubName: "test123" }, + serviceProviderConfiguration: { + operationId: "receiveEvents", + connectionName: "eventHub", + serviceProviderId: "/serviceProviders/eventHub" + } + }, + splitOn: "@triggerOutputs()?['body']" + } + } + }, + kind: "Stateful" + } + } + }; + const options: WebAppsDeployWorkflowArtifactsSlotOptionalParams = { + workflowArtifacts + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.deployWorkflowArtifactsSlot( + resourceGroupName, + name, + slot, + options + ); + console.log(result); +} + +async function main() { + deploysWorkflowArtifactsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts new file mode 100644 index 000000000000..f8808343b15d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the config reference and status of an app + * + * @summary Description for Gets the config reference and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSetting.json + */ +async function getAzureKeyVaultAppSettingReference() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const appSettingKey = "setting"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAppSettingKeyVaultReference( + resourceGroupName, + name, + appSettingKey + ); + console.log(result); +} + +async function main() { + getAzureKeyVaultAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts new file mode 100644 index 000000000000..a6b843cf66e5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingKeyVaultReferenceSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the config reference and status of an app + * + * @summary Description for Gets the config reference and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingSlot.json + */ +async function getAzureKeyVaultSlotAppSettingReference() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const appSettingKey = "setting"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAppSettingKeyVaultReferenceSlot( + resourceGroupName, + name, + appSettingKey, + slot + ); + console.log(result); +} + +async function main() { + getAzureKeyVaultSlotAppSettingReference(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts new file mode 100644 index 000000000000..c146fa391434 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the config reference app settings and status of an app + * + * @summary Description for Gets the config reference app settings and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettings.json + */ +async function getAzureKeyVaultReferencesForAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listAppSettingsKeyVaultReferences( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAzureKeyVaultReferencesForAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts new file mode 100644 index 000000000000..609eaae022e1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAppSettingsKeyVaultReferencesSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the config reference app settings and status of an app + * + * @summary Description for Gets the config reference app settings and status of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetKeyVaultReferencesForAppSettingsSlot.json + */ +async function getAzureKeyVaultReferencesForAppSettingsForSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testc6282"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listAppSettingsKeyVaultReferencesSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + getAzureKeyVaultReferencesForAppSettingsForSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsSample.ts new file mode 100644 index 000000000000..30cbf79d11f6 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the Authentication/Authorization settings of an app. + * + * @summary Description for Gets the Authentication/Authorization settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettings.json + */ +async function listAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettings(resourceGroupName, name); + console.log(result); +} + +async function main() { + listAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2Sample.ts new file mode 100644 index 000000000000..3d2b18bc7686 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2Sample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAuthSettingsV2.json + */ +async function listAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2WithoutSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2WithoutSecretsSample.ts new file mode 100644 index 000000000000..5485b12d4540 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetAuthSettingsV2WithoutSecretsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Gets site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetAuthSettingsV2WithoutSecrets.json + */ +async function listAuthSettingsWithoutSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getAuthSettingsV2WithoutSecrets( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAuthSettingsWithoutSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetBackupStatusSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetBackupStatusSample.ts new file mode 100644 index 000000000000..f9978032959f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetBackupStatusSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a backup of an app by its ID. + * + * @summary Description for Gets a backup of an app by its ID. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackup.json + */ +async function getWebAppBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getBackupStatus( + resourceGroupName, + name, + backupId + ); + console.log(result); +} + +async function main() { + getWebAppBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetConfigurationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetConfigurationSample.ts new file mode 100644 index 000000000000..11959223162a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetConfigurationSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * + * @summary Description for Gets the configuration of an app, such as platform version and bitness, default documents, virtual applications, Always On, etc. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteConfig.json + */ +async function getSiteConfig() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getConfiguration(resourceGroupName, name); + console.log(result); +} + +async function main() { + getSiteConfig(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSample.ts new file mode 100644 index 000000000000..0d27d0cdfc14 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSample.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. + * + * @summary Description for Returns whether FTP is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json + */ +async function getFtpAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getFtpAllowed(resourceGroupName, name); + console.log(result); +} + +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSlotSample.ts new file mode 100644 index 000000000000..b1e1180322ad --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetFtpAllowedSlotSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether FTP is allowed on the site or not. + * + * @summary Description for Returns whether FTP is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json + */ +async function getFtpAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getFtpAllowedSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + getFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSample.ts new file mode 100644 index 000000000000..0ce37409ff07 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all scale-out instances of an app. + * + * @summary Description for Gets all scale-out instances of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json + */ +async function getSiteInstanceInfo() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const instanceId = "134987120"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceInfo( + resourceGroupName, + name, + instanceId + ); + console.log(result); +} + +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSlotSample.ts new file mode 100644 index 000000000000..764af11a164c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceInfoSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all scale-out instances of an app. + * + * @summary Description for Gets all scale-out instances of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteInstanceInfo.json + */ +async function getSiteInstanceInfo() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const instanceId = "134987120"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceInfoSlot( + resourceGroupName, + name, + instanceId, + slot + ); + console.log(result); +} + +async function main() { + getSiteInstanceInfo(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceWorkflowSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceWorkflowSlotSample.ts new file mode 100644 index 000000000000..e95ede26580c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetInstanceWorkflowSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflowSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getInstanceWorkflowSlot( + resourceGroupName, + name, + slot, + workflowName + ); + console.log(result); +} + +async function main() { + getAWorkflowSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSample.ts new file mode 100644 index 000000000000..b2e75d73fe70 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json + */ +async function getTheCurrentStatusOfANetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTraceOperation( + resourceGroupName, + name, + operationId + ); + console.log(result); +} + +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts new file mode 100644 index 000000000000..e72847403828 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json + */ +async function getTheCurrentStatusOfANetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTraceOperationSlot( + resourceGroupName, + name, + operationId, + slot + ); + console.log(result); +} + +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts new file mode 100644 index 000000000000..8a9d21d3ecb7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationSlotV2Sample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json + */ +async function getTheCurrentStatusOfANetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTraceOperationSlotV2( + resourceGroupName, + name, + operationId, + slot + ); + console.log(result); +} + +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts new file mode 100644 index 000000000000..948ae6a5b89c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTraceOperationV2Sample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraceOperation.json + */ +async function getTheCurrentStatusOfANetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTraceOperationV2( + resourceGroupName, + name, + operationId + ); + console.log(result); +} + +async function main() { + getTheCurrentStatusOfANetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSample.ts new file mode 100644 index 000000000000..6dae49c4e26d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json + */ +async function getNetworkTracesForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTraces( + resourceGroupName, + name, + operationId + ); + console.log(result); +} + +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotSample.ts new file mode 100644 index 000000000000..f742085ed5c8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json + */ +async function getNetworkTracesForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTracesSlot( + resourceGroupName, + name, + operationId, + slot + ); + console.log(result); +} + +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts new file mode 100644 index 000000000000..27852fbc531c --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesSlotV2Sample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json + */ +async function getNetworkTracesForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTracesSlotV2( + resourceGroupName, + name, + operationId, + slot + ); + console.log(result); +} + +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesV2Sample.ts new file mode 100644 index 000000000000..fbaa9ca745fb --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetNetworkTracesV2Sample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * + * @summary Description for Gets a named operation for a network trace capturing (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebSiteNetworkTraces.json + */ +async function getNetworkTracesForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const operationId = "c291433b-53ad-4c49-8cae-0a293eae1c6d"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getNetworkTracesV2( + resourceGroupName, + name, + operationId + ); + console.log(result); +} + +async function main() { + getNetworkTracesForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts new file mode 100644 index 000000000000..5acdecb49a0e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnection.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateEndpointConnection( + resourceGroupName, + name, + privateEndpointConnectionName + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts new file mode 100644 index 000000000000..da054721f53d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateEndpointConnectionSlotSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets a private endpoint connection + * + * @summary Description for Gets a private endpoint connection + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateEndpointConnectionSlot.json + */ +async function getAPrivateEndpointConnectionForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const privateEndpointConnectionName = "connection"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateEndpointConnectionSlot( + resourceGroupName, + name, + privateEndpointConnectionName, + slot + ); + console.log(result); +} + +async function main() { + getAPrivateEndpointConnectionForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSample.ts new file mode 100644 index 000000000000..15563242f95a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSample.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResources.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateLinkResources( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts new file mode 100644 index 000000000000..b7ba09054e74 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetPrivateLinkResourcesSlotSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the private link resources + * + * @summary Description for Gets the private link resources + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSitePrivateLinkResourcesSlot.json + */ +async function getPrivateLinkResourcesOfASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getPrivateLinkResourcesSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + getPrivateLinkResourcesOfASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts new file mode 100644 index 000000000000..465f2052cfa1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetProductionSiteDeploymentStatusSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). + * + * @summary Gets the deployment status for an app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatus.json + */ +async function getDeploymentStatus() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginGetProductionSiteDeploymentStatusAndWait( + resourceGroupName, + name, + deploymentStatusId + ); + console.log(result); +} + +async function main() { + getDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSample.ts new file mode 100644 index 000000000000..68a1cd0a4c9f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebApp.json + */ +async function getWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.get(resourceGroupName, name); + console.log(result); +} + +async function main() { + getWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSample.ts new file mode 100644 index 000000000000..7b49cec22078 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSample.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. + * + * @summary Description for Returns whether Scm basic auth is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicy.json + */ +async function getScmAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getScmAllowed(resourceGroupName, name); + console.log(result); +} + +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSlotSample.ts new file mode 100644 index 000000000000..204e3e40cc6a --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetScmAllowedSlotSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed on the site or not. + * + * @summary Description for Returns whether Scm basic auth is allowed on the site or not. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetPublishingCredentialsPolicySlot.json + */ +async function getScmAllowed() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getScmAllowedSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + getScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSample.ts new file mode 100644 index 000000000000..7812d49e5108 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSample.ts @@ -0,0 +1,41 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the details of a web, mobile, or API app. + * + * @summary Description for Gets the details of a web, mobile, or API app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppSlot.json + */ +async function getWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getSlot(resourceGroupName, name, slot); + console.log(result); +} + +async function main() { + getWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts new file mode 100644 index 000000000000..ca3166e9be4f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetSlotSiteDeploymentStatusSlotSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets the deployment status for an app (or deployment slot, if specified). + * + * @summary Gets the deployment status for an app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetSiteDeploymentStatusSlot.json + */ +async function getDeploymentStatusSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const deploymentStatusId = "eacfd68b-3bbd-4ad9-99c5-98614d89c8e5"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginGetSlotSiteDeploymentStatusSlotAndWait( + resourceGroupName, + name, + slot, + deploymentStatusId + ); + console.log(result); +} + +async function main() { + getDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetWorkflowSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetWorkflowSample.ts new file mode 100644 index 000000000000..fe4f81bc386e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsGetWorkflowSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get workflow information by its ID for web site, or a deployment slot. + * + * @summary Get workflow information by its ID for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWorkflow.json + */ +async function getAWorkflow() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const workflowName = "stateful1"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.getWorkflow( + resourceGroupName, + name, + workflowName + ); + console.log(result); +} + +async function main() { + getAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListApplicationSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListApplicationSettingsSample.ts new file mode 100644 index 000000000000..f4460c03e9f1 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListApplicationSettingsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets the application settings of an app. + * + * @summary Description for Gets the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListAppSettings.json + */ +async function listAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listApplicationSettings( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupStatusSecretsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupStatusSecretsSample.ts new file mode 100644 index 000000000000..cfac0cf36402 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupStatusSecretsSample.ts @@ -0,0 +1,75 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { BackupRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * + * @summary Description for Gets status of a web app backup that may be in progress, including secrets associated with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is passed in the request body. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/GetWebAppBackupWithSecrets.json + */ +async function getWebAppBackupWithSecrets() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "12345"; + const request: BackupRequest = { + backupName: "abcdwe", + backupSchedule: { + frequencyInterval: 7, + frequencyUnit: "Day", + keepAtLeastOneBackup: true, + retentionPeriodInDays: 30, + startTime: new Date("2022-09-02T17:33:11.641Z") + }, + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + enabled: true, + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listBackupStatusSecrets( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + getWebAppBackupWithSecrets(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupsSample.ts new file mode 100644 index 000000000000..a126c4b34cfd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBackupsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppBackups.json + */ +async function listWebAppBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listBackups(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts new file mode 100644 index 000000000000..f4b061043666 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. + * + * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPolicies.json + */ +async function listPublishingCredentialsPolicies() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listBasicPublishingCredentialsPolicies( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts new file mode 100644 index 000000000000..6e4216c411a9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListBasicPublishingCredentialsPoliciesSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. + * + * @summary Description for Returns whether Scm basic auth is allowed and whether Ftp is allowed for a given site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListPublishingCredentialsPoliciesSlot.json + */ +async function listPublishingCredentialsPolicies() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "3fb8d758-2e2c-42e9-a528-a8acdfe87237"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listBasicPublishingCredentialsPoliciesSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listPublishingCredentialsPolicies(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListByResourceGroupSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListByResourceGroupSample.ts new file mode 100644 index 000000000000..f9268fe26b0d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListByResourceGroupSample.ts @@ -0,0 +1,44 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets all web, mobile, and API apps in the specified resource group. + * + * @summary Description for Gets all web, mobile, and API apps in the specified resource group. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppsByResourceGroup.json + */ +async function listWebAppsByResourceGroup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listByResourceGroup( + resourceGroupName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsByResourceGroup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListConfigurationsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListConfigurationsSample.ts new file mode 100644 index 000000000000..2b51c9740829 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListConfigurationsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for List the configurations of an app + * + * @summary Description for List the configurations of an app + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppConfigurations.json + */ +async function listWebAppConfigurations() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listConfigurations( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppConfigurations(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListInstanceWorkflowsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListInstanceWorkflowsSlotSample.ts new file mode 100644 index 000000000000..713012069ad2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListInstanceWorkflowsSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflowsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listInstanceWorkflowsSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflowsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts new file mode 100644 index 000000000000..641410086937 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListProductionSiteDeploymentStatusesSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). + * + * @summary List deployment statuses for an app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatus.json + */ +async function listDeploymentStatus() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listProductionSiteDeploymentStatuses( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDeploymentStatus(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSample.ts new file mode 100644 index 000000000000..5417760c9e0e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Get all apps for a subscription. + * + * @summary Description for Get all apps for a subscription. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebApps.json + */ +async function listWebAppsForSubscription() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.list()) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppsForSubscription(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSample.ts new file mode 100644 index 000000000000..c58f857b8ea5 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json + */ +async function listBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSiteBackups( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSlotSample.ts new file mode 100644 index 000000000000..f1299f6aae7b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSiteBackupsSlotSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets existing backups of an app. + * + * @summary Description for Gets existing backups of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSlotBackups.json + */ +async function listBackups() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "tests346"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSiteBackupsSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listBackups(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts new file mode 100644 index 000000000000..abb3eb7b6b2f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotSiteDeploymentStatusesSlotSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List deployment statuses for an app (or deployment slot, if specified). + * + * @summary List deployment statuses for an app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListSiteDeploymentStatusSlot.json + */ +async function listDeploymentStatusSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; + const name = "testSite"; + const slot = "stage"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSlotSiteDeploymentStatusesSlot( + resourceGroupName, + name, + slot + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listDeploymentStatusSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotsSample.ts new file mode 100644 index 000000000000..0ad04fc540f3 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListSlotsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Gets an app's deployment slots. + * + * @summary Description for Gets an app's deployment slots. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWebAppSlots.json + */ +async function listWebAppSlots() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listSlots(resourceGroupName, name)) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWebAppSlots(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSample.ts new file mode 100644 index 000000000000..8393ca49406b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnections() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnections( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnections(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSlotSample.ts new file mode 100644 index 000000000000..e489da63458f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsConnectionsSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Lists logic app's connections for web site, or a deployment slot. + * + * @summary Lists logic app's connections for web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflowsConfigurationConnections.json + */ +async function listTheInstanceWorkflowsConfigurationConnectionsSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const slot = "staging"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.listWorkflowsConnectionsSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + listTheInstanceWorkflowsConfigurationConnectionsSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsSample.ts new file mode 100644 index 000000000000..8efe01d4b0d8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsListWorkflowsSample.ts @@ -0,0 +1,46 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List the workflows for a web site, or a deployment slot. + * + * @summary List the workflows for a web site, or a deployment slot. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/ListWorkflows.json + */ +async function listTheWorkflows() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "testsite2"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.webApps.listWorkflows( + resourceGroupName, + name + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheWorkflows(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsRestoreSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsRestoreSample.ts new file mode 100644 index 000000000000..9b9e791b7e29 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsRestoreSample.ts @@ -0,0 +1,68 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { RestoreRequest, WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Restores a specific backup to another app (or deployment slot, if specified). + * + * @summary Description for Restores a specific backup to another app (or deployment slot, if specified). + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/RestoreWebAppBackup.json + */ +async function restoreWebAppFromBackup() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const backupId = "123244"; + const request: RestoreRequest = { + databases: [ + { + name: "backenddb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "backend", + databaseType: "SqlAzure" + }, + { + name: "statsdb", + connectionString: + "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;=]", + connectionStringName: "stats", + databaseType: "SqlAzure" + } + ], + overwrite: true, + siteName: "sitef6141", + storageAccountUrl: + "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginRestoreAndWait( + resourceGroupName, + name, + backupId, + request + ); + console.log(result); +} + +async function main() { + restoreWebAppFromBackup(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSample.ts new file mode 100644 index 000000000000..3c2810003c98 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WebAppsStartNetworkTraceOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Start capturing network packets for the site. + * + * @summary Description for Start capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json + */ +async function startANewNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const durationInSeconds = 60; + const options: WebAppsStartNetworkTraceOptionalParams = { durationInSeconds }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginStartNetworkTraceAndWait( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSlotSample.ts new file mode 100644 index 000000000000..c243fa17bad8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartNetworkTraceSlotSample.ts @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WebAppsStartNetworkTraceSlotOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Start capturing network packets for the site. + * + * @summary Description for Start capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json + */ +async function startANewNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const durationInSeconds = 60; + const slot = "Production"; + const options: WebAppsStartNetworkTraceSlotOptionalParams = { + durationInSeconds + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginStartNetworkTraceSlotAndWait( + resourceGroupName, + name, + slot, + options + ); + console.log(result); +} + +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts new file mode 100644 index 000000000000..a88910e0bd30 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + WebAppsStartWebSiteNetworkTraceOperationOptionalParams, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Start capturing network packets for the site. + * + * @summary Description for Start capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json + */ +async function startANewNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const durationInSeconds = 60; + const options: WebAppsStartWebSiteNetworkTraceOperationOptionalParams = { + durationInSeconds + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.beginStartWebSiteNetworkTraceOperationAndWait( + resourceGroupName, + name, + options + ); + console.log(result); +} + +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts index f3121910fa8c..4c33e968431d 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStartWebSiteNetworkTraceOperationSlotSample.ts @@ -13,16 +13,22 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Start capturing network packets for the site. * * @summary Description for Start capturing network packets for the site. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/StartWebSiteNetworkTraceOperation.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StartWebSiteNetworkTraceOperation.json */ async function startANewNetworkTraceOperationForASite() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testrg123"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; const name = "SampleApp"; const durationInSeconds = 60; const slot = "Production"; @@ -40,4 +46,8 @@ async function startANewNetworkTraceOperationForASite() { console.log(result); } -startANewNetworkTraceOperationForASite().catch(console.error); +async function main() { + startANewNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSample.ts new file mode 100644 index 000000000000..bdf7301821b9 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSample.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopNetworkTrace(resourceGroupName, name); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSlotSample.ts new file mode 100644 index 000000000000..f65fa70ce6f0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopNetworkTraceSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopNetworkTraceSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts new file mode 100644 index 000000000000..a369cc8ad1bc --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSample.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopWebSiteNetworkTrace( + resourceGroupName, + name + ); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts new file mode 100644 index 000000000000..48c6decc3458 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsStopWebSiteNetworkTraceSlotSample.ts @@ -0,0 +1,45 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Stop ongoing capturing network packets for the site. + * + * @summary Description for Stop ongoing capturing network packets for the site. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/StopWebSiteNetworkTrace.json + */ +async function stopACurrentlyRunningNetworkTraceOperationForASite() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "SampleApp"; + const slot = "Production"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.stopWebSiteNetworkTraceSlot( + resourceGroupName, + name, + slot + ); + console.log(result); +} + +async function main() { + stopACurrentlyRunningNetworkTraceOperationForASite(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateApplicationSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateApplicationSettingsSample.ts new file mode 100644 index 000000000000..361478c3641f --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateApplicationSettingsSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + StringDictionary, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Replaces the application settings of an app. + * + * @summary Description for Replaces the application settings of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAppSettings.json + */ +async function updateAppSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const appSettings: StringDictionary = { + properties: { setting1: "Value1", setting2: "Value2" } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateApplicationSettings( + resourceGroupName, + name, + appSettings + ); + console.log(result); +} + +async function main() { + updateAppSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsSample.ts new file mode 100644 index 000000000000..656e9145eea4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsSample.ts @@ -0,0 +1,60 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteAuthSettings, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the Authentication / Authorization settings associated with web app. + * + * @summary Description for Updates the Authentication / Authorization settings associated with web app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettings.json + */ +async function updateAuthSettings() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettings: SiteAuthSettings = { + allowedExternalRedirectUrls: [ + "sitef6141.customdomain.net", + "sitef6141.customdomain.info" + ], + clientId: "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + defaultProvider: "Google", + enabled: true, + runtimeVersion: "~1", + tokenRefreshExtensionHours: 120, + tokenStoreEnabled: true, + unauthenticatedClientAction: "RedirectToLoginPage" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettings( + resourceGroupName, + name, + siteAuthSettings + ); + console.log(result); +} + +async function main() { + updateAuthSettings(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsV2Sample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsV2Sample.ts new file mode 100644 index 000000000000..d149b945fecf --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAuthSettingsV2Sample.ts @@ -0,0 +1,95 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SiteAuthSettingsV2, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * + * @summary Description for Updates site's Authentication / Authorization settings for apps via the V2 format + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAuthSettingsV2.json + */ +async function updateAuthSettingsV2() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteAuthSettingsV2: SiteAuthSettingsV2 = { + globalValidation: { + excludedPaths: ["/nosecrets/Path"], + requireAuthentication: true, + unauthenticatedClientAction: "Return403" + }, + httpSettings: { + forwardProxy: { + convention: "Standard", + customHostHeaderName: "authHeader", + customProtoHeaderName: "customProtoHeader" + }, + requireHttps: true, + routes: { apiPrefix: "/authv2/" } + }, + identityProviders: { + google: { + enabled: true, + login: { scopes: ["admin"] }, + registration: { + clientId: + "42d795a9-8abb-4d06-8534-39528af40f8e.apps.googleusercontent.com", + clientSecretSettingName: "ClientSecret" + }, + validation: { allowedAudiences: ["https://example.com"] } + } + }, + login: { + allowedExternalRedirectUrls: ["https://someurl.com"], + cookieExpiration: { + convention: "IdentityProviderDerived", + timeToExpiration: "2022:09-01T00:00Z" + }, + nonce: { validateNonce: true }, + preserveUrlFragmentsForLogins: true, + routes: { logoutEndpoint: "https://app.com/logout" }, + tokenStore: { + enabled: true, + fileSystem: { directory: "/wwwroot/sites/example" }, + tokenRefreshExtensionHours: 96 + } + }, + platform: { + configFilePath: "/auth/config.json", + enabled: true, + runtimeVersion: "~1" + } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAuthSettingsV2( + resourceGroupName, + name, + siteAuthSettingsV2 + ); + console.log(result); +} + +async function main() { + updateAuthSettingsV2(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAzureStorageAccountsSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAzureStorageAccountsSample.ts new file mode 100644 index 000000000000..9a3de035d51e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateAzureStorageAccountsSample.ts @@ -0,0 +1,58 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + AzureStoragePropertyDictionaryResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Updates the Azure storage account configurations of an app. + * + * @summary Description for Updates the Azure storage account configurations of an app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateAzureStorageAccounts.json + */ +async function updateAzureStorageAccounts() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const azureStorageAccounts: AzureStoragePropertyDictionaryResource = { + properties: { + account1: { + type: "AzureFiles", + accessKey: "26515^%@#*", + accountName: "testsa", + mountPath: "/mounts/a/files", + shareName: "web" + } + } + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateAzureStorageAccounts( + resourceGroupName, + name, + azureStorageAccounts + ); + console.log(result); +} + +async function main() { + updateAzureStorageAccounts(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSample.ts index 13dfbde33aa7..8252da8b5771 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { allow: true @@ -37,4 +42,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts index 33c958c415c9..2586825e6474 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateFtpAllowedSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether FTP is allowed on the site or not. * * @summary Description for Updates whether FTP is allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateFtpAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { @@ -39,4 +44,8 @@ async function updateFtpAllowed() { console.log(result); } -updateFtpAllowed().catch(console.error); +async function main() { + updateFtpAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSample.ts new file mode 100644 index 000000000000..8472c85c3e20 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SitePatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebApp.json + */ +async function updateWebApp() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const siteEnvelope: SitePatchResource = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.update( + resourceGroupName, + name, + siteEnvelope + ); + console.log(result); +} + +async function main() { + updateWebApp(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSample.ts index bf76405702f3..5bfd0d2936c8 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicy.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicy.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { allow: true @@ -37,4 +42,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSlotSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSlotSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSlotSample.ts index 4c68d91a5b6b..124d64cf960b 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/webAppsUpdateScmAllowedSlotSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateScmAllowedSlotSample.ts @@ -13,16 +13,21 @@ import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Description for Updates whether user publishing credentials are allowed on the site or not. * * @summary Description for Updates whether user publishing credentials are allowed on the site or not. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/UpdatePublishingCredentialsPolicySlot.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdatePublishingCredentialsPolicySlot.json */ async function updateScmAllowed() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = process.env["APPSERVICE_RESOURCE_GROUP"] || "rg"; const name = "testSite"; const slot = "stage"; const csmPublishingAccessPoliciesEntity: CsmPublishingCredentialsPoliciesEntity = { @@ -39,4 +44,8 @@ async function updateScmAllowed() { console.log(result); } -updateScmAllowed().catch(console.error); +async function main() { + updateScmAllowed(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSlotSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSlotSample.ts new file mode 100644 index 000000000000..3be940d1f3b8 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/webAppsUpdateSlotSample.ts @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + SitePatchResource, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * + * @summary Description for Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/UpdateWebAppSlot.json + */ +async function updateWebAppSlot() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testrg123"; + const name = "sitef6141"; + const slot = "staging"; + const siteEnvelope: SitePatchResource = { + serverFarmId: + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp" + }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.webApps.updateSlot( + resourceGroupName, + name, + slot, + siteEnvelope + ); + console.log(result); +} + +async function main() { + updateWebAppSlot(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsGetSample.ts new file mode 100644 index 000000000000..ebbb15619c54 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsGetSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get a workflow run action repetition. + * + * @summary Get a workflow run action repetition. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_Get.json + */ +async function getARepetition() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testFlow"; + const runName = "08586776228332053161046300351"; + const actionName = "testAction"; + const repetitionName = "000001"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRunActionRepetitions.get( + resourceGroupName, + name, + workflowName, + runName, + actionName, + repetitionName + ); + console.log(result); +} + +async function main() { + getARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts index 1bfb55d6750d..31e854e91773 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListExpressionTracesSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Lists a workflow run expression trace. * * @summary Lists a workflow run expression trace. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_ListExpressionTraces.json */ async function listExpressionTracesForARepetition() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "testResourceGroup"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; const name = "test-name"; const workflowName = "testFlow"; const runName = "08586776228332053161046300351"; @@ -41,4 +47,8 @@ async function listExpressionTracesForARepetition() { console.log(resArray); } -listExpressionTracesForARepetition().catch(console.error); +async function main() { + listExpressionTracesForARepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListSample.ts new file mode 100644 index 000000000000..c3a7d4d0b3b0 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsListSample.ts @@ -0,0 +1,52 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get all of a workflow run action repetitions. + * + * @summary Get all of a workflow run action repetitions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitions_List.json + */ +async function listRepetitions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testFlow"; + const runName = "08586776228332053161046300351"; + const actionName = "testAction"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRunActionRepetitions.list( + resourceGroupName, + name, + workflowName, + runName, + actionName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts index 77c5c8f3a8a1..bc68cf8af1b6 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesGetSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Gets a workflow run repetition request history. * * @summary Gets a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_Get.json */ async function getARepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -40,4 +46,8 @@ async function getARepetitionRequestHistory() { console.log(result); } -getARepetitionRequestHistory().catch(console.error); +async function main() { + getARepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts similarity index 75% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts index 118b70159e15..c3db848d54c6 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionRepetitionsRequestHistoriesListSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to List a workflow run repetition request history. * * @summary List a workflow run repetition request history. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionRepetitionsRequestHistories_List.json */ async function listRepetitionRequestHistory() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const runName = "08586776228332053161046300351"; @@ -41,4 +47,8 @@ async function listRepetitionRequestHistory() { console.log(resArray); } -listRepetitionRequestHistory().catch(console.error); +async function main() { + listRepetitionRequestHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts new file mode 100644 index 000000000000..91f523ffaadd --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsGetSample.ts @@ -0,0 +1,51 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get a workflow run action scoped repetition. + * + * @summary Get a workflow run action scoped repetition. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_Get.json + */ +async function getAScopedRepetition() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testFlow"; + const runName = "08586776228332053161046300351"; + const actionName = "for_each"; + const repetitionName = "000000"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRunActionScopeRepetitions.get( + resourceGroupName, + name, + workflowName, + runName, + actionName, + repetitionName + ); + console.log(result); +} + +async function main() { + getAScopedRepetition(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsListSample.ts new file mode 100644 index 000000000000..e0d1e575ee86 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionScopeRepetitionsListSample.ts @@ -0,0 +1,52 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to List the workflow run action scoped repetitions. + * + * @summary List the workflow run action scoped repetitions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActionScopeRepetitions_List.json + */ +async function listTheScopedRepetitions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testFlow"; + const runName = "08586776228332053161046300351"; + const actionName = "for_each"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRunActionScopeRepetitions.list( + resourceGroupName, + name, + workflowName, + runName, + actionName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listTheScopedRepetitions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsGetSample.ts new file mode 100644 index 000000000000..1738062e556d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsGetSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a workflow run action. + * + * @summary Gets a workflow run action. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_Get.json + */ +async function getAWorkflowRunAction() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const actionName = "HTTP"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRunActions.get( + resourceGroupName, + name, + workflowName, + runName, + actionName + ); + console.log(result); +} + +async function main() { + getAWorkflowRunAction(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListExpressionTracesSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListExpressionTracesSample.ts new file mode 100644 index 000000000000..33f29b1684ba --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListExpressionTracesSample.ts @@ -0,0 +1,52 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Lists a workflow run expression trace. + * + * @summary Lists a workflow run expression trace. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_ListExpressionTraces.json + */ +async function listExpressionTraces() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testFlow"; + const runName = "08586776228332053161046300351"; + const actionName = "testAction"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRunActions.listExpressionTraces( + resourceGroupName, + name, + workflowName, + runName, + actionName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listExpressionTraces(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListSample.ts new file mode 100644 index 000000000000..5c0b12b48dae --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunActionsListSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a list of workflow run actions. + * + * @summary Gets a list of workflow run actions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRunActions_List.json + */ +async function listAWorkflowRunActions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRunActions.list( + resourceGroupName, + name, + workflowName, + runName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAWorkflowRunActions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsCancelSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsCancelSample.ts new file mode 100644 index 000000000000..ccebfe60e65e --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsCancelSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Cancels a workflow run. + * + * @summary Cancels a workflow run. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Cancel.json + */ +async function cancelAWorkflowRun() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRuns.cancel( + resourceGroupName, + name, + workflowName, + runName + ); + console.log(result); +} + +async function main() { + cancelAWorkflowRun(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsGetSample.ts new file mode 100644 index 000000000000..1cda67b8be96 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsGetSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a workflow run. + * + * @summary Gets a workflow run. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_Get.json + */ +async function getARunForAWorkflow() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const runName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowRuns.get( + resourceGroupName, + name, + workflowName, + runName + ); + console.log(result); +} + +async function main() { + getARunForAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsListSample.ts new file mode 100644 index 000000000000..7df513a093da --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowRunsListSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a list of workflow runs. + * + * @summary Gets a list of workflow runs. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowRuns_List.json + */ +async function listWorkflowRuns() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowRuns.list( + resourceGroupName, + name, + workflowName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWorkflowRuns(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesGetSample.ts new file mode 100644 index 000000000000..b9912e821eba --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesGetSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a workflow trigger history. + * + * @summary Gets a workflow trigger history. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Get.json + */ +async function getAWorkflowTriggerHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const triggerName = "testTriggerName"; + const historyName = "08586676746934337772206998657CU22"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggerHistories.get( + resourceGroupName, + name, + workflowName, + triggerName, + historyName + ); + console.log(result); +} + +async function main() { + getAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesListSample.ts new file mode 100644 index 000000000000..f892c803e743 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesListSample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a list of workflow trigger histories. + * + * @summary Gets a list of workflow trigger histories. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_List.json + */ +async function listAWorkflowTriggerHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const triggerName = "testTriggerName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowTriggerHistories.list( + resourceGroupName, + name, + workflowName, + triggerName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAWorkflowTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesResubmitSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesResubmitSample.ts new file mode 100644 index 000000000000..4203051c5e3d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggerHistoriesResubmitSample.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Resubmits a workflow run based on the trigger history. + * + * @summary Resubmits a workflow run based on the trigger history. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggerHistories_Resubmit.json + */ +async function resubmitAWorkflowRunBasedOnTheTriggerHistory() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const triggerName = "testTriggerName"; + const historyName = "testHistoryName"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggerHistories.beginResubmitAndWait( + resourceGroupName, + name, + workflowName, + triggerName, + historyName + ); + console.log(result); +} + +async function main() { + resubmitAWorkflowRunBasedOnTheTriggerHistory(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSample.ts new file mode 100644 index 000000000000..aca17ef14bd7 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a workflow trigger. + * + * @summary Gets a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Get.json + */ +async function getAWorkflowTrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "manual"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.get( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSchemaJsonSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSchemaJsonSample.ts new file mode 100644 index 000000000000..c56bfb67bd17 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersGetSchemaJsonSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get the trigger schema as JSON. + * + * @summary Get the trigger schema as JSON. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_GetSchemaJson.json + */ +async function getTriggerSchema() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflow"; + const triggerName = "testTrigger"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.getSchemaJson( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getTriggerSchema(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListCallbackUrlSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListCallbackUrlSample.ts new file mode 100644 index 000000000000..75b70b3c0906 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListCallbackUrlSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Get the callback URL for a workflow trigger. + * + * @summary Get the callback URL for a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_ListCallbackUrl.json + */ +async function getTheCallbackUrlForATrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "manual"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.listCallbackUrl( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + getTheCallbackUrlForATrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListSample.ts new file mode 100644 index 000000000000..1fedaa176b9d --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersListSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a list of workflow triggers. + * + * @summary Gets a list of workflow triggers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_List.json + */ +async function listWorkflowTriggers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowTriggers.list( + resourceGroupName, + name, + workflowName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listWorkflowTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersRunSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersRunSample.ts new file mode 100644 index 000000000000..3b0794be75d2 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowTriggersRunSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Runs a workflow trigger. + * + * @summary Runs a workflow trigger. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowTriggers_Run.json + */ +async function runAWorkflowTrigger() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const triggerName = "recurrence"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowTriggers.beginRunAndWait( + resourceGroupName, + name, + workflowName, + triggerName + ); + console.log(result); +} + +async function main() { + runAWorkflowTrigger(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsGetSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsGetSample.ts new file mode 100644 index 000000000000..f0b0513f6bec --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsGetSample.ts @@ -0,0 +1,47 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a workflow version. + * + * @summary Gets a workflow version. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_Get.json + */ +async function getAWorkflowVersion() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const versionId = "08586676824806722526"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflowVersions.get( + resourceGroupName, + name, + workflowName, + versionId + ); + console.log(result); +} + +async function main() { + getAWorkflowVersion(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsListSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsListSample.ts new file mode 100644 index 000000000000..9c470ab2260b --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowVersionsListSample.ts @@ -0,0 +1,48 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { WebSiteManagementClient } from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Gets a list of workflow versions. + * + * @summary Gets a list of workflow versions. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/WorkflowVersions_List.json + */ +async function listAWorkflowsVersions() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; + const name = "test-name"; + const workflowName = "test-workflow"; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const resArray = new Array(); + for await (let item of client.workflowVersions.list( + resourceGroupName, + name, + workflowName + )) { + resArray.push(item); + } + console.log(resArray); +} + +async function main() { + listAWorkflowsVersions(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsRegenerateAccessKeySample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsRegenerateAccessKeySample.ts new file mode 100644 index 000000000000..8148cfcc98c4 --- /dev/null +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsRegenerateAccessKeySample.ts @@ -0,0 +1,50 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { + RegenerateActionParameter, + WebSiteManagementClient +} from "@azure/arm-appservice"; +import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); + +/** + * This sample demonstrates how to Regenerates the callback URL access key for request triggers. + * + * @summary Regenerates the callback URL access key for request triggers. + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_RegenerateAccessKey.json + */ +async function regenerateTheCallbackUrlAccessKeyForRequestTriggers() { + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "testResourceGroup"; + const name = "test-name"; + const workflowName = "testWorkflowName"; + const keyType: RegenerateActionParameter = { keyType: "Primary" }; + const credential = new DefaultAzureCredential(); + const client = new WebSiteManagementClient(credential, subscriptionId); + const result = await client.workflows.regenerateAccessKey( + resourceGroupName, + name, + workflowName, + keyType + ); + console.log(result); +} + +async function main() { + regenerateTheCallbackUrlAccessKeyForRequestTriggers(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsValidateSample.ts b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsValidateSample.ts similarity index 76% rename from sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsValidateSample.ts rename to sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsValidateSample.ts index f9ba1418ff65..2d583747d680 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/src/workflowsValidateSample.ts +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/src/workflowsValidateSample.ts @@ -10,16 +10,22 @@ // Licensed under the MIT License. import { Workflow, WebSiteManagementClient } from "@azure/arm-appservice"; import { DefaultAzureCredential } from "@azure/identity"; +import * as dotenv from "dotenv"; + +dotenv.config(); /** * This sample demonstrates how to Validates the workflow definition. * * @summary Validates the workflow definition. - * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-03-01/examples/Workflows_Validate.json + * x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2022-09-01/examples/Workflows_Validate.json */ async function validateAWorkflow() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "test-resource-group"; + const subscriptionId = + process.env["APPSERVICE_SUBSCRIPTION_ID"] || + "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; + const resourceGroupName = + process.env["APPSERVICE_RESOURCE_GROUP"] || "test-resource-group"; const name = "test-name"; const workflowName = "test-workflow"; const validate: Workflow = { @@ -45,4 +51,8 @@ async function validateAWorkflow() { console.log(result); } -validateAWorkflow().catch(console.error); +async function main() { + validateAWorkflow(); +} + +main().catch(console.error); diff --git a/sdk/appservice/arm-appservice/samples/v13/typescript/tsconfig.json b/sdk/appservice/arm-appservice/samples/v14/typescript/tsconfig.json similarity index 92% rename from sdk/appservice/arm-appservice/samples/v13/typescript/tsconfig.json rename to sdk/appservice/arm-appservice/samples/v14/typescript/tsconfig.json index 416c2dd82e00..e26ce2a6d8f7 100644 --- a/sdk/appservice/arm-appservice/samples/v13/typescript/tsconfig.json +++ b/sdk/appservice/arm-appservice/samples/v14/typescript/tsconfig.json @@ -1,6 +1,6 @@ { "compilerOptions": { - "target": "ES2018", + "target": "ES2020", "module": "commonjs", "moduleResolution": "node", "resolveJsonModule": true, diff --git a/sdk/appservice/arm-appservice/src/lroImpl.ts b/sdk/appservice/arm-appservice/src/lroImpl.ts index 518d5f053b4e..dd803cd5e28c 100644 --- a/sdk/appservice/arm-appservice/src/lroImpl.ts +++ b/sdk/appservice/arm-appservice/src/lroImpl.ts @@ -6,29 +6,37 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT license. + +import { AbortSignalLike } from "@azure/abort-controller"; import { LongRunningOperation, LroResponse } from "@azure/core-lro"; -export class LroImpl implements LongRunningOperation { - constructor( - private sendOperationFn: (args: any, spec: any) => Promise>, - private args: Record, - private spec: { - readonly requestBody?: unknown; - readonly path?: string; - readonly httpMethod: string; - } & Record, - public requestPath: string = spec.path!, - public requestMethod: string = spec.httpMethod - ) {} - public async sendInitialRequest(): Promise> { - return this.sendOperationFn(this.args, this.spec); - } - public async sendPollRequest(path: string): Promise> { - const { requestBody, ...restSpec } = this.spec; - return this.sendOperationFn(this.args, { - ...restSpec, - path, - httpMethod: "GET" - }); - } +export function createLroSpec(inputs: { + sendOperationFn: (args: any, spec: any) => Promise>; + args: Record; + spec: { + readonly requestBody?: unknown; + readonly path?: string; + readonly httpMethod: string; + } & Record; +}): LongRunningOperation { + const { args, spec, sendOperationFn } = inputs; + return { + requestMethod: spec.httpMethod, + requestPath: spec.path!, + sendInitialRequest: () => sendOperationFn(args, spec), + sendPollRequest: ( + path: string, + options?: { abortSignal?: AbortSignalLike } + ) => { + const { requestBody, ...restSpec } = spec; + return sendOperationFn(args, { + ...restSpec, + httpMethod: "GET", + path, + abortSignal: options?.abortSignal + }); + } + }; } diff --git a/sdk/appservice/arm-appservice/src/models/index.ts b/sdk/appservice/arm-appservice/src/models/index.ts index a12800647ffd..adcd0f6702fd 100644 --- a/sdk/appservice/arm-appservice/src/models/index.ts +++ b/sdk/appservice/arm-appservice/src/models/index.ts @@ -904,6 +904,8 @@ export interface SiteConfig { publishingUsername?: string; /** Application settings. */ appSettings?: NameValuePair[]; + /** Application metadata. This property cannot be retrieved, since it may contain secrets. */ + metadata?: NameValuePair[]; /** Connection strings. */ connectionStrings?: ConnStringInfo[]; /** @@ -973,8 +975,12 @@ export interface SiteConfig { keyVaultReferenceIdentity?: string; /** IP security restrictions for main. */ ipSecurityRestrictions?: IpSecurityRestriction[]; + /** Default action for main access restriction if no rules are matched. */ + ipSecurityRestrictionsDefaultAction?: DefaultAction; /** IP security restrictions for scm. */ scmIpSecurityRestrictions?: IpSecurityRestriction[]; + /** Default action for scm access restriction if no rules are matched. */ + scmIpSecurityRestrictionsDefaultAction?: DefaultAction; /** IP security restrictions for scm to use main. */ scmIpSecurityRestrictionsUseMain?: boolean; /** Http20Enabled: configures a web site to allow clients to connect over http2.0 */ @@ -995,6 +1001,11 @@ export interface SiteConfig { * This setting only applies to the Consumption and Elastic Premium Plans */ functionAppScaleLimit?: number; + /** + * Maximum number of workers that a site can scale out to. + * This setting only applies to apps in plans where ElasticScaleEnabled is true + */ + elasticWebAppScaleLimit?: number; /** Health check path */ healthCheckPath?: string; /** @@ -3106,6 +3117,54 @@ export interface StaticSiteLinkedBackend { readonly provisioningState?: string; } +/** Static Site Database Connection overview. */ +export interface DatabaseConnectionOverview { + /** + * The resource id of the database. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly resourceId?: string; + /** + * If present, the identity is used in conjunction with connection string to connect to the database. Use of the system-assigned managed identity is indicated with the string 'SystemAssigned', while use of a user-assigned managed identity is indicated with the resource id of the managed identity resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly connectionIdentity?: string; + /** + * The region of the database resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly region?: string; + /** + * A list of configuration files associated with this database connection. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly configurationFiles?: StaticSiteDatabaseConnectionConfigurationFileOverview[]; + /** + * If present, the name of this database connection resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; +} + +/** A database connection configuration file */ +export interface StaticSiteDatabaseConnectionConfigurationFileOverview { + /** + * The name of the configuration file. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly fileName?: string; + /** + * The Base64 encoding of the file contents. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly contents?: string; + /** + * The type of configuration file. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; +} + /** Collection of static site custom users. */ export interface StaticSiteUserCollection { /** Collection of resources. */ @@ -3128,6 +3187,29 @@ export interface StaticSiteBuildCollection { readonly nextLink?: string; } +/** Collection of static site database connections. */ +export interface DatabaseConnectionCollection { + /** Collection of resources. */ + value: DatabaseConnection[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Static Site Database Connection Request Properties resource when patching */ +export interface DatabaseConnectionPatchRequest { + /** The resource id of the database. */ + resourceId?: string; + /** If present, the identity is used in conjunction with connection string to connect to the database. Use of the system-assigned managed identity is indicated with the string 'SystemAssigned', while use of a user-assigned managed identity is indicated with the resource id of the managed identity resource. */ + connectionIdentity?: string; + /** The connection string to use to connect to the database. */ + connectionString?: string; + /** The region of the database resource. */ + region?: string; +} + /** Collection of static site functions. */ export interface StaticSiteFunctionOverviewCollection { /** Collection of resources. */ @@ -3150,6 +3232,17 @@ export interface StaticSiteUserProvidedFunctionAppsCollection { readonly nextLink?: string; } +/** Collection of static site basic auth. */ +export interface StaticSiteBasicAuthPropertiesCollection { + /** Collection of resources. */ + value: StaticSiteBasicAuthPropertiesARMResource[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + /** Collection of static site custom domains. */ export interface StaticSiteCustomDomainOverviewCollection { /** Collection of resources. */ @@ -4243,6 +4336,70 @@ export interface WebJobCollection { readonly nextLink?: string; } +/** The workflow filter. */ +export interface WorkflowArtifacts { + /** Application settings of the workflow. */ + appSettings?: Record; + /** Files of the app. */ + files?: { [propertyName: string]: Record }; + /** Files of the app to delete. */ + filesToDelete?: string[]; +} + +/** Collection of Kudu workflow information elements. */ +export interface WorkflowEnvelopeCollection { + /** Collection of resources. */ + value: WorkflowEnvelope[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Workflow properties definition. */ +export interface WorkflowEnvelope { + /** + * The resource id. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; + /** + * Gets the resource name. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * Gets the resource type. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** The resource kind. */ + kind?: string; + /** The resource location. */ + location?: string; + /** Additional workflow properties. */ + properties?: WorkflowEnvelopeProperties; +} + +/** Additional workflow properties. */ +export interface WorkflowEnvelopeProperties { + /** Gets or sets the files. */ + files?: { [propertyName: string]: Record }; + /** Gets or sets the state of the workflow. */ + flowState?: WorkflowState; + /** Gets or sets workflow health. */ + health?: WorkflowHealth; +} + +/** Represents the workflow health. */ +export interface WorkflowHealth { + /** Gets or sets the workflow health state. */ + state: WorkflowHealthState; + /** Gets or sets the workflow error. */ + error?: ErrorEntity; +} + /** The access key regenerate action content. */ export interface RegenerateActionParameter { /** The key type. */ @@ -5221,6 +5378,8 @@ export interface Site extends Resource { * This must be of the form /subscriptions/{subscriptionName}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName} */ virtualNetworkSubnetId?: string; + /** Azure Resource Manager ID of the customer's selected Managed Environment on which to host this app. This must be of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName} */ + managedEnvironmentId?: string; } /** App Service plan. */ @@ -5572,6 +5731,11 @@ export interface StaticSiteARMResource extends Resource { enterpriseGradeCdnStatus?: EnterpriseGradeCdnStatus; /** State indicating whether public traffic are allowed or not for a static web app. Allowed Values: 'Enabled', 'Disabled' or an empty string. */ publicNetworkAccess?: string; + /** + * Database connections for the static site + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly databaseConnections?: DatabaseConnectionOverview[]; } /** Premier add-on. */ @@ -6901,6 +7065,11 @@ export interface StaticSitePatchResource extends ProxyOnlyResource { enterpriseGradeCdnStatus?: EnterpriseGradeCdnStatus; /** State indicating whether public traffic are allowed or not for a static web app. Allowed Values: 'Enabled', 'Disabled' or an empty string. */ publicNetworkAccess?: string; + /** + * Database connections for the static site + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly databaseConnections?: DatabaseConnectionOverview[]; } /** Static Site User ARM resource. */ @@ -6971,6 +7140,11 @@ export interface StaticSiteBuildARMResource extends ProxyOnlyResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly linkedBackends?: StaticSiteLinkedBackend[]; + /** + * Database connections for the static site build + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly databaseConnections?: DatabaseConnectionOverview[]; } /** String dictionary resource. */ @@ -6979,6 +7153,23 @@ export interface StringDictionary extends ProxyOnlyResource { properties?: { [propertyName: string]: string }; } +/** Static Site Database Connection resource. */ +export interface DatabaseConnection extends ProxyOnlyResource { + /** The resource id of the database. */ + resourceId?: string; + /** If present, the identity is used in conjunction with connection string to connect to the database. Use of the system-assigned managed identity is indicated with the string 'SystemAssigned', while use of a user-assigned managed identity is indicated with the resource id of the managed identity resource. */ + connectionIdentity?: string; + /** The connection string to use to connect to the database. */ + connectionString?: string; + /** The region of the database resource. */ + region?: string; + /** + * A list of configuration files associated with this database connection. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly configurationFiles?: StaticSiteDatabaseConnectionConfigurationFileOverview[]; +} + /** Static Site Function Overview ARM resource. */ export interface StaticSiteFunctionOverviewARMResource extends ProxyOnlyResource { @@ -7022,6 +7213,24 @@ export interface StaticSiteZipDeploymentARMResource extends ProxyOnlyResource { functionLanguage?: string; } +/** Static site basic auth properties ARM resource. */ +export interface StaticSiteBasicAuthPropertiesARMResource + extends ProxyOnlyResource { + /** The password for basic auth. */ + password?: string; + /** Url to the secret in Key Vault. */ + secretUrl?: string; + /** State indicating if basic auth is enabled and for what environments it is active. */ + applicableEnvironmentsMode?: string; + /** The list of enabled environments for Basic Auth if ApplicableEnvironmentsMode is set to SpecifiedEnvironments. */ + environments?: string[]; + /** + * State indicating if basic auth has a secret and what type it is. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly secretState?: string; +} + /** Static sites user roles invitation resource. */ export interface StaticSiteUserInvitationRequestResource extends ProxyOnlyResource { @@ -7487,6 +7696,8 @@ export interface SiteConfigResource extends ProxyOnlyResource { publishingUsername?: string; /** Application settings. */ appSettings?: NameValuePair[]; + /** Application metadata. This property cannot be retrieved, since it may contain secrets. */ + metadata?: NameValuePair[]; /** Connection strings. */ connectionStrings?: ConnStringInfo[]; /** @@ -7556,8 +7767,12 @@ export interface SiteConfigResource extends ProxyOnlyResource { keyVaultReferenceIdentity?: string; /** IP security restrictions for main. */ ipSecurityRestrictions?: IpSecurityRestriction[]; + /** Default action for main access restriction if no rules are matched. */ + ipSecurityRestrictionsDefaultAction?: DefaultAction; /** IP security restrictions for scm. */ scmIpSecurityRestrictions?: IpSecurityRestriction[]; + /** Default action for scm access restriction if no rules are matched. */ + scmIpSecurityRestrictionsDefaultAction?: DefaultAction; /** IP security restrictions for scm to use main. */ scmIpSecurityRestrictionsUseMain?: boolean; /** Http20Enabled: configures a web site to allow clients to connect over http2.0 */ @@ -7578,6 +7793,11 @@ export interface SiteConfigResource extends ProxyOnlyResource { * This setting only applies to the Consumption and Elastic Premium Plans */ functionAppScaleLimit?: number; + /** + * Maximum number of workers that a site can scale out to. + * This setting only applies to apps in plans where ElasticScaleEnabled is true + */ + elasticWebAppScaleLimit?: number; /** Health check path */ healthCheckPath?: string; /** @@ -7663,7 +7883,7 @@ export interface SiteAuthSettings extends ProxyOnlyResource { /** Gets a value indicating whether the issuer should be a valid HTTPS url and be validated as such. */ validateIssuer?: boolean; /** - * Allowed audience values to consider when validating JWTs issued by + * Allowed audience values to consider when validating JSON Web Tokens issued by * Azure Active Directory. Note that the ClientID value is always considered an * allowed audience, regardless of this setting. */ @@ -9027,6 +9247,12 @@ export interface WorkflowRunActionRepetitionProperties extends OperationResult { repetitionIndexes?: RepetitionIndex[]; } +/** Defines headers for AppServiceEnvironments_createOrUpdate operation. */ +export interface AppServiceEnvironmentsCreateOrUpdateHeaders { + /** Location header for asynchronous response. */ + location?: string; +} + /** Known values of {@link ResourceNotRenewableReason} that the service accepts. */ export enum KnownResourceNotRenewableReason { /** RegistrationStatusNotSupportedForRenewal */ @@ -9189,6 +9415,24 @@ export enum KnownIpFilterTag { */ export type IpFilterTag = string; +/** Known values of {@link DefaultAction} that the service accepts. */ +export enum KnownDefaultAction { + /** Allow */ + Allow = "Allow", + /** Deny */ + Deny = "Deny" +} + +/** + * Defines values for DefaultAction. \ + * {@link KnownDefaultAction} can be used interchangeably with DefaultAction, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Allow** \ + * **Deny** + */ +export type DefaultAction = string; + /** Known values of {@link SupportedTlsVersions} that the service accepts. */ export enum KnownSupportedTlsVersions { /** One0 */ @@ -9363,8 +9607,8 @@ export enum KnownRevisionProvisioningState { */ export type RevisionProvisioningState = string; -/** Known values of {@link Enum14} that the service accepts. */ -export enum KnownEnum14 { +/** Known values of {@link ProviderOsTypeSelected} that the service accepts. */ +export enum KnownProviderOsTypeSelected { /** Windows */ Windows = "Windows", /** Linux */ @@ -9378,8 +9622,8 @@ export enum KnownEnum14 { } /** - * Defines values for Enum14. \ - * {@link KnownEnum14} can be used interchangeably with Enum14, + * Defines values for ProviderOsTypeSelected. \ + * {@link KnownProviderOsTypeSelected} can be used interchangeably with ProviderOsTypeSelected, * this enum contains the known values that the service supports. * ### Known values supported by the service * **Windows** \ @@ -9388,10 +9632,10 @@ export enum KnownEnum14 { * **LinuxFunctions** \ * **All** */ -export type Enum14 = string; +export type ProviderOsTypeSelected = string; -/** Known values of {@link Enum15} that the service accepts. */ -export enum KnownEnum15 { +/** Known values of {@link ProviderStackOsType} that the service accepts. */ +export enum KnownProviderStackOsType { /** Windows */ Windows = "Windows", /** Linux */ @@ -9401,105 +9645,15 @@ export enum KnownEnum15 { } /** - * Defines values for Enum15. \ - * {@link KnownEnum15} can be used interchangeably with Enum15, + * Defines values for ProviderStackOsType. \ + * {@link KnownProviderStackOsType} can be used interchangeably with ProviderStackOsType, * this enum contains the known values that the service supports. * ### Known values supported by the service * **Windows** \ * **Linux** \ * **All** */ -export type Enum15 = string; - -/** Known values of {@link Enum16} that the service accepts. */ -export enum KnownEnum16 { - /** Windows */ - Windows = "Windows", - /** Linux */ - Linux = "Linux", - /** All */ - All = "All" -} - -/** - * Defines values for Enum16. \ - * {@link KnownEnum16} can be used interchangeably with Enum16, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Windows** \ - * **Linux** \ - * **All** - */ -export type Enum16 = string; - -/** Known values of {@link Enum17} that the service accepts. */ -export enum KnownEnum17 { - /** Windows */ - Windows = "Windows", - /** Linux */ - Linux = "Linux", - /** All */ - All = "All" -} - -/** - * Defines values for Enum17. \ - * {@link KnownEnum17} can be used interchangeably with Enum17, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Windows** \ - * **Linux** \ - * **All** - */ -export type Enum17 = string; - -/** Known values of {@link Enum18} that the service accepts. */ -export enum KnownEnum18 { - /** Windows */ - Windows = "Windows", - /** Linux */ - Linux = "Linux", - /** All */ - All = "All" -} - -/** - * Defines values for Enum18. \ - * {@link KnownEnum18} can be used interchangeably with Enum18, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Windows** \ - * **Linux** \ - * **All** - */ -export type Enum18 = string; - -/** Known values of {@link Enum19} that the service accepts. */ -export enum KnownEnum19 { - /** Windows */ - Windows = "Windows", - /** Linux */ - Linux = "Linux", - /** WindowsFunctions */ - WindowsFunctions = "WindowsFunctions", - /** LinuxFunctions */ - LinuxFunctions = "LinuxFunctions", - /** All */ - All = "All" -} - -/** - * Defines values for Enum19. \ - * {@link KnownEnum19} can be used interchangeably with Enum19, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Windows** \ - * **Linux** \ - * **WindowsFunctions** \ - * **LinuxFunctions** \ - * **All** - */ -export type Enum19 = string; +export type ProviderStackOsType = string; /** Known values of {@link ResourceScopeType} that the service accepts. */ export enum KnownResourceScopeType { @@ -9723,6 +9877,21 @@ export enum KnownTriggerTypes { */ export type TriggerTypes = string; +/** Known values of {@link BasicAuthName} that the service accepts. */ +export enum KnownBasicAuthName { + /** Default */ + Default = "default" +} + +/** + * Defines values for BasicAuthName. \ + * {@link KnownBasicAuthName} can be used interchangeably with BasicAuthName, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **default** + */ +export type BasicAuthName = string; + /** Known values of {@link CustomDomainStatus} that the service accepts. */ export enum KnownCustomDomainStatus { /** RetrievingValidationToken */ @@ -10029,36 +10198,6 @@ export enum KnownWorkflowTriggerProvisioningState { */ export type WorkflowTriggerProvisioningState = string; -/** Known values of {@link WorkflowState} that the service accepts. */ -export enum KnownWorkflowState { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Completed */ - Completed = "Completed", - /** Enabled */ - Enabled = "Enabled", - /** Disabled */ - Disabled = "Disabled", - /** Deleted */ - Deleted = "Deleted", - /** Suspended */ - Suspended = "Suspended" -} - -/** - * Defines values for WorkflowState. \ - * {@link KnownWorkflowState} can be used interchangeably with WorkflowState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Completed** \ - * **Enabled** \ - * **Disabled** \ - * **Deleted** \ - * **Suspended** - */ -export type WorkflowState = string; - /** Known values of {@link RecurrenceFrequency} that the service accepts. */ export enum KnownRecurrenceFrequency { /** NotSpecified */ @@ -10604,6 +10743,20 @@ export type PublicCertificateLocation = export type SiteExtensionType = "Gallery" | "WebRoot"; /** Defines values for TriggeredWebJobStatus. */ export type TriggeredWebJobStatus = "Success" | "Failed" | "Error"; +/** Defines values for WorkflowState. */ +export type WorkflowState = + | "NotSpecified" + | "Completed" + | "Enabled" + | "Disabled" + | "Deleted" + | "Suspended"; +/** Defines values for WorkflowHealthState. */ +export type WorkflowHealthState = + | "NotSpecified" + | "Healthy" + | "Unhealthy" + | "Unknown"; /** Defines values for DaysOfWeek. */ export type DaysOfWeek = | "Sunday" @@ -11487,10 +11640,7 @@ export type AppServiceEnvironmentsListAppServicePlansNextResponse = AppServicePl /** Optional parameters. */ export interface AppServiceEnvironmentsListWebAppsNextOptionalParams - extends coreClient.OperationOptions { - /** Comma separated list of app properties to include. */ - propertiesToInclude?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listWebAppsNext operation. */ export type AppServiceEnvironmentsListWebAppsNextResponse = WebAppCollection; @@ -11504,10 +11654,7 @@ export type AppServiceEnvironmentsSuspendNextResponse = WebAppCollection; /** Optional parameters. */ export interface AppServiceEnvironmentsListUsagesNextOptionalParams - extends coreClient.OperationOptions { - /** Return only usages/metrics specified in the filter. Filter conforms to odata syntax. Example: $filter=(name.value eq 'Metric1' or name.value eq 'Metric2') and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[Hour|Minute|Day]'. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listUsagesNext operation. */ export type AppServiceEnvironmentsListUsagesNextResponse = CsmUsageQuotaCollection; @@ -11747,13 +11894,7 @@ export interface AppServicePlansRebootWorkerOptionalParams /** Optional parameters. */ export interface AppServicePlansListNextOptionalParams - extends coreClient.OperationOptions { - /** - * Specify true to return all App Service plan properties. The default is false, which returns a subset of the properties. - * Retrieval of all properties may increase the API latency. - */ - detailed?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type AppServicePlansListNextResponse = AppServicePlanCollection; @@ -11781,24 +11922,14 @@ export type AppServicePlansListHybridConnectionsNextResponse = HybridConnectionC /** Optional parameters. */ export interface AppServicePlansListWebAppsNextOptionalParams - extends coreClient.OperationOptions { - /** Supported filter: $filter=state eq running. Returns only web apps that are currently running */ - filter?: string; - /** Skip to a web app in the list of webapps associated with app service plan. If specified, the resulting list will contain web apps starting from (including) the skipToken. Otherwise, the resulting list contains web apps from the start of the list */ - skipToken?: string; - /** List page size. If specified, results are paged. */ - top?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listWebAppsNext operation. */ export type AppServicePlansListWebAppsNextResponse = WebAppCollection; /** Optional parameters. */ export interface AppServicePlansListUsagesNextOptionalParams - extends coreClient.OperationOptions { - /** Return only usages/metrics specified in the filter. Filter conforms to odata syntax. Example: $filter=(name.value eq 'Metric1' or name.value eq 'Metric2'). */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listUsagesNext operation. */ export type AppServicePlansListUsagesNextResponse = CsmUsageQuotaCollection; @@ -11847,10 +11978,7 @@ export type CertificatesUpdateResponse = Certificate; /** Optional parameters. */ export interface CertificatesListNextOptionalParams - extends coreClient.OperationOptions { - /** Return only information specified in the filter (using OData syntax). For example: $filter=KeyVaultId eq 'KeyVaultId' */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type CertificatesListNextResponse = CertificateCollection; @@ -12343,7 +12471,7 @@ export type KubeEnvironmentsListByResourceGroupNextResponse = KubeEnvironmentCol /** Optional parameters. */ export interface ProviderGetAvailableStacksOptionalParams extends coreClient.OperationOptions { - osTypeSelected?: Enum14; + osTypeSelected?: ProviderOsTypeSelected; } /** Contains response data for the getAvailableStacks operation. */ @@ -12353,7 +12481,7 @@ export type ProviderGetAvailableStacksResponse = ApplicationStackCollection; export interface ProviderGetFunctionAppStacksOptionalParams extends coreClient.OperationOptions { /** Stack OS Type */ - stackOsType?: Enum15; + stackOsType?: ProviderStackOsType; } /** Contains response data for the getFunctionAppStacks operation. */ @@ -12363,7 +12491,7 @@ export type ProviderGetFunctionAppStacksResponse = FunctionAppStackCollection; export interface ProviderGetFunctionAppStacksForLocationOptionalParams extends coreClient.OperationOptions { /** Stack OS Type */ - stackOsType?: Enum16; + stackOsType?: ProviderStackOsType; } /** Contains response data for the getFunctionAppStacksForLocation operation. */ @@ -12373,7 +12501,7 @@ export type ProviderGetFunctionAppStacksForLocationResponse = FunctionAppStackCo export interface ProviderGetWebAppStacksForLocationOptionalParams extends coreClient.OperationOptions { /** Stack OS Type */ - stackOsType?: Enum17; + stackOsType?: ProviderStackOsType; } /** Contains response data for the getWebAppStacksForLocation operation. */ @@ -12390,7 +12518,7 @@ export type ProviderListOperationsResponse = CsmOperationCollection; export interface ProviderGetWebAppStacksOptionalParams extends coreClient.OperationOptions { /** Stack OS Type */ - stackOsType?: Enum18; + stackOsType?: ProviderStackOsType; } /** Contains response data for the getWebAppStacks operation. */ @@ -12399,7 +12527,7 @@ export type ProviderGetWebAppStacksResponse = WebAppStackCollection; /** Optional parameters. */ export interface ProviderGetAvailableStacksOnPremOptionalParams extends coreClient.OperationOptions { - osTypeSelected?: Enum19; + osTypeSelected?: ProviderOsTypeSelected; } /** Contains response data for the getAvailableStacksOnPrem operation. */ @@ -12407,39 +12535,28 @@ export type ProviderGetAvailableStacksOnPremResponse = ApplicationStackCollectio /** Optional parameters. */ export interface ProviderGetAvailableStacksNextOptionalParams - extends coreClient.OperationOptions { - osTypeSelected?: Enum14; -} + extends coreClient.OperationOptions {} /** Contains response data for the getAvailableStacksNext operation. */ export type ProviderGetAvailableStacksNextResponse = ApplicationStackCollection; /** Optional parameters. */ export interface ProviderGetFunctionAppStacksNextOptionalParams - extends coreClient.OperationOptions { - /** Stack OS Type */ - stackOsType?: Enum15; -} + extends coreClient.OperationOptions {} /** Contains response data for the getFunctionAppStacksNext operation. */ export type ProviderGetFunctionAppStacksNextResponse = FunctionAppStackCollection; /** Optional parameters. */ export interface ProviderGetFunctionAppStacksForLocationNextOptionalParams - extends coreClient.OperationOptions { - /** Stack OS Type */ - stackOsType?: Enum16; -} + extends coreClient.OperationOptions {} /** Contains response data for the getFunctionAppStacksForLocationNext operation. */ export type ProviderGetFunctionAppStacksForLocationNextResponse = FunctionAppStackCollection; /** Optional parameters. */ export interface ProviderGetWebAppStacksForLocationNextOptionalParams - extends coreClient.OperationOptions { - /** Stack OS Type */ - stackOsType?: Enum17; -} + extends coreClient.OperationOptions {} /** Contains response data for the getWebAppStacksForLocationNext operation. */ export type ProviderGetWebAppStacksForLocationNextResponse = WebAppStackCollection; @@ -12453,19 +12570,14 @@ export type ProviderListOperationsNextResponse = CsmOperationCollection; /** Optional parameters. */ export interface ProviderGetWebAppStacksNextOptionalParams - extends coreClient.OperationOptions { - /** Stack OS Type */ - stackOsType?: Enum18; -} + extends coreClient.OperationOptions {} /** Contains response data for the getWebAppStacksNext operation. */ export type ProviderGetWebAppStacksNextResponse = WebAppStackCollection; /** Optional parameters. */ export interface ProviderGetAvailableStacksOnPremNextOptionalParams - extends coreClient.OperationOptions { - osTypeSelected?: Enum19; -} + extends coreClient.OperationOptions {} /** Contains response data for the getAvailableStacksOnPremNext operation. */ export type ProviderGetAvailableStacksOnPremNextResponse = ApplicationStackCollection; @@ -12588,60 +12700,35 @@ export interface RecommendationsDisableRecommendationForSiteOptionalParams /** Optional parameters. */ export interface RecommendationsListNextOptionalParams - extends coreClient.OperationOptions { - /** Filter is specified by using OData syntax. Example: $filter=channel eq 'Api' or channel eq 'Notification' and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[PT1H|PT1M|P1D] */ - filter?: string; - /** Specify true to return only the most critical recommendations. The default is false, which returns all recommendations. */ - featured?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type RecommendationsListNextResponse = RecommendationCollection; /** Optional parameters. */ export interface RecommendationsListHistoryForHostingEnvironmentNextOptionalParams - extends coreClient.OperationOptions { - /** Filter is specified by using OData syntax. Example: $filter=channel eq 'Api' or channel eq 'Notification' and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[PT1H|PT1M|P1D] */ - filter?: string; - /** Specify false to return all recommendations. The default is true, which returns only expired recommendations. */ - expiredOnly?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listHistoryForHostingEnvironmentNext operation. */ export type RecommendationsListHistoryForHostingEnvironmentNextResponse = RecommendationCollection; /** Optional parameters. */ export interface RecommendationsListRecommendedRulesForHostingEnvironmentNextOptionalParams - extends coreClient.OperationOptions { - /** Return only channels specified in the filter. Filter is specified by using OData syntax. Example: $filter=channel eq 'Api' or channel eq 'Notification' */ - filter?: string; - /** Specify true to return only the most critical recommendations. The default is false, which returns all recommendations. */ - featured?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listRecommendedRulesForHostingEnvironmentNext operation. */ export type RecommendationsListRecommendedRulesForHostingEnvironmentNextResponse = RecommendationCollection; /** Optional parameters. */ export interface RecommendationsListHistoryForWebAppNextOptionalParams - extends coreClient.OperationOptions { - /** Filter is specified by using OData syntax. Example: $filter=channel eq 'Api' or channel eq 'Notification' and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[PT1H|PT1M|P1D] */ - filter?: string; - /** Specify false to return all recommendations. The default is true, which returns only expired recommendations. */ - expiredOnly?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listHistoryForWebAppNext operation. */ export type RecommendationsListHistoryForWebAppNextResponse = RecommendationCollection; /** Optional parameters. */ export interface RecommendationsListRecommendedRulesForWebAppNextOptionalParams - extends coreClient.OperationOptions { - /** Return only channels specified in the filter. Filter is specified by using OData syntax. Example: $filter=channel eq 'Api' or channel eq 'Notification' */ - filter?: string; - /** Specify true to return only the most critical recommendations. The default is false, which returns all recommendations. */ - featured?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listRecommendedRulesForWebAppNext operation. */ export type RecommendationsListRecommendedRulesForWebAppNextResponse = RecommendationCollection; @@ -12855,38 +12942,21 @@ export type ListSourceControlsNextResponse = SourceControlCollection; /** Optional parameters. */ export interface ListBillingMetersNextOptionalParams - extends coreClient.OperationOptions { - /** Azure Location of billable resource */ - billingLocation?: string; - /** App Service OS type meters used for */ - osType?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listBillingMetersNext operation. */ export type ListBillingMetersNextResponse = BillingMeterCollection; /** Optional parameters. */ export interface ListCustomHostNameSitesNextOptionalParams - extends coreClient.OperationOptions { - /** Specific hostname */ - hostname?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listCustomHostNameSitesNext operation. */ export type ListCustomHostNameSitesNextResponse = CustomHostnameSitesCollection; /** Optional parameters. */ export interface ListGeoRegionsNextOptionalParams - extends coreClient.OperationOptions { - /** Name of SKU used to filter the regions. */ - sku?: SkuName; - /** Specify true if you want to filter to only regions that support Linux workers. */ - linuxWorkersEnabled?: boolean; - /** Specify true if you want to filter to only regions that support Xenon workers. */ - xenonWorkersEnabled?: boolean; - /** Specify true if you want to filter to only regions that support Linux Consumption Workers. */ - linuxDynamicWorkersEnabled?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listGeoRegionsNext operation. */ export type ListGeoRegionsNextResponse = GeoRegionCollection; @@ -13016,6 +13086,45 @@ export interface StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOpti /** Contains response data for the createOrUpdateStaticSiteBuildFunctionAppSettings operation. */ export type StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse = StringDictionary; +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnections operation. */ +export type StaticSitesGetBuildDatabaseConnectionsResponse = DatabaseConnectionCollection; + +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnection operation. */ +export type StaticSitesGetBuildDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdateBuildDatabaseConnection operation. */ +export type StaticSitesCreateOrUpdateBuildDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesDeleteBuildDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface StaticSitesUpdateBuildDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the updateBuildDatabaseConnection operation. */ +export type StaticSitesUpdateBuildDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnectionWithDetails operation. */ +export type StaticSitesGetBuildDatabaseConnectionWithDetailsResponse = DatabaseConnection; + /** Optional parameters. */ export interface StaticSitesListStaticSiteBuildFunctionsOptionalParams extends coreClient.OperationOptions {} @@ -13037,6 +13146,13 @@ export interface StaticSitesListStaticSiteBuildFunctionAppSettingsOptionalParams /** Contains response data for the listStaticSiteBuildFunctionAppSettings operation. */ export type StaticSitesListStaticSiteBuildFunctionAppSettingsResponse = StringDictionary; +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnectionsWithDetails operation. */ +export type StaticSitesGetBuildDatabaseConnectionsWithDetailsResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams extends coreClient.OperationOptions {} @@ -13085,6 +13201,27 @@ export interface StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams /** Contains response data for the createOrUpdateStaticSiteAppSettings operation. */ export type StaticSitesCreateOrUpdateStaticSiteAppSettingsResponse = StringDictionary; +/** Optional parameters. */ +export interface StaticSitesListBasicAuthOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBasicAuth operation. */ +export type StaticSitesListBasicAuthResponse = StaticSiteBasicAuthPropertiesCollection; + +/** Optional parameters. */ +export interface StaticSitesGetBasicAuthOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBasicAuth operation. */ +export type StaticSitesGetBasicAuthResponse = StaticSiteBasicAuthPropertiesARMResource; + +/** Optional parameters. */ +export interface StaticSitesCreateOrUpdateBasicAuthOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdateBasicAuth operation. */ +export type StaticSitesCreateOrUpdateBasicAuthResponse = StaticSiteBasicAuthPropertiesARMResource; + /** Optional parameters. */ export interface StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsOptionalParams extends coreClient.OperationOptions {} @@ -13143,6 +13280,45 @@ export interface StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalPa resumeFrom?: string; } +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnections operation. */ +export type StaticSitesGetDatabaseConnectionsResponse = DatabaseConnectionCollection; + +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnection operation. */ +export type StaticSitesGetDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdateDatabaseConnection operation. */ +export type StaticSitesCreateOrUpdateDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesDeleteDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface StaticSitesUpdateDatabaseConnectionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the updateDatabaseConnection operation. */ +export type StaticSitesUpdateDatabaseConnectionResponse = DatabaseConnection; + +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionWithDetailsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnectionWithDetails operation. */ +export type StaticSitesGetDatabaseConnectionWithDetailsResponse = DatabaseConnection; + /** Optional parameters. */ export interface StaticSitesDetachStaticSiteOptionalParams extends coreClient.OperationOptions { @@ -13239,6 +13415,13 @@ export type StaticSitesGetPrivateLinkResourcesResponse = PrivateLinkResourcesWra export interface StaticSitesResetStaticSiteApiKeyOptionalParams extends coreClient.OperationOptions {} +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnectionsWithDetails operation. */ +export type StaticSitesGetDatabaseConnectionsWithDetailsResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams extends coreClient.OperationOptions {} @@ -13392,6 +13575,13 @@ export interface StaticSitesGetStaticSiteBuildsNextOptionalParams /** Contains response data for the getStaticSiteBuildsNext operation. */ export type StaticSitesGetStaticSiteBuildsNextResponse = StaticSiteBuildCollection; +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnectionsNext operation. */ +export type StaticSitesGetBuildDatabaseConnectionsNextResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesListStaticSiteBuildFunctionsNextOptionalParams extends coreClient.OperationOptions {} @@ -13399,6 +13589,13 @@ export interface StaticSitesListStaticSiteBuildFunctionsNextOptionalParams /** Contains response data for the listStaticSiteBuildFunctionsNext operation. */ export type StaticSitesListStaticSiteBuildFunctionsNextResponse = StaticSiteFunctionOverviewCollection; +/** Optional parameters. */ +export interface StaticSitesGetBuildDatabaseConnectionsWithDetailsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuildDatabaseConnectionsWithDetailsNext operation. */ +export type StaticSitesGetBuildDatabaseConnectionsWithDetailsNextResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildNextOptionalParams extends coreClient.OperationOptions {} @@ -13406,6 +13603,13 @@ export interface StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildNextOpt /** Contains response data for the getUserProvidedFunctionAppsForStaticSiteBuildNext operation. */ export type StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildNextResponse = StaticSiteUserProvidedFunctionAppsCollection; +/** Optional parameters. */ +export interface StaticSitesListBasicAuthNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBasicAuthNext operation. */ +export type StaticSitesListBasicAuthNextResponse = StaticSiteBasicAuthPropertiesCollection; + /** Optional parameters. */ export interface StaticSitesListStaticSiteCustomDomainsNextOptionalParams extends coreClient.OperationOptions {} @@ -13413,6 +13617,13 @@ export interface StaticSitesListStaticSiteCustomDomainsNextOptionalParams /** Contains response data for the listStaticSiteCustomDomainsNext operation. */ export type StaticSitesListStaticSiteCustomDomainsNextResponse = StaticSiteCustomDomainOverviewCollection; +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnectionsNext operation. */ +export type StaticSitesGetDatabaseConnectionsNextResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesListStaticSiteFunctionsNextOptionalParams extends coreClient.OperationOptions {} @@ -13427,6 +13638,13 @@ export interface StaticSitesGetPrivateEndpointConnectionListNextOptionalParams /** Contains response data for the getPrivateEndpointConnectionListNext operation. */ export type StaticSitesGetPrivateEndpointConnectionListNextResponse = PrivateEndpointConnectionCollection; +/** Optional parameters. */ +export interface StaticSitesGetDatabaseConnectionsWithDetailsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDatabaseConnectionsWithDetailsNext operation. */ +export type StaticSitesGetDatabaseConnectionsWithDetailsNextResponse = DatabaseConnectionCollection; + /** Optional parameters. */ export interface StaticSitesGetUserProvidedFunctionAppsForStaticSiteNextOptionalParams extends coreClient.OperationOptions {} @@ -16419,6 +16637,62 @@ export interface WebAppsGetWebJobOptionalParams /** Contains response data for the getWebJob operation. */ export type WebAppsGetWebJobResponse = WebJob; +/** Optional parameters. */ +export interface WebAppsDeployWorkflowArtifactsOptionalParams + extends coreClient.OperationOptions { + /** Application settings and files of the workflow. */ + workflowArtifacts?: WorkflowArtifacts; +} + +/** Optional parameters. */ +export interface WebAppsDeployWorkflowArtifactsSlotOptionalParams + extends coreClient.OperationOptions { + /** Application settings and files of the workflow. */ + workflowArtifacts?: WorkflowArtifacts; +} + +/** Optional parameters. */ +export interface WebAppsListInstanceWorkflowsSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listInstanceWorkflowsSlot operation. */ +export type WebAppsListInstanceWorkflowsSlotResponse = WorkflowEnvelopeCollection; + +/** Optional parameters. */ +export interface WebAppsGetInstanceWorkflowSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getInstanceWorkflowSlot operation. */ +export type WebAppsGetInstanceWorkflowSlotResponse = WorkflowEnvelope; + +/** Optional parameters. */ +export interface WebAppsListWorkflowsConnectionsSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listWorkflowsConnectionsSlot operation. */ +export type WebAppsListWorkflowsConnectionsSlotResponse = WorkflowEnvelope; + +/** Optional parameters. */ +export interface WebAppsListWorkflowsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listWorkflows operation. */ +export type WebAppsListWorkflowsResponse = WorkflowEnvelopeCollection; + +/** Optional parameters. */ +export interface WebAppsGetWorkflowOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getWorkflow operation. */ +export type WebAppsGetWorkflowResponse = WorkflowEnvelope; + +/** Optional parameters. */ +export interface WebAppsListWorkflowsConnectionsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listWorkflowsConnections operation. */ +export type WebAppsListWorkflowsConnectionsResponse = WorkflowEnvelope; + /** Optional parameters. */ export interface WebAppsListNextOptionalParams extends coreClient.OperationOptions {} @@ -16428,10 +16702,7 @@ export type WebAppsListNextResponse = WebAppCollection; /** Optional parameters. */ export interface WebAppsListByResourceGroupNextOptionalParams - extends coreClient.OperationOptions { - /** Specify true to include deployment slots in results. The default is false, which only gives you the production slot of all apps. */ - includeSlots?: boolean; -} + extends coreClient.OperationOptions {} /** Contains response data for the listByResourceGroupNext operation. */ export type WebAppsListByResourceGroupNextResponse = WebAppCollection; @@ -16557,10 +16828,7 @@ export type WebAppsListSiteBackupsNextResponse = BackupItemCollection; /** Optional parameters. */ export interface WebAppsListPerfMonCountersNextOptionalParams - extends coreClient.OperationOptions { - /** Return only usages/metrics specified in the filter. Filter conforms to odata syntax. Example: $filter=(startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[Hour|Minute|Day]'. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listPerfMonCountersNext operation. */ export type WebAppsListPerfMonCountersNextResponse = PerfMonCounterCollection; @@ -16735,10 +17003,7 @@ export type WebAppsListSiteBackupsSlotNextResponse = BackupItemCollection; /** Optional parameters. */ export interface WebAppsListPerfMonCountersSlotNextOptionalParams - extends coreClient.OperationOptions { - /** Return only usages/metrics specified in the filter. Filter conforms to odata syntax. Example: $filter=(startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[Hour|Minute|Day]'. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listPerfMonCountersSlotNext operation. */ export type WebAppsListPerfMonCountersSlotNextResponse = PerfMonCounterCollection; @@ -16822,10 +17087,7 @@ export type WebAppsListTriggeredWebJobHistorySlotNextResponse = TriggeredJobHist /** Optional parameters. */ export interface WebAppsListUsagesSlotNextOptionalParams - extends coreClient.OperationOptions { - /** Return only information specified in the filter (using OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq 'Metric2') and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[Hour|Minute|Day]'. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listUsagesSlotNext operation. */ export type WebAppsListUsagesSlotNextResponse = CsmUsageQuotaCollection; @@ -16874,10 +17136,7 @@ export type WebAppsListTriggeredWebJobHistoryNextResponse = TriggeredJobHistoryC /** Optional parameters. */ export interface WebAppsListUsagesNextOptionalParams - extends coreClient.OperationOptions { - /** Return only information specified in the filter (using OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq 'Metric2') and startTime eq 2014-01-01T00:00:00Z and endTime eq 2014-12-31T23:59:59Z and timeGrain eq duration'[Hour|Minute|Day]'. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listUsagesNext operation. */ export type WebAppsListUsagesNextResponse = CsmUsageQuotaCollection; @@ -16889,6 +17148,20 @@ export interface WebAppsListWebJobsNextOptionalParams /** Contains response data for the listWebJobsNext operation. */ export type WebAppsListWebJobsNextResponse = WebJobCollection; +/** Optional parameters. */ +export interface WebAppsListInstanceWorkflowsSlotNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listInstanceWorkflowsSlotNext operation. */ +export type WebAppsListInstanceWorkflowsSlotNextResponse = WorkflowEnvelopeCollection; + +/** Optional parameters. */ +export interface WebAppsListWorkflowsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listWorkflowsNext operation. */ +export type WebAppsListWorkflowsNextResponse = WorkflowEnvelopeCollection; + /** Optional parameters. */ export interface WorkflowsRegenerateAccessKeyOptionalParams extends coreClient.OperationOptions {} @@ -16922,12 +17195,7 @@ export interface WorkflowRunsCancelOptionalParams /** Optional parameters. */ export interface WorkflowRunsListNextOptionalParams - extends coreClient.OperationOptions { - /** The number of items to be included in the result. */ - top?: number; - /** The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type WorkflowRunsListNextResponse = WorkflowRunListResult; @@ -16960,12 +17228,7 @@ export type WorkflowRunActionsListExpressionTracesResponse = ExpressionTraces; /** Optional parameters. */ export interface WorkflowRunActionsListNextOptionalParams - extends coreClient.OperationOptions { - /** The number of items to be included in the result. */ - top?: number; - /** The filter to apply on the operation. Options for filters include: Status. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type WorkflowRunActionsListNextResponse = WorkflowRunActionListResult; @@ -17098,12 +17361,7 @@ export type WorkflowTriggersGetSchemaJsonResponse = JsonSchema; /** Optional parameters. */ export interface WorkflowTriggersListNextOptionalParams - extends coreClient.OperationOptions { - /** The number of items to be included in the result. */ - top?: number; - /** The filter to apply on the operation. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type WorkflowTriggersListNextResponse = WorkflowTriggerListResult; @@ -17138,12 +17396,7 @@ export interface WorkflowTriggerHistoriesResubmitOptionalParams /** Optional parameters. */ export interface WorkflowTriggerHistoriesListNextOptionalParams - extends coreClient.OperationOptions { - /** The number of items to be included in the result. */ - top?: number; - /** The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type WorkflowTriggerHistoriesListNextResponse = WorkflowTriggerHistoryListResult; @@ -17167,10 +17420,7 @@ export type WorkflowVersionsGetResponse = WorkflowVersion; /** Optional parameters. */ export interface WorkflowVersionsListNextOptionalParams - extends coreClient.OperationOptions { - /** The number of items to be included in the result. */ - top?: number; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type WorkflowVersionsListNextResponse = WorkflowVersionListResult; diff --git a/sdk/appservice/arm-appservice/src/models/mappers.ts b/sdk/appservice/arm-appservice/src/models/mappers.ts index 2b1d396030ea..265a062d9996 100644 --- a/sdk/appservice/arm-appservice/src/models/mappers.ts +++ b/sdk/appservice/arm-appservice/src/models/mappers.ts @@ -2755,6 +2755,20 @@ export const SiteConfig: coreClient.CompositeMapper = { } } }, + metadata: { + serializedName: "metadata", + xmlName: "metadata", + xmlElementName: "NameValuePair", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "NameValuePair" + } + } + } + }, connectionStrings: { serializedName: "connectionStrings", xmlName: "connectionStrings", @@ -3032,6 +3046,13 @@ export const SiteConfig: coreClient.CompositeMapper = { } } }, + ipSecurityRestrictionsDefaultAction: { + serializedName: "ipSecurityRestrictionsDefaultAction", + xmlName: "ipSecurityRestrictionsDefaultAction", + type: { + name: "String" + } + }, scmIpSecurityRestrictions: { serializedName: "scmIpSecurityRestrictions", xmlName: "scmIpSecurityRestrictions", @@ -3046,6 +3067,13 @@ export const SiteConfig: coreClient.CompositeMapper = { } } }, + scmIpSecurityRestrictionsDefaultAction: { + serializedName: "scmIpSecurityRestrictionsDefaultAction", + xmlName: "scmIpSecurityRestrictionsDefaultAction", + type: { + name: "String" + } + }, scmIpSecurityRestrictionsUseMain: { serializedName: "scmIpSecurityRestrictionsUseMain", xmlName: "scmIpSecurityRestrictionsUseMain", @@ -3103,6 +3131,16 @@ export const SiteConfig: coreClient.CompositeMapper = { name: "Number" } }, + elasticWebAppScaleLimit: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "elasticWebAppScaleLimit", + xmlName: "elasticWebAppScaleLimit", + type: { + name: "Number" + } + }, healthCheckPath: { serializedName: "healthCheckPath", xmlName: "healthCheckPath", @@ -9238,6 +9276,97 @@ export const StaticSiteLinkedBackend: coreClient.CompositeMapper = { } }; +export const DatabaseConnectionOverview: coreClient.CompositeMapper = { + serializedName: "DatabaseConnectionOverview", + type: { + name: "Composite", + className: "DatabaseConnectionOverview", + modelProperties: { + resourceId: { + serializedName: "resourceId", + readOnly: true, + xmlName: "resourceId", + type: { + name: "String" + } + }, + connectionIdentity: { + serializedName: "connectionIdentity", + readOnly: true, + xmlName: "connectionIdentity", + type: { + name: "String" + } + }, + region: { + serializedName: "region", + readOnly: true, + xmlName: "region", + type: { + name: "String" + } + }, + configurationFiles: { + serializedName: "configurationFiles", + readOnly: true, + xmlName: "configurationFiles", + xmlElementName: "StaticSiteDatabaseConnectionConfigurationFileOverview", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StaticSiteDatabaseConnectionConfigurationFileOverview" + } + } + } + }, + name: { + serializedName: "name", + readOnly: true, + xmlName: "name", + type: { + name: "String" + } + } + } + } +}; + +export const StaticSiteDatabaseConnectionConfigurationFileOverview: coreClient.CompositeMapper = { + serializedName: "StaticSiteDatabaseConnectionConfigurationFileOverview", + type: { + name: "Composite", + className: "StaticSiteDatabaseConnectionConfigurationFileOverview", + modelProperties: { + fileName: { + serializedName: "fileName", + readOnly: true, + xmlName: "fileName", + type: { + name: "String" + } + }, + contents: { + serializedName: "contents", + readOnly: true, + xmlName: "contents", + type: { + name: "String" + } + }, + type: { + serializedName: "type", + readOnly: true, + xmlName: "type", + type: { + name: "String" + } + } + } + } +}; + export const StaticSiteUserCollection: coreClient.CompositeMapper = { serializedName: "StaticSiteUserCollection", type: { @@ -9304,6 +9433,77 @@ export const StaticSiteBuildCollection: coreClient.CompositeMapper = { } }; +export const DatabaseConnectionCollection: coreClient.CompositeMapper = { + serializedName: "DatabaseConnectionCollection", + type: { + name: "Composite", + className: "DatabaseConnectionCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + xmlName: "value", + xmlElementName: "DatabaseConnection", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DatabaseConnection" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + xmlName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const DatabaseConnectionPatchRequest: coreClient.CompositeMapper = { + serializedName: "DatabaseConnectionPatchRequest", + type: { + name: "Composite", + className: "DatabaseConnectionPatchRequest", + modelProperties: { + resourceId: { + serializedName: "properties.resourceId", + xmlName: "properties.resourceId", + type: { + name: "String" + } + }, + connectionIdentity: { + serializedName: "properties.connectionIdentity", + xmlName: "properties.connectionIdentity", + type: { + name: "String" + } + }, + connectionString: { + serializedName: "properties.connectionString", + xmlName: "properties.connectionString", + type: { + name: "String" + } + }, + region: { + serializedName: "properties.region", + xmlName: "properties.region", + type: { + name: "String" + } + } + } + } +}; + export const StaticSiteFunctionOverviewCollection: coreClient.CompositeMapper = { serializedName: "StaticSiteFunctionOverviewCollection", type: { @@ -9370,6 +9570,39 @@ export const StaticSiteUserProvidedFunctionAppsCollection: coreClient.CompositeM } }; +export const StaticSiteBasicAuthPropertiesCollection: coreClient.CompositeMapper = { + serializedName: "StaticSiteBasicAuthPropertiesCollection", + type: { + name: "Composite", + className: "StaticSiteBasicAuthPropertiesCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + xmlName: "value", + xmlElementName: "StaticSiteBasicAuthPropertiesARMResource", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StaticSiteBasicAuthPropertiesARMResource" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + xmlName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + export const StaticSiteCustomDomainOverviewCollection: coreClient.CompositeMapper = { serializedName: "StaticSiteCustomDomainOverviewCollection", type: { @@ -12685,84 +12918,284 @@ export const TriggeredJobRun: coreClient.CompositeMapper = { name: "String" } }, - jobName: { - serializedName: "job_name", - xmlName: "job_name", + jobName: { + serializedName: "job_name", + xmlName: "job_name", + type: { + name: "String" + } + }, + trigger: { + serializedName: "trigger", + xmlName: "trigger", + type: { + name: "String" + } + } + } + } +}; + +export const TriggeredJobHistoryCollection: coreClient.CompositeMapper = { + serializedName: "TriggeredJobHistoryCollection", + type: { + name: "Composite", + className: "TriggeredJobHistoryCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + xmlName: "value", + xmlElementName: "TriggeredJobHistory", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "TriggeredJobHistory" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + xmlName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const WebJobCollection: coreClient.CompositeMapper = { + serializedName: "WebJobCollection", + type: { + name: "Composite", + className: "WebJobCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + xmlName: "value", + xmlElementName: "WebJob", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WebJob" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + xmlName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const WorkflowArtifacts: coreClient.CompositeMapper = { + serializedName: "WorkflowArtifacts", + type: { + name: "Composite", + className: "WorkflowArtifacts", + modelProperties: { + appSettings: { + serializedName: "appSettings", + xmlName: "appSettings", + type: { + name: "Dictionary", + value: { type: { name: "any" } } + } + }, + files: { + serializedName: "files", + xmlName: "files", + type: { + name: "Dictionary", + value: { + type: { name: "Dictionary", value: { type: { name: "any" } } } + } + } + }, + filesToDelete: { + serializedName: "filesToDelete", + xmlName: "filesToDelete", + xmlElementName: "WorkflowArtifactsFilesToDeleteItem", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const WorkflowEnvelopeCollection: coreClient.CompositeMapper = { + serializedName: "WorkflowEnvelopeCollection", + type: { + name: "Composite", + className: "WorkflowEnvelopeCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + xmlName: "value", + xmlElementName: "WorkflowEnvelope", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WorkflowEnvelope" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + xmlName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const WorkflowEnvelope: coreClient.CompositeMapper = { + serializedName: "WorkflowEnvelope", + type: { + name: "Composite", + className: "WorkflowEnvelope", + modelProperties: { + id: { + serializedName: "id", + readOnly: true, + xmlName: "id", + type: { + name: "String" + } + }, + name: { + serializedName: "name", + readOnly: true, + xmlName: "name", + type: { + name: "String" + } + }, + type: { + serializedName: "type", + readOnly: true, + xmlName: "type", + type: { + name: "String" + } + }, + kind: { + serializedName: "kind", + xmlName: "kind", + type: { + name: "String" + } + }, + location: { + serializedName: "location", + xmlName: "location", type: { name: "String" } }, - trigger: { - serializedName: "trigger", - xmlName: "trigger", + properties: { + serializedName: "properties", + xmlName: "properties", type: { - name: "String" + name: "Composite", + className: "WorkflowEnvelopeProperties" } } } } }; -export const TriggeredJobHistoryCollection: coreClient.CompositeMapper = { - serializedName: "TriggeredJobHistoryCollection", +export const WorkflowEnvelopeProperties: coreClient.CompositeMapper = { + serializedName: "WorkflowEnvelopeProperties", type: { name: "Composite", - className: "TriggeredJobHistoryCollection", + className: "WorkflowEnvelopeProperties", modelProperties: { - value: { - serializedName: "value", - required: true, - xmlName: "value", - xmlElementName: "TriggeredJobHistory", + files: { + serializedName: "files", + xmlName: "files", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "TriggeredJobHistory" - } + name: "Dictionary", + value: { + type: { name: "Dictionary", value: { type: { name: "any" } } } } } }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - xmlName: "nextLink", + flowState: { + serializedName: "flowState", + xmlName: "flowState", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] + } + }, + health: { + serializedName: "health", + xmlName: "health", + type: { + name: "Composite", + className: "WorkflowHealth" } } } } }; -export const WebJobCollection: coreClient.CompositeMapper = { - serializedName: "WebJobCollection", +export const WorkflowHealth: coreClient.CompositeMapper = { + serializedName: "WorkflowHealth", type: { name: "Composite", - className: "WebJobCollection", + className: "WorkflowHealth", modelProperties: { - value: { - serializedName: "value", + state: { + serializedName: "state", required: true, - xmlName: "value", - xmlElementName: "WebJob", + xmlName: "state", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "WebJob" - } - } + name: "Enum", + allowedValues: ["NotSpecified", "Healthy", "Unhealthy", "Unknown"] } }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - xmlName: "nextLink", + error: { + serializedName: "error", + xmlName: "error", type: { - name: "String" + name: "Composite", + className: "ErrorEntity" } } } @@ -14430,7 +14863,15 @@ export const WorkflowFilter: coreClient.CompositeMapper = { serializedName: "state", xmlName: "state", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] } } } @@ -14512,7 +14953,15 @@ export const WorkflowTriggerFilter: coreClient.CompositeMapper = { serializedName: "state", xmlName: "state", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] } } } @@ -15578,6 +16027,13 @@ export const Site: coreClient.CompositeMapper = { type: { name: "String" } + }, + managedEnvironmentId: { + serializedName: "properties.managedEnvironmentId", + xmlName: "properties.managedEnvironmentId", + type: { + name: "String" + } } } } @@ -16412,6 +16868,21 @@ export const StaticSiteARMResource: coreClient.CompositeMapper = { type: { name: "String" } + }, + databaseConnections: { + serializedName: "properties.databaseConnections", + readOnly: true, + xmlName: "properties.databaseConnections", + xmlElementName: "DatabaseConnectionOverview", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DatabaseConnectionOverview" + } + } + } } } } @@ -20118,6 +20589,21 @@ export const StaticSitePatchResource: coreClient.CompositeMapper = { type: { name: "String" } + }, + databaseConnections: { + serializedName: "properties.databaseConnections", + readOnly: true, + xmlName: "properties.databaseConnections", + xmlElementName: "DatabaseConnectionOverview", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DatabaseConnectionOverview" + } + } + } } } } @@ -20257,6 +20743,21 @@ export const StaticSiteBuildARMResource: coreClient.CompositeMapper = { } } } + }, + databaseConnections: { + serializedName: "properties.databaseConnections", + readOnly: true, + xmlName: "properties.databaseConnections", + xmlElementName: "DatabaseConnectionOverview", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DatabaseConnectionOverview" + } + } + } } } } @@ -20281,6 +20782,60 @@ export const StringDictionary: coreClient.CompositeMapper = { } }; +export const DatabaseConnection: coreClient.CompositeMapper = { + serializedName: "DatabaseConnection", + type: { + name: "Composite", + className: "DatabaseConnection", + modelProperties: { + ...ProxyOnlyResource.type.modelProperties, + resourceId: { + serializedName: "properties.resourceId", + xmlName: "properties.resourceId", + type: { + name: "String" + } + }, + connectionIdentity: { + serializedName: "properties.connectionIdentity", + xmlName: "properties.connectionIdentity", + type: { + name: "String" + } + }, + connectionString: { + serializedName: "properties.connectionString", + xmlName: "properties.connectionString", + type: { + name: "String" + } + }, + region: { + serializedName: "properties.region", + xmlName: "properties.region", + type: { + name: "String" + } + }, + configurationFiles: { + serializedName: "properties.configurationFiles", + readOnly: true, + xmlName: "properties.configurationFiles", + xmlElementName: "StaticSiteDatabaseConnectionConfigurationFileOverview", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StaticSiteDatabaseConnectionConfigurationFileOverview" + } + } + } + } + } + } +}; + export const StaticSiteFunctionOverviewARMResource: coreClient.CompositeMapper = { serializedName: "StaticSiteFunctionOverviewARMResource", type: { @@ -20387,6 +20942,60 @@ export const StaticSiteZipDeploymentARMResource: coreClient.CompositeMapper = { } }; +export const StaticSiteBasicAuthPropertiesARMResource: coreClient.CompositeMapper = { + serializedName: "StaticSiteBasicAuthPropertiesARMResource", + type: { + name: "Composite", + className: "StaticSiteBasicAuthPropertiesARMResource", + modelProperties: { + ...ProxyOnlyResource.type.modelProperties, + password: { + serializedName: "properties.password", + xmlName: "properties.password", + type: { + name: "String" + } + }, + secretUrl: { + serializedName: "properties.secretUrl", + xmlName: "properties.secretUrl", + type: { + name: "String" + } + }, + applicableEnvironmentsMode: { + serializedName: "properties.applicableEnvironmentsMode", + xmlName: "properties.applicableEnvironmentsMode", + type: { + name: "String" + } + }, + environments: { + serializedName: "properties.environments", + xmlName: "properties.environments", + xmlElementName: + "StaticSiteBasicAuthPropertiesARMResourcePropertiesEnvironmentsItem", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + secretState: { + serializedName: "properties.secretState", + readOnly: true, + xmlName: "properties.secretState", + type: { + name: "String" + } + } + } + } +}; + export const StaticSiteUserInvitationRequestResource: coreClient.CompositeMapper = { serializedName: "StaticSiteUserInvitationRequestResource", type: { @@ -21595,6 +22204,20 @@ export const SiteConfigResource: coreClient.CompositeMapper = { } } }, + metadata: { + serializedName: "properties.metadata", + xmlName: "properties.metadata", + xmlElementName: "NameValuePair", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "NameValuePair" + } + } + } + }, connectionStrings: { serializedName: "properties.connectionStrings", xmlName: "properties.connectionStrings", @@ -21872,6 +22495,13 @@ export const SiteConfigResource: coreClient.CompositeMapper = { } } }, + ipSecurityRestrictionsDefaultAction: { + serializedName: "properties.ipSecurityRestrictionsDefaultAction", + xmlName: "properties.ipSecurityRestrictionsDefaultAction", + type: { + name: "String" + } + }, scmIpSecurityRestrictions: { serializedName: "properties.scmIpSecurityRestrictions", xmlName: "properties.scmIpSecurityRestrictions", @@ -21886,6 +22516,13 @@ export const SiteConfigResource: coreClient.CompositeMapper = { } } }, + scmIpSecurityRestrictionsDefaultAction: { + serializedName: "properties.scmIpSecurityRestrictionsDefaultAction", + xmlName: "properties.scmIpSecurityRestrictionsDefaultAction", + type: { + name: "String" + } + }, scmIpSecurityRestrictionsUseMain: { serializedName: "properties.scmIpSecurityRestrictionsUseMain", xmlName: "properties.scmIpSecurityRestrictionsUseMain", @@ -21943,6 +22580,16 @@ export const SiteConfigResource: coreClient.CompositeMapper = { name: "Number" } }, + elasticWebAppScaleLimit: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "properties.elasticWebAppScaleLimit", + xmlName: "properties.elasticWebAppScaleLimit", + type: { + name: "Number" + } + }, healthCheckPath: { serializedName: "properties.healthCheckPath", xmlName: "properties.healthCheckPath", @@ -25036,7 +25683,15 @@ export const WorkflowTrigger: coreClient.CompositeMapper = { readOnly: true, xmlName: "properties.state", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] } }, status: { @@ -25561,7 +26216,15 @@ export const Workflow: coreClient.CompositeMapper = { serializedName: "properties.state", xmlName: "properties.state", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] } }, version: { @@ -25682,7 +26345,15 @@ export const WorkflowVersion: coreClient.CompositeMapper = { serializedName: "properties.state", xmlName: "properties.state", type: { - name: "String" + name: "Enum", + allowedValues: [ + "NotSpecified", + "Completed", + "Enabled", + "Disabled", + "Deleted", + "Suspended" + ] } }, version: { @@ -25777,3 +26448,20 @@ export const WorkflowRunActionRepetitionProperties: coreClient.CompositeMapper = } } }; + +export const AppServiceEnvironmentsCreateOrUpdateHeaders: coreClient.CompositeMapper = { + serializedName: "AppServiceEnvironments_createOrUpdateHeaders", + type: { + name: "Composite", + className: "AppServiceEnvironmentsCreateOrUpdateHeaders", + modelProperties: { + location: { + serializedName: "location", + xmlName: "location", + type: { + name: "String" + } + } + } + } +}; diff --git a/sdk/appservice/arm-appservice/src/models/parameters.ts b/sdk/appservice/arm-appservice/src/models/parameters.ts index d9eee2d29ba8..8382315cbc91 100644 --- a/sdk/appservice/arm-appservice/src/models/parameters.ts +++ b/sdk/appservice/arm-appservice/src/models/parameters.ts @@ -52,8 +52,11 @@ import { StaticSitePatchResource as StaticSitePatchResourceMapper, StaticSiteUserARMResource as StaticSiteUserARMResourceMapper, StringDictionary as StringDictionaryMapper, + DatabaseConnection as DatabaseConnectionMapper, + DatabaseConnectionPatchRequest as DatabaseConnectionPatchRequestMapper, StaticSiteUserProvidedFunctionAppARMResource as StaticSiteUserProvidedFunctionAppARMResourceMapper, StaticSiteZipDeploymentARMResource as StaticSiteZipDeploymentARMResourceMapper, + StaticSiteBasicAuthPropertiesARMResource as StaticSiteBasicAuthPropertiesARMResourceMapper, StaticSiteUserInvitationRequestResource as StaticSiteUserInvitationRequestResourceMapper, StaticSiteCustomDomainRequestPropertiesARMResource as StaticSiteCustomDomainRequestPropertiesARMResourceMapper, StaticSiteResetPropertiesARMResource as StaticSiteResetPropertiesARMResourceMapper, @@ -92,6 +95,7 @@ import { SnapshotRestoreRequest as SnapshotRestoreRequestMapper, SiteSourceControl as SiteSourceControlMapper, VnetInfoResource as VnetInfoResourceMapper, + WorkflowArtifacts as WorkflowArtifactsMapper, RegenerateActionParameter as RegenerateActionParameterMapper, Workflow as WorkflowMapper } from "../models/mappers"; @@ -136,7 +140,7 @@ export const subscriptionId: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2022-03-01", + defaultValue: "2022-09-01", isConstant: true, serializedName: "api-version", type: { @@ -773,50 +777,6 @@ export const stackOsType: OperationQueryParameter = { } }; -export const stackOsType1: OperationQueryParameter = { - parameterPath: ["options", "stackOsType"], - mapper: { - serializedName: "stackOsType", - xmlName: "stackOsType", - type: { - name: "String" - } - } -}; - -export const stackOsType2: OperationQueryParameter = { - parameterPath: ["options", "stackOsType"], - mapper: { - serializedName: "stackOsType", - xmlName: "stackOsType", - type: { - name: "String" - } - } -}; - -export const stackOsType3: OperationQueryParameter = { - parameterPath: ["options", "stackOsType"], - mapper: { - serializedName: "stackOsType", - xmlName: "stackOsType", - type: { - name: "String" - } - } -}; - -export const osTypeSelected1: OperationQueryParameter = { - parameterPath: ["options", "osTypeSelected"], - mapper: { - serializedName: "osTypeSelected", - xmlName: "osTypeSelected", - type: { - name: "String" - } - } -}; - export const featured: OperationQueryParameter = { parameterPath: ["options", "featured"], mapper: { @@ -1075,6 +1035,46 @@ export const appSettings: OperationParameter = { mapper: StringDictionaryMapper }; +export const environmentName2: OperationURLParameter = { + parameterPath: "environmentName", + mapper: { + constraints: { + Pattern: new RegExp("^[a-zA-Z0-9]+$") + }, + serializedName: "environmentName", + required: true, + xmlName: "environmentName", + type: { + name: "String" + } + } +}; + +export const databaseConnectionName: OperationURLParameter = { + parameterPath: "databaseConnectionName", + mapper: { + constraints: { + Pattern: new RegExp("^[a-zA-Z0-9]+$") + }, + serializedName: "databaseConnectionName", + required: true, + xmlName: "databaseConnectionName", + type: { + name: "String" + } + } +}; + +export const databaseConnectionRequestEnvelope: OperationParameter = { + parameterPath: "databaseConnectionRequestEnvelope", + mapper: DatabaseConnectionMapper +}; + +export const databaseConnectionRequestEnvelope1: OperationParameter = { + parameterPath: "databaseConnectionRequestEnvelope", + mapper: DatabaseConnectionPatchRequestMapper +}; + export const functionAppName: OperationURLParameter = { parameterPath: "functionAppName", mapper: { @@ -1108,6 +1108,23 @@ export const staticSiteZipDeploymentEnvelope: OperationParameter = { mapper: StaticSiteZipDeploymentARMResourceMapper }; +export const basicAuthName: OperationURLParameter = { + parameterPath: "basicAuthName", + mapper: { + serializedName: "basicAuthName", + required: true, + xmlName: "basicAuthName", + type: { + name: "String" + } + } +}; + +export const basicAuthEnvelope: OperationParameter = { + parameterPath: "basicAuthEnvelope", + mapper: StaticSiteBasicAuthPropertiesARMResourceMapper +}; + export const staticSiteUserRolesInvitationEnvelope: OperationParameter = { parameterPath: "staticSiteUserRolesInvitationEnvelope", mapper: StaticSiteUserInvitationRequestResourceMapper @@ -1713,12 +1730,34 @@ export const connectionEnvelope4: OperationParameter = { mapper: VnetInfoResourceMapper }; +export const workflowArtifacts: OperationParameter = { + parameterPath: ["options", "workflowArtifacts"], + mapper: WorkflowArtifactsMapper +}; + +export const workflowName: OperationURLParameter = { + parameterPath: "workflowName", + mapper: { + constraints: { + Pattern: new RegExp("^[a-z][a-z0-9]*$"), + MaxLength: 63, + MinLength: 3 + }, + serializedName: "workflowName", + required: true, + xmlName: "workflowName", + type: { + name: "String" + } + } +}; + export const keyType1: OperationParameter = { parameterPath: "keyType", mapper: RegenerateActionParameterMapper }; -export const workflowName: OperationURLParameter = { +export const workflowName1: OperationURLParameter = { parameterPath: "workflowName", mapper: { serializedName: "workflowName", diff --git a/sdk/appservice/arm-appservice/src/operations/appServiceCertificateOrders.ts b/sdk/appservice/arm-appservice/src/operations/appServiceCertificateOrders.ts index f56f50c3e4a5..75eea7220361 100644 --- a/sdk/appservice/arm-appservice/src/operations/appServiceCertificateOrders.ts +++ b/sdk/appservice/arm-appservice/src/operations/appServiceCertificateOrders.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { AppServiceCertificateOrder, AppServiceCertificateOrdersListNextOptionalParams, @@ -355,8 +359,8 @@ export class AppServiceCertificateOrdersImpl certificateDistinguishedName: AppServiceCertificateOrder, options?: AppServiceCertificateOrdersCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceCertificateOrdersCreateOrUpdateResponse > > { @@ -366,7 +370,7 @@ export class AppServiceCertificateOrdersImpl ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -399,18 +403,21 @@ export class AppServiceCertificateOrdersImpl }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, certificateOrderName, certificateDistinguishedName, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + AppServiceCertificateOrdersCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -531,8 +538,8 @@ export class AppServiceCertificateOrdersImpl keyVaultCertificate: AppServiceCertificateResource, options?: AppServiceCertificateOrdersCreateOrUpdateCertificateOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceCertificateOrdersCreateOrUpdateCertificateResponse >, AppServiceCertificateOrdersCreateOrUpdateCertificateResponse @@ -544,7 +551,7 @@ export class AppServiceCertificateOrdersImpl ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -577,19 +584,24 @@ export class AppServiceCertificateOrdersImpl }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, certificateOrderName, name, keyVaultCertificate, options }, - createOrUpdateCertificateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: createOrUpdateCertificateOperationSpec + }); + const poller = await createHttpPoller< + AppServiceCertificateOrdersCreateOrUpdateCertificateResponse, + OperationState< + AppServiceCertificateOrdersCreateOrUpdateCertificateResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1364,7 +1376,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1384,7 +1395,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1405,7 +1415,6 @@ const listCertificatesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/appServiceEnvironments.ts b/sdk/appservice/arm-appservice/src/operations/appServiceEnvironments.ts index d9344a86f2da..8bfbea27b612 100644 --- a/sdk/appservice/arm-appservice/src/operations/appServiceEnvironments.ts +++ b/sdk/appservice/arm-appservice/src/operations/appServiceEnvironments.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { AppServiceEnvironmentResource, AppServiceEnvironmentsListNextOptionalParams, @@ -2063,8 +2067,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { hostingEnvironmentEnvelope: AppServiceEnvironmentResource, options?: AppServiceEnvironmentsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateResponse > > { @@ -2074,7 +2078,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2107,13 +2111,16 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, hostingEnvironmentEnvelope, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, hostingEnvironmentEnvelope, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2152,14 +2159,14 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2192,13 +2199,13 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - deleteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: deleteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2286,8 +2293,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { vnetInfo: VirtualNetworkProfile, options?: AppServiceEnvironmentsChangeVnetOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceEnvironmentsChangeVnetResponse > > { @@ -2297,7 +2304,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2330,13 +2337,16 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, vnetInfo, options }, - changeVnetOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, vnetInfo, options }, + spec: changeVnetOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsChangeVnetResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2538,10 +2548,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { multiRolePoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams ): Promise< - PollerLike< - PollOperationState< - AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse - >, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse > > { @@ -2551,7 +2559,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2584,13 +2592,16 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, multiRolePoolEnvelope, options }, - createOrUpdateMultiRolePoolOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, multiRolePoolEnvelope, options }, + spec: createOrUpdateMultiRolePoolOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2721,14 +2732,14 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { resourceGroupName: string, name: string, options?: AppServiceEnvironmentsUpgradeOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2761,13 +2772,13 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - upgradeOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: upgradeOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2894,8 +2905,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse >, AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse @@ -2907,7 +2918,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2940,19 +2951,24 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, privateEndpointWrapper, options }, - approveOrRejectPrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: approveOrRejectPrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse, + OperationState< + AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2999,8 +3015,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { privateEndpointConnectionName: string, options?: AppServiceEnvironmentsDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse >, AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse @@ -3012,7 +3028,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3045,13 +3061,18 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, privateEndpointConnectionName, options }, - deletePrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, options }, + spec: deletePrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse, + OperationState< + AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3125,8 +3146,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { name: string, options?: AppServiceEnvironmentsResumeOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceEnvironmentsResumeResponse > > { @@ -3136,7 +3157,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3169,13 +3190,16 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - resumeOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: resumeOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsResumeResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3227,8 +3251,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { name: string, options?: AppServiceEnvironmentsSuspendOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceEnvironmentsSuspendResponse > > { @@ -3238,7 +3262,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3271,13 +3295,16 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - suspendOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: suspendOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsSuspendResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3352,10 +3379,8 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { workerPoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateWorkerPoolOptionalParams ): Promise< - PollerLike< - PollOperationState< - AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse - >, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse > > { @@ -3365,7 +3390,7 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3398,13 +3423,22 @@ export class AppServiceEnvironmentsImpl implements AppServiceEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, workerPoolName, workerPoolEnvelope, options }, - createOrUpdateWorkerPoolOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + name, + workerPoolName, + workerPoolEnvelope, + options + }, + spec: createOrUpdateWorkerPoolOperationSpec + }); + const poller = await createHttpPoller< + AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -5190,7 +5224,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5210,7 +5243,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5231,7 +5263,6 @@ const listCapacitiesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5256,7 +5287,6 @@ const changeVnetNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5279,7 +5309,6 @@ const getInboundNetworkDependenciesEndpointsNextOperationSpec: coreClient.Operat bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5301,7 +5330,6 @@ const listMultiRolePoolsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5323,7 +5351,6 @@ const listMultiRolePoolInstanceMetricDefinitionsNextOperationSpec: coreClient.Op bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5346,7 +5373,6 @@ const listMultiRoleMetricDefinitionsNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5368,7 +5394,6 @@ const listMultiRolePoolSkusNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5390,7 +5415,6 @@ const listMultiRoleUsagesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5412,7 +5436,6 @@ const getOutboundNetworkDependenciesEndpointsNextOperationSpec: coreClient.Opera bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5434,7 +5457,6 @@ const getPrivateEndpointConnectionListNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5459,7 +5481,6 @@ const resumeNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5481,7 +5502,6 @@ const listAppServicePlansNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5503,7 +5523,6 @@ const listWebAppsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.propertiesToInclude], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5528,7 +5547,6 @@ const suspendNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5550,7 +5568,6 @@ const listUsagesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5572,7 +5589,6 @@ const listWorkerPoolsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5594,7 +5610,6 @@ const listWorkerPoolInstanceMetricDefinitionsNextOperationSpec: coreClient.Opera bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5618,7 +5633,6 @@ const listWebWorkerMetricDefinitionsNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5641,7 +5655,6 @@ const listWorkerPoolSkusNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5664,7 +5677,6 @@ const listWebWorkerUsagesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/appServicePlans.ts b/sdk/appservice/arm-appservice/src/operations/appServicePlans.ts index a0c3a3d9b8c7..81623f792197 100644 --- a/sdk/appservice/arm-appservice/src/operations/appServicePlans.ts +++ b/sdk/appservice/arm-appservice/src/operations/appServicePlans.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { AppServicePlan, AppServicePlansListNextOptionalParams, @@ -615,8 +619,8 @@ export class AppServicePlansImpl implements AppServicePlans { appServicePlan: AppServicePlan, options?: AppServicePlansCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServicePlansCreateOrUpdateResponse > > { @@ -626,7 +630,7 @@ export class AppServicePlansImpl implements AppServicePlans { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -659,13 +663,16 @@ export class AppServicePlansImpl implements AppServicePlans { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, appServicePlan, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, appServicePlan, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + AppServicePlansCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1950,7 +1957,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.detailed], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1970,7 +1976,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1991,7 +1996,6 @@ const listWebAppsByHybridConnectionNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2015,7 +2019,6 @@ const listHybridConnectionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2037,12 +2040,6 @@ const listWebAppsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.skipToken, - Parameters.top - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2064,7 +2061,6 @@ const listUsagesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/certificateOrdersDiagnostics.ts b/sdk/appservice/arm-appservice/src/operations/certificateOrdersDiagnostics.ts index 31c94e1a4802..76f4fd43dbfb 100644 --- a/sdk/appservice/arm-appservice/src/operations/certificateOrdersDiagnostics.ts +++ b/sdk/appservice/arm-appservice/src/operations/certificateOrdersDiagnostics.ts @@ -247,7 +247,6 @@ const listAppServiceCertificateOrderDetectorResponseNextOperationSpec: coreClien bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/certificateRegistrationProvider.ts b/sdk/appservice/arm-appservice/src/operations/certificateRegistrationProvider.ts index 177d2a6dcb32..c7eb6d89ca18 100644 --- a/sdk/appservice/arm-appservice/src/operations/certificateRegistrationProvider.ts +++ b/sdk/appservice/arm-appservice/src/operations/certificateRegistrationProvider.ts @@ -149,7 +149,6 @@ const listOperationsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer diff --git a/sdk/appservice/arm-appservice/src/operations/certificates.ts b/sdk/appservice/arm-appservice/src/operations/certificates.ts index 3fdea6d39b10..c5d88361f8ac 100644 --- a/sdk/appservice/arm-appservice/src/operations/certificates.ts +++ b/sdk/appservice/arm-appservice/src/operations/certificates.ts @@ -440,7 +440,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -460,7 +459,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/containerApps.ts b/sdk/appservice/arm-appservice/src/operations/containerApps.ts index fe360731318f..b4363bec9652 100644 --- a/sdk/appservice/arm-appservice/src/operations/containerApps.ts +++ b/sdk/appservice/arm-appservice/src/operations/containerApps.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { ContainerApp, ContainerAppsListBySubscriptionNextOptionalParams, @@ -228,8 +232,8 @@ export class ContainerAppsImpl implements ContainerApps { containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, ContainerAppsCreateOrUpdateResponse > > { @@ -239,7 +243,7 @@ export class ContainerAppsImpl implements ContainerApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -272,13 +276,16 @@ export class ContainerAppsImpl implements ContainerApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, containerAppEnvelope, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, containerAppEnvelope, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + ContainerAppsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -317,14 +324,14 @@ export class ContainerAppsImpl implements ContainerApps { resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -357,13 +364,13 @@ export class ContainerAppsImpl implements ContainerApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - deleteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: deleteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -581,7 +588,6 @@ const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -601,7 +607,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/containerAppsRevisions.ts b/sdk/appservice/arm-appservice/src/operations/containerAppsRevisions.ts index 73e60cc7b380..df3f585ad3ab 100644 --- a/sdk/appservice/arm-appservice/src/operations/containerAppsRevisions.ts +++ b/sdk/appservice/arm-appservice/src/operations/containerAppsRevisions.ts @@ -357,7 +357,6 @@ const listRevisionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/deletedWebApps.ts b/sdk/appservice/arm-appservice/src/operations/deletedWebApps.ts index f49930693833..dfeddf8fc1c6 100644 --- a/sdk/appservice/arm-appservice/src/operations/deletedWebApps.ts +++ b/sdk/appservice/arm-appservice/src/operations/deletedWebApps.ts @@ -303,7 +303,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -323,7 +322,6 @@ const listByLocationNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/diagnostics.ts b/sdk/appservice/arm-appservice/src/operations/diagnostics.ts index a6515ee97bdd..52591f861027 100644 --- a/sdk/appservice/arm-appservice/src/operations/diagnostics.ts +++ b/sdk/appservice/arm-appservice/src/operations/diagnostics.ts @@ -2193,7 +2193,6 @@ const listHostingEnvironmentDetectorResponsesNextOperationSpec: coreClient.Opera bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2215,7 +2214,6 @@ const listSiteDetectorResponsesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2237,7 +2235,6 @@ const listSiteDiagnosticCategoriesNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2259,7 +2256,6 @@ const listSiteAnalysesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2282,7 +2278,6 @@ const listSiteDetectorsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2305,7 +2300,6 @@ const listSiteDetectorResponsesSlotNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2328,7 +2322,6 @@ const listSiteDiagnosticCategoriesSlotNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2351,7 +2344,6 @@ const listSiteAnalysesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -2375,7 +2367,6 @@ const listSiteDetectorsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/domainRegistrationProvider.ts b/sdk/appservice/arm-appservice/src/operations/domainRegistrationProvider.ts index 5ac414e02b9d..c9ba45f696d7 100644 --- a/sdk/appservice/arm-appservice/src/operations/domainRegistrationProvider.ts +++ b/sdk/appservice/arm-appservice/src/operations/domainRegistrationProvider.ts @@ -149,7 +149,6 @@ const listOperationsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer diff --git a/sdk/appservice/arm-appservice/src/operations/domains.ts b/sdk/appservice/arm-appservice/src/operations/domains.ts index 901a5132d180..3fa502de87ed 100644 --- a/sdk/appservice/arm-appservice/src/operations/domains.ts +++ b/sdk/appservice/arm-appservice/src/operations/domains.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { Domain, DomainsListNextOptionalParams, @@ -447,8 +451,8 @@ export class DomainsImpl implements Domains { domain: Domain, options?: DomainsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, DomainsCreateOrUpdateResponse > > { @@ -458,7 +462,7 @@ export class DomainsImpl implements Domains { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -491,13 +495,16 @@ export class DomainsImpl implements Domains { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, domainName, domain, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, domainName, domain, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + DomainsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1150,7 +1157,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1170,7 +1176,6 @@ const listRecommendationsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1191,7 +1196,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1212,7 +1216,6 @@ const listOwnershipIdentifiersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/kubeEnvironments.ts b/sdk/appservice/arm-appservice/src/operations/kubeEnvironments.ts index d1ba086c5162..7439c72f431b 100644 --- a/sdk/appservice/arm-appservice/src/operations/kubeEnvironments.ts +++ b/sdk/appservice/arm-appservice/src/operations/kubeEnvironments.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { KubeEnvironment, KubeEnvironmentsListBySubscriptionNextOptionalParams, @@ -229,8 +233,8 @@ export class KubeEnvironmentsImpl implements KubeEnvironments { kubeEnvironmentEnvelope: KubeEnvironment, options?: KubeEnvironmentsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, KubeEnvironmentsCreateOrUpdateResponse > > { @@ -240,7 +244,7 @@ export class KubeEnvironmentsImpl implements KubeEnvironments { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -273,13 +277,16 @@ export class KubeEnvironmentsImpl implements KubeEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, kubeEnvironmentEnvelope, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, kubeEnvironmentEnvelope, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + KubeEnvironmentsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -318,14 +325,14 @@ export class KubeEnvironmentsImpl implements KubeEnvironments { resourceGroupName: string, name: string, options?: KubeEnvironmentsDeleteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -358,13 +365,13 @@ export class KubeEnvironmentsImpl implements KubeEnvironments { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - deleteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: deleteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -594,7 +601,6 @@ const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -614,7 +620,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/provider.ts b/sdk/appservice/arm-appservice/src/operations/provider.ts index 47a843869aaf..32f41c706eee 100644 --- a/sdk/appservice/arm-appservice/src/operations/provider.ts +++ b/sdk/appservice/arm-appservice/src/operations/provider.ts @@ -730,7 +730,7 @@ const getFunctionAppStacksForLocationOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType1], + queryParameters: [Parameters.apiVersion, Parameters.stackOsType], urlParameters: [Parameters.$host, Parameters.location], headerParameters: [Parameters.accept], serializer @@ -746,7 +746,7 @@ const getWebAppStacksForLocationOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType2], + queryParameters: [Parameters.apiVersion, Parameters.stackOsType], urlParameters: [Parameters.$host, Parameters.location], headerParameters: [Parameters.accept], serializer @@ -778,7 +778,7 @@ const getWebAppStacksOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType3], + queryParameters: [Parameters.apiVersion, Parameters.stackOsType], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], serializer @@ -795,7 +795,7 @@ const getAvailableStacksOnPremOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.osTypeSelected1], + queryParameters: [Parameters.apiVersion, Parameters.osTypeSelected], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], serializer @@ -811,7 +811,6 @@ const getAvailableStacksNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.osTypeSelected], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer @@ -827,7 +826,6 @@ const getFunctionAppStacksNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer @@ -843,7 +841,6 @@ const getFunctionAppStacksForLocationNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType1], urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.location], headerParameters: [Parameters.accept], serializer @@ -859,7 +856,6 @@ const getWebAppStacksForLocationNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType2], urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.location], headerParameters: [Parameters.accept], serializer @@ -875,7 +871,6 @@ const listOperationsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer @@ -891,7 +886,6 @@ const getWebAppStacksNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.stackOsType3], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer @@ -907,7 +901,6 @@ const getAvailableStacksOnPremNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.osTypeSelected1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/recommendations.ts b/sdk/appservice/arm-appservice/src/operations/recommendations.ts index 960307a1f2d2..6d1cabd71e96 100644 --- a/sdk/appservice/arm-appservice/src/operations/recommendations.ts +++ b/sdk/appservice/arm-appservice/src/operations/recommendations.ts @@ -1155,11 +1155,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.featured - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1179,11 +1174,6 @@ const listHistoryForHostingEnvironmentNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.expiredOnly - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1205,11 +1195,6 @@ const listRecommendedRulesForHostingEnvironmentNextOperationSpec: coreClient.Ope bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.featured - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1231,11 +1216,6 @@ const listHistoryForWebAppNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.expiredOnly - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1257,11 +1237,6 @@ const listRecommendedRulesForWebAppNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.featured - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/resourceHealthMetadataOperations.ts b/sdk/appservice/arm-appservice/src/operations/resourceHealthMetadataOperations.ts index 0dee824b478c..2bfe0f7a86ed 100644 --- a/sdk/appservice/arm-appservice/src/operations/resourceHealthMetadataOperations.ts +++ b/sdk/appservice/arm-appservice/src/operations/resourceHealthMetadataOperations.ts @@ -660,7 +660,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -680,7 +679,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -701,7 +699,6 @@ const listBySiteNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -723,7 +720,6 @@ const listBySiteSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/staticSites.ts b/sdk/appservice/arm-appservice/src/operations/staticSites.ts index ced52e1c7042..be7467cd202b 100644 --- a/sdk/appservice/arm-appservice/src/operations/staticSites.ts +++ b/sdk/appservice/arm-appservice/src/operations/staticSites.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { StaticSiteARMResource, StaticSitesListNextOptionalParams, @@ -31,18 +35,32 @@ import { StaticSitesGetStaticSiteBuildsNextOptionalParams, StaticSitesGetStaticSiteBuildsOptionalParams, StaticSitesGetStaticSiteBuildsResponse, + DatabaseConnection, + StaticSitesGetBuildDatabaseConnectionsNextOptionalParams, + StaticSitesGetBuildDatabaseConnectionsOptionalParams, + StaticSitesGetBuildDatabaseConnectionsResponse, StaticSiteFunctionOverviewARMResource, StaticSitesListStaticSiteBuildFunctionsNextOptionalParams, StaticSitesListStaticSiteBuildFunctionsOptionalParams, StaticSitesListStaticSiteBuildFunctionsResponse, + StaticSitesGetBuildDatabaseConnectionsWithDetailsNextOptionalParams, + StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams, + StaticSitesGetBuildDatabaseConnectionsWithDetailsResponse, StaticSiteUserProvidedFunctionAppARMResource, StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildNextOptionalParams, StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams, StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildResponse, + StaticSiteBasicAuthPropertiesARMResource, + StaticSitesListBasicAuthNextOptionalParams, + StaticSitesListBasicAuthOptionalParams, + StaticSitesListBasicAuthResponse, StaticSiteCustomDomainOverviewARMResource, StaticSitesListStaticSiteCustomDomainsNextOptionalParams, StaticSitesListStaticSiteCustomDomainsOptionalParams, StaticSitesListStaticSiteCustomDomainsResponse, + StaticSitesGetDatabaseConnectionsNextOptionalParams, + StaticSitesGetDatabaseConnectionsOptionalParams, + StaticSitesGetDatabaseConnectionsResponse, StaticSitesListStaticSiteFunctionsNextOptionalParams, StaticSitesListStaticSiteFunctionsOptionalParams, StaticSitesListStaticSiteFunctionsResponse, @@ -50,6 +68,9 @@ import { StaticSitesGetPrivateEndpointConnectionListNextOptionalParams, StaticSitesGetPrivateEndpointConnectionListOptionalParams, StaticSitesGetPrivateEndpointConnectionListResponse, + StaticSitesGetDatabaseConnectionsWithDetailsNextOptionalParams, + StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams, + StaticSitesGetDatabaseConnectionsWithDetailsResponse, StaticSitesGetUserProvidedFunctionAppsForStaticSiteNextOptionalParams, StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams, StaticSitesGetUserProvidedFunctionAppsForStaticSiteResponse, @@ -82,6 +103,16 @@ import { StaticSitesCreateOrUpdateStaticSiteBuildAppSettingsResponse, StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse, + StaticSitesGetBuildDatabaseConnectionOptionalParams, + StaticSitesGetBuildDatabaseConnectionResponse, + StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams, + StaticSitesCreateOrUpdateBuildDatabaseConnectionResponse, + StaticSitesDeleteBuildDatabaseConnectionOptionalParams, + DatabaseConnectionPatchRequest, + StaticSitesUpdateBuildDatabaseConnectionOptionalParams, + StaticSitesUpdateBuildDatabaseConnectionResponse, + StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams, + StaticSitesGetBuildDatabaseConnectionWithDetailsResponse, StaticSitesListStaticSiteBuildAppSettingsOptionalParams, StaticSitesListStaticSiteBuildAppSettingsResponse, StaticSitesListStaticSiteBuildFunctionAppSettingsOptionalParams, @@ -95,6 +126,11 @@ import { StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams, StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteAppSettingsResponse, + BasicAuthName, + StaticSitesGetBasicAuthOptionalParams, + StaticSitesGetBasicAuthResponse, + StaticSitesCreateOrUpdateBasicAuthOptionalParams, + StaticSitesCreateOrUpdateBasicAuthResponse, StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsResponse, StaticSiteUserInvitationRequestResource, @@ -107,6 +143,15 @@ import { StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse, StaticSitesDeleteStaticSiteCustomDomainOptionalParams, StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams, + StaticSitesGetDatabaseConnectionOptionalParams, + StaticSitesGetDatabaseConnectionResponse, + StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams, + StaticSitesCreateOrUpdateDatabaseConnectionResponse, + StaticSitesDeleteDatabaseConnectionOptionalParams, + StaticSitesUpdateDatabaseConnectionOptionalParams, + StaticSitesUpdateDatabaseConnectionResponse, + StaticSitesGetDatabaseConnectionWithDetailsOptionalParams, + StaticSitesGetDatabaseConnectionWithDetailsResponse, StaticSitesDetachStaticSiteOptionalParams, StaticSitesListStaticSiteAppSettingsOptionalParams, StaticSitesListStaticSiteAppSettingsResponse, @@ -149,11 +194,16 @@ import { StaticSitesGetStaticSitesByResourceGroupNextResponse, StaticSitesListStaticSiteUsersNextResponse, StaticSitesGetStaticSiteBuildsNextResponse, + StaticSitesGetBuildDatabaseConnectionsNextResponse, StaticSitesListStaticSiteBuildFunctionsNextResponse, + StaticSitesGetBuildDatabaseConnectionsWithDetailsNextResponse, StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildNextResponse, + StaticSitesListBasicAuthNextResponse, StaticSitesListStaticSiteCustomDomainsNextResponse, + StaticSitesGetDatabaseConnectionsNextResponse, StaticSitesListStaticSiteFunctionsNextResponse, StaticSitesGetPrivateEndpointConnectionListNextResponse, + StaticSitesGetDatabaseConnectionsWithDetailsNextResponse, StaticSitesGetUserProvidedFunctionAppsForStaticSiteNextResponse, StaticSitesGetLinkedBackendsNextResponse, StaticSitesGetLinkedBackendsForBuildNextResponse @@ -479,19 +529,19 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets the functions of a particular static site build. + * Returns overviews of database connections for a static site build * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site. + * @param name Name of the static site * @param environmentName The stage site identifier. * @param options The options parameters. */ - public listStaticSiteBuildFunctions( + public listBuildDatabaseConnections( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listStaticSiteBuildFunctionsPagingAll( + options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getBuildDatabaseConnectionsPagingAll( resourceGroupName, name, environmentName, @@ -508,7 +558,7 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.listStaticSiteBuildFunctionsPagingPage( + return this.getBuildDatabaseConnectionsPagingPage( resourceGroupName, name, environmentName, @@ -519,17 +569,17 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *listStaticSiteBuildFunctionsPagingPage( + private async *getBuildDatabaseConnectionsPagingPage( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams, + options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesListStaticSiteBuildFunctionsResponse; + ): AsyncIterableIterator { + let result: StaticSitesGetBuildDatabaseConnectionsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._listStaticSiteBuildFunctions( + result = await this._getBuildDatabaseConnections( resourceGroupName, name, environmentName, @@ -541,7 +591,7 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._listStaticSiteBuildFunctionsNext( + result = await this._getBuildDatabaseConnectionsNext( resourceGroupName, name, environmentName, @@ -555,13 +605,13 @@ export class StaticSitesImpl implements StaticSites { } } - private async *listStaticSiteBuildFunctionsPagingAll( + private async *getBuildDatabaseConnectionsPagingAll( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listStaticSiteBuildFunctionsPagingPage( + options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getBuildDatabaseConnectionsPagingPage( resourceGroupName, name, environmentName, @@ -572,20 +622,19 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets the details of the user provided function apps registered with a static site - * build + * Description for Gets the functions of a particular static site build. * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the static site. * @param environmentName The stage site identifier. * @param options The options parameters. */ - public listUserProvidedFunctionAppsForStaticSiteBuild( + public listStaticSiteBuildFunctions( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.getUserProvidedFunctionAppsForStaticSiteBuildPagingAll( + options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listStaticSiteBuildFunctionsPagingAll( resourceGroupName, name, environmentName, @@ -602,7 +651,7 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( + return this.listStaticSiteBuildFunctionsPagingPage( resourceGroupName, name, environmentName, @@ -613,17 +662,17 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( + private async *listStaticSiteBuildFunctionsPagingPage( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams, + options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildResponse; + ): AsyncIterableIterator { + let result: StaticSitesListStaticSiteBuildFunctionsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._getUserProvidedFunctionAppsForStaticSiteBuild( + result = await this._listStaticSiteBuildFunctions( resourceGroupName, name, environmentName, @@ -635,7 +684,7 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._getUserProvidedFunctionAppsForStaticSiteBuildNext( + result = await this._listStaticSiteBuildFunctionsNext( resourceGroupName, name, environmentName, @@ -649,13 +698,13 @@ export class StaticSitesImpl implements StaticSites { } } - private async *getUserProvidedFunctionAppsForStaticSiteBuildPagingAll( + private async *listStaticSiteBuildFunctionsPagingAll( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams - ): AsyncIterableIterator { - for await (const page of this.getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( + options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listStaticSiteBuildFunctionsPagingPage( resourceGroupName, name, environmentName, @@ -666,19 +715,22 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets all static site custom domains for a particular static site. + * Returns details of database connections for a static site build * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site resource to search in. + * @param name Name of the static site + * @param environmentName The stage site identifier. * @param options The options parameters. */ - public listStaticSiteCustomDomains( + public listBuildDatabaseConnectionsWithDetails( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteCustomDomainsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listStaticSiteCustomDomainsPagingAll( + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getBuildDatabaseConnectionsWithDetailsPagingAll( resourceGroupName, name, + environmentName, options ); return { @@ -692,9 +744,10 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.listStaticSiteCustomDomainsPagingPage( + return this.getBuildDatabaseConnectionsWithDetailsPagingPage( resourceGroupName, name, + environmentName, options, settings ); @@ -702,18 +755,20 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *listStaticSiteCustomDomainsPagingPage( + private async *getBuildDatabaseConnectionsWithDetailsPagingPage( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteCustomDomainsOptionalParams, + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesListStaticSiteCustomDomainsResponse; + ): AsyncIterableIterator { + let result: StaticSitesGetBuildDatabaseConnectionsWithDetailsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._listStaticSiteCustomDomains( + result = await this._getBuildDatabaseConnectionsWithDetails( resourceGroupName, name, + environmentName, options ); let page = result.value || []; @@ -722,9 +777,10 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._listStaticSiteCustomDomainsNext( + result = await this._getBuildDatabaseConnectionsWithDetailsNext( resourceGroupName, name, + environmentName, continuationToken, options ); @@ -735,14 +791,16 @@ export class StaticSitesImpl implements StaticSites { } } - private async *listStaticSiteCustomDomainsPagingAll( + private async *getBuildDatabaseConnectionsWithDetailsPagingAll( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteCustomDomainsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listStaticSiteCustomDomainsPagingPage( + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getBuildDatabaseConnectionsWithDetailsPagingPage( resourceGroupName, name, + environmentName, options )) { yield* page; @@ -750,19 +808,23 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets the functions of a static site. + * Description for Gets the details of the user provided function apps registered with a static site + * build * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the static site. + * @param environmentName The stage site identifier. * @param options The options parameters. */ - public listStaticSiteFunctions( + public listUserProvidedFunctionAppsForStaticSiteBuild( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteFunctionsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listStaticSiteFunctionsPagingAll( + environmentName: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getUserProvidedFunctionAppsForStaticSiteBuildPagingAll( resourceGroupName, name, + environmentName, options ); return { @@ -776,9 +838,10 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.listStaticSiteFunctionsPagingPage( + return this.getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( resourceGroupName, name, + environmentName, options, settings ); @@ -786,18 +849,20 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *listStaticSiteFunctionsPagingPage( + private async *getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteFunctionsOptionalParams, + environmentName: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesListStaticSiteFunctionsResponse; + ): AsyncIterableIterator { + let result: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._listStaticSiteFunctions( + result = await this._getUserProvidedFunctionAppsForStaticSiteBuild( resourceGroupName, name, + environmentName, options ); let page = result.value || []; @@ -806,9 +871,10 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._listStaticSiteFunctionsNext( + result = await this._getUserProvidedFunctionAppsForStaticSiteBuildNext( resourceGroupName, name, + environmentName, continuationToken, options ); @@ -819,14 +885,16 @@ export class StaticSitesImpl implements StaticSites { } } - private async *listStaticSiteFunctionsPagingAll( + private async *getUserProvidedFunctionAppsForStaticSiteBuildPagingAll( resourceGroupName: string, name: string, - options?: StaticSitesListStaticSiteFunctionsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listStaticSiteFunctionsPagingPage( + environmentName: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getUserProvidedFunctionAppsForStaticSiteBuildPagingPage( resourceGroupName, name, + environmentName, options )) { yield* page; @@ -834,21 +902,17 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets the list of private endpoint connections associated with a static site + * Description for Gets the basic auth properties for a static site as a collection. * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the static site. * @param options The options parameters. */ - public listPrivateEndpointConnectionList( + public listBasicAuth( resourceGroupName: string, name: string, - options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.getPrivateEndpointConnectionListPagingAll( - resourceGroupName, - name, - options - ); + options?: StaticSitesListBasicAuthOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listBasicAuthPagingAll(resourceGroupName, name, options); return { next() { return iter.next(); @@ -860,7 +924,7 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.getPrivateEndpointConnectionListPagingPage( + return this.listBasicAuthPagingPage( resourceGroupName, name, options, @@ -870,27 +934,23 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *getPrivateEndpointConnectionListPagingPage( + private async *listBasicAuthPagingPage( resourceGroupName: string, name: string, - options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams, + options?: StaticSitesListBasicAuthOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesGetPrivateEndpointConnectionListResponse; + ): AsyncIterableIterator { + let result: StaticSitesListBasicAuthResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._getPrivateEndpointConnectionList( - resourceGroupName, - name, - options - ); + result = await this._listBasicAuth(resourceGroupName, name, options); let page = result.value || []; continuationToken = result.nextLink; setContinuationToken(page, continuationToken); yield page; } while (continuationToken) { - result = await this._getPrivateEndpointConnectionListNext( + result = await this._listBasicAuthNext( resourceGroupName, name, continuationToken, @@ -903,12 +963,12 @@ export class StaticSitesImpl implements StaticSites { } } - private async *getPrivateEndpointConnectionListPagingAll( + private async *listBasicAuthPagingAll( resourceGroupName: string, name: string, - options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams - ): AsyncIterableIterator { - for await (const page of this.getPrivateEndpointConnectionListPagingPage( + options?: StaticSitesListBasicAuthOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listBasicAuthPagingPage( resourceGroupName, name, options @@ -918,17 +978,17 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Gets the details of the user provided function apps registered with a static site + * Description for Gets all static site custom domains for a particular static site. * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site. + * @param name Name of the static site resource to search in. * @param options The options parameters. */ - public listUserProvidedFunctionAppsForStaticSite( + public listStaticSiteCustomDomains( resourceGroupName: string, name: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.getUserProvidedFunctionAppsForStaticSitePagingAll( + options?: StaticSitesListStaticSiteCustomDomainsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listStaticSiteCustomDomainsPagingAll( resourceGroupName, name, options @@ -944,7 +1004,7 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.getUserProvidedFunctionAppsForStaticSitePagingPage( + return this.listStaticSiteCustomDomainsPagingPage( resourceGroupName, name, options, @@ -954,16 +1014,16 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *getUserProvidedFunctionAppsForStaticSitePagingPage( + private async *listStaticSiteCustomDomainsPagingPage( resourceGroupName: string, name: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams, + options?: StaticSitesListStaticSiteCustomDomainsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesGetUserProvidedFunctionAppsForStaticSiteResponse; + ): AsyncIterableIterator { + let result: StaticSitesListStaticSiteCustomDomainsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._getUserProvidedFunctionAppsForStaticSite( + result = await this._listStaticSiteCustomDomains( resourceGroupName, name, options @@ -974,7 +1034,7 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._getUserProvidedFunctionAppsForStaticSiteNext( + result = await this._listStaticSiteCustomDomainsNext( resourceGroupName, name, continuationToken, @@ -987,12 +1047,12 @@ export class StaticSitesImpl implements StaticSites { } } - private async *getUserProvidedFunctionAppsForStaticSitePagingAll( + private async *listStaticSiteCustomDomainsPagingAll( resourceGroupName: string, name: string, - options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams - ): AsyncIterableIterator { - for await (const page of this.getUserProvidedFunctionAppsForStaticSitePagingPage( + options?: StaticSitesListStaticSiteCustomDomainsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listStaticSiteCustomDomainsPagingPage( resourceGroupName, name, options @@ -1002,17 +1062,17 @@ export class StaticSitesImpl implements StaticSites { } /** - * Returns details of all backends linked to a static site + * Returns overviews of database connections for a static site * @param resourceGroupName Name of the resource group to which the resource belongs. * @param name Name of the static site * @param options The options parameters. */ - public listLinkedBackends( + public listDatabaseConnections( resourceGroupName: string, name: string, - options?: StaticSitesGetLinkedBackendsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.getLinkedBackendsPagingAll( + options?: StaticSitesGetDatabaseConnectionsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getDatabaseConnectionsPagingAll( resourceGroupName, name, options @@ -1028,7 +1088,7 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.getLinkedBackendsPagingPage( + return this.getDatabaseConnectionsPagingPage( resourceGroupName, name, options, @@ -1038,23 +1098,27 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *getLinkedBackendsPagingPage( + private async *getDatabaseConnectionsPagingPage( resourceGroupName: string, name: string, - options?: StaticSitesGetLinkedBackendsOptionalParams, + options?: StaticSitesGetDatabaseConnectionsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesGetLinkedBackendsResponse; + ): AsyncIterableIterator { + let result: StaticSitesGetDatabaseConnectionsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._getLinkedBackends(resourceGroupName, name, options); + result = await this._getDatabaseConnections( + resourceGroupName, + name, + options + ); let page = result.value || []; continuationToken = result.nextLink; setContinuationToken(page, continuationToken); yield page; } while (continuationToken) { - result = await this._getLinkedBackendsNext( + result = await this._getDatabaseConnectionsNext( resourceGroupName, name, continuationToken, @@ -1067,12 +1131,12 @@ export class StaticSitesImpl implements StaticSites { } } - private async *getLinkedBackendsPagingAll( + private async *getDatabaseConnectionsPagingAll( resourceGroupName: string, name: string, - options?: StaticSitesGetLinkedBackendsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.getLinkedBackendsPagingPage( + options?: StaticSitesGetDatabaseConnectionsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getDatabaseConnectionsPagingPage( resourceGroupName, name, options @@ -1082,22 +1146,19 @@ export class StaticSitesImpl implements StaticSites { } /** - * Returns details of all backends linked to a static site build + * Description for Gets the functions of a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site - * @param environmentName The stage site identifier + * @param name Name of the static site. * @param options The options parameters. */ - public listLinkedBackendsForBuild( + public listStaticSiteFunctions( resourceGroupName: string, name: string, - environmentName: string, - options?: StaticSitesGetLinkedBackendsForBuildOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.getLinkedBackendsForBuildPagingAll( + options?: StaticSitesListStaticSiteFunctionsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listStaticSiteFunctionsPagingAll( resourceGroupName, name, - environmentName, options ); return { @@ -1111,10 +1172,9 @@ export class StaticSitesImpl implements StaticSites { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.getLinkedBackendsForBuildPagingPage( + return this.listStaticSiteFunctionsPagingPage( resourceGroupName, name, - environmentName, options, settings ); @@ -1122,20 +1182,18 @@ export class StaticSitesImpl implements StaticSites { }; } - private async *getLinkedBackendsForBuildPagingPage( + private async *listStaticSiteFunctionsPagingPage( resourceGroupName: string, name: string, - environmentName: string, - options?: StaticSitesGetLinkedBackendsForBuildOptionalParams, + options?: StaticSitesListStaticSiteFunctionsOptionalParams, settings?: PageSettings - ): AsyncIterableIterator { - let result: StaticSitesGetLinkedBackendsForBuildResponse; + ): AsyncIterableIterator { + let result: StaticSitesListStaticSiteFunctionsResponse; let continuationToken = settings?.continuationToken; if (!continuationToken) { - result = await this._getLinkedBackendsForBuild( + result = await this._listStaticSiteFunctions( resourceGroupName, name, - environmentName, options ); let page = result.value || []; @@ -1144,10 +1202,9 @@ export class StaticSitesImpl implements StaticSites { yield page; } while (continuationToken) { - result = await this._getLinkedBackendsForBuildNext( + result = await this._listStaticSiteFunctionsNext( resourceGroupName, name, - environmentName, continuationToken, options ); @@ -1158,16 +1215,14 @@ export class StaticSitesImpl implements StaticSites { } } - private async *getLinkedBackendsForBuildPagingAll( + private async *listStaticSiteFunctionsPagingAll( resourceGroupName: string, name: string, - environmentName: string, - options?: StaticSitesGetLinkedBackendsForBuildOptionalParams - ): AsyncIterableIterator { - for await (const page of this.getLinkedBackendsForBuildPagingPage( + options?: StaticSitesListStaticSiteFunctionsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listStaticSiteFunctionsPagingPage( resourceGroupName, name, - environmentName, options )) { yield* page; @@ -1175,19 +1230,444 @@ export class StaticSitesImpl implements StaticSites { } /** - * Description for Generates a preview workflow file for the static site - * @param location Location where you plan to create the static site. - * @param staticSitesWorkflowPreviewRequest A JSON representation of the - * StaticSitesWorkflowPreviewRequest properties. See example. + * Description for Gets the list of private endpoint connections associated with a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. * @param options The options parameters. */ - previewWorkflow( - location: string, - staticSitesWorkflowPreviewRequest: StaticSitesWorkflowPreviewRequest, - options?: StaticSitesPreviewWorkflowOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { location, staticSitesWorkflowPreviewRequest, options }, + public listPrivateEndpointConnectionList( + resourceGroupName: string, + name: string, + options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getPrivateEndpointConnectionListPagingAll( + resourceGroupName, + name, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.getPrivateEndpointConnectionListPagingPage( + resourceGroupName, + name, + options, + settings + ); + } + }; + } + + private async *getPrivateEndpointConnectionListPagingPage( + resourceGroupName: string, + name: string, + options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: StaticSitesGetPrivateEndpointConnectionListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._getPrivateEndpointConnectionList( + resourceGroupName, + name, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._getPrivateEndpointConnectionListNext( + resourceGroupName, + name, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *getPrivateEndpointConnectionListPagingAll( + resourceGroupName: string, + name: string, + options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getPrivateEndpointConnectionListPagingPage( + resourceGroupName, + name, + options + )) { + yield* page; + } + } + + /** + * Returns details of database connections for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + public listDatabaseConnectionsWithDetails( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getDatabaseConnectionsWithDetailsPagingAll( + resourceGroupName, + name, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.getDatabaseConnectionsWithDetailsPagingPage( + resourceGroupName, + name, + options, + settings + ); + } + }; + } + + private async *getDatabaseConnectionsWithDetailsPagingPage( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: StaticSitesGetDatabaseConnectionsWithDetailsResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._getDatabaseConnectionsWithDetails( + resourceGroupName, + name, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._getDatabaseConnectionsWithDetailsNext( + resourceGroupName, + name, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *getDatabaseConnectionsWithDetailsPagingAll( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getDatabaseConnectionsWithDetailsPagingPage( + resourceGroupName, + name, + options + )) { + yield* page; + } + } + + /** + * Description for Gets the details of the user provided function apps registered with a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param options The options parameters. + */ + public listUserProvidedFunctionAppsForStaticSite( + resourceGroupName: string, + name: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getUserProvidedFunctionAppsForStaticSitePagingAll( + resourceGroupName, + name, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.getUserProvidedFunctionAppsForStaticSitePagingPage( + resourceGroupName, + name, + options, + settings + ); + } + }; + } + + private async *getUserProvidedFunctionAppsForStaticSitePagingPage( + resourceGroupName: string, + name: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: StaticSitesGetUserProvidedFunctionAppsForStaticSiteResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._getUserProvidedFunctionAppsForStaticSite( + resourceGroupName, + name, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._getUserProvidedFunctionAppsForStaticSiteNext( + resourceGroupName, + name, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *getUserProvidedFunctionAppsForStaticSitePagingAll( + resourceGroupName: string, + name: string, + options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getUserProvidedFunctionAppsForStaticSitePagingPage( + resourceGroupName, + name, + options + )) { + yield* page; + } + } + + /** + * Returns details of all backends linked to a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + public listLinkedBackends( + resourceGroupName: string, + name: string, + options?: StaticSitesGetLinkedBackendsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getLinkedBackendsPagingAll( + resourceGroupName, + name, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.getLinkedBackendsPagingPage( + resourceGroupName, + name, + options, + settings + ); + } + }; + } + + private async *getLinkedBackendsPagingPage( + resourceGroupName: string, + name: string, + options?: StaticSitesGetLinkedBackendsOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: StaticSitesGetLinkedBackendsResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._getLinkedBackends(resourceGroupName, name, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._getLinkedBackendsNext( + resourceGroupName, + name, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *getLinkedBackendsPagingAll( + resourceGroupName: string, + name: string, + options?: StaticSitesGetLinkedBackendsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getLinkedBackendsPagingPage( + resourceGroupName, + name, + options + )) { + yield* page; + } + } + + /** + * Returns details of all backends linked to a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier + * @param options The options parameters. + */ + public listLinkedBackendsForBuild( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetLinkedBackendsForBuildOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.getLinkedBackendsForBuildPagingAll( + resourceGroupName, + name, + environmentName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.getLinkedBackendsForBuildPagingPage( + resourceGroupName, + name, + environmentName, + options, + settings + ); + } + }; + } + + private async *getLinkedBackendsForBuildPagingPage( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetLinkedBackendsForBuildOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: StaticSitesGetLinkedBackendsForBuildResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._getLinkedBackendsForBuild( + resourceGroupName, + name, + environmentName, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._getLinkedBackendsForBuildNext( + resourceGroupName, + name, + environmentName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *getLinkedBackendsForBuildPagingAll( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetLinkedBackendsForBuildOptionalParams + ): AsyncIterableIterator { + for await (const page of this.getLinkedBackendsForBuildPagingPage( + resourceGroupName, + name, + environmentName, + options + )) { + yield* page; + } + } + + /** + * Description for Generates a preview workflow file for the static site + * @param location Location where you plan to create the static site. + * @param staticSitesWorkflowPreviewRequest A JSON representation of the + * StaticSitesWorkflowPreviewRequest properties. See example. + * @param options The options parameters. + */ + previewWorkflow( + location: string, + staticSitesWorkflowPreviewRequest: StaticSitesWorkflowPreviewRequest, + options?: StaticSitesPreviewWorkflowOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { location, staticSitesWorkflowPreviewRequest, options }, previewWorkflowOperationSpec ); } @@ -1248,8 +1728,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteEnvelope: StaticSiteARMResource, options?: StaticSitesCreateOrUpdateStaticSiteOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesCreateOrUpdateStaticSiteResponse > > { @@ -1259,7 +1739,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -1292,13 +1772,16 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, staticSiteEnvelope, options }, - createOrUpdateStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, staticSiteEnvelope, options }, + spec: createOrUpdateStaticSiteOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesCreateOrUpdateStaticSiteResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1338,14 +1821,14 @@ export class StaticSitesImpl implements StaticSites { resourceGroupName: string, name: string, options?: StaticSitesDeleteStaticSiteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -1378,13 +1861,13 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - deleteStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: deleteStaticSiteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1548,14 +2031,14 @@ export class StaticSitesImpl implements StaticSites { name: string, environmentName: string, options?: StaticSitesDeleteStaticSiteBuildOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -1588,13 +2071,13 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, environmentName, options }, - deleteStaticSiteBuildOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, environmentName, options }, + spec: deleteStaticSiteBuildOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1604,66 +2087,228 @@ export class StaticSitesImpl implements StaticSites { /** * Description for Deletes a static site build. * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site. + * @param name Name of the static site. + * @param environmentName The stage site identifier. + * @param options The options parameters. + */ + async beginDeleteStaticSiteBuildAndWait( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesDeleteStaticSiteBuildOptionalParams + ): Promise { + const poller = await this.beginDeleteStaticSiteBuild( + resourceGroupName, + name, + environmentName, + options + ); + return poller.pollUntilDone(); + } + + /** + * Description for Creates or updates the app settings of a static site build. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param environmentName The stage site identifier. + * @param appSettings The dictionary containing the static site app settings to update. + * @param options The options parameters. + */ + createOrUpdateStaticSiteBuildAppSettings( + resourceGroupName: string, + name: string, + environmentName: string, + appSettings: StringDictionary, + options?: StaticSitesCreateOrUpdateStaticSiteBuildAppSettingsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, appSettings, options }, + createOrUpdateStaticSiteBuildAppSettingsOperationSpec + ); + } + + /** + * Description for Creates or updates the function app settings of a static site build. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param environmentName The stage site identifier. + * @param appSettings The dictionary containing the static site function app settings to update. + * @param options The options parameters. + */ + createOrUpdateStaticSiteBuildFunctionAppSettings( + resourceGroupName: string, + name: string, + environmentName: string, + appSettings: StringDictionary, + options?: StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOptionalParams + ): Promise< + StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse + > { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, appSettings, options }, + createOrUpdateStaticSiteBuildFunctionAppSettingsOperationSpec + ); + } + + /** + * Returns overviews of database connections for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param options The options parameters. + */ + private _getBuildDatabaseConnections( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, options }, + getBuildDatabaseConnectionsOperationSpec + ); + } + + /** + * Returns overview of a database connection for a static site build by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + options?: StaticSitesGetBuildDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + environmentName, + databaseConnectionName, + options + }, + getBuildDatabaseConnectionOperationSpec + ); + } + + /** + * Description for Create or update a database connection for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + createOrUpdateBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnection, + options?: StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope, + options + }, + createOrUpdateBuildDatabaseConnectionOperationSpec + ); + } + + /** + * Delete a database connection for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. * @param options The options parameters. */ - async beginDeleteStaticSiteBuildAndWait( + deleteBuildDatabaseConnection( resourceGroupName: string, name: string, environmentName: string, - options?: StaticSitesDeleteStaticSiteBuildOptionalParams + databaseConnectionName: string, + options?: StaticSitesDeleteBuildDatabaseConnectionOptionalParams ): Promise { - const poller = await this.beginDeleteStaticSiteBuild( - resourceGroupName, - name, - environmentName, - options + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + environmentName, + databaseConnectionName, + options + }, + deleteBuildDatabaseConnectionOperationSpec ); - return poller.pollUntilDone(); } /** - * Description for Creates or updates the app settings of a static site build. + * Description for Create or update a database connection for a static site build * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site. + * @param name Name of the static site * @param environmentName The stage site identifier. - * @param appSettings The dictionary containing the static site app settings to update. + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties * @param options The options parameters. */ - createOrUpdateStaticSiteBuildAppSettings( + updateBuildDatabaseConnection( resourceGroupName: string, name: string, environmentName: string, - appSettings: StringDictionary, - options?: StaticSitesCreateOrUpdateStaticSiteBuildAppSettingsOptionalParams - ): Promise { + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, + options?: StaticSitesUpdateBuildDatabaseConnectionOptionalParams + ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, environmentName, appSettings, options }, - createOrUpdateStaticSiteBuildAppSettingsOperationSpec + { + resourceGroupName, + name, + environmentName, + databaseConnectionName, + databaseConnectionRequestEnvelope, + options + }, + updateBuildDatabaseConnectionOperationSpec ); } /** - * Description for Creates or updates the function app settings of a static site build. + * Returns details of a database connection for a static site build by name * @param resourceGroupName Name of the resource group to which the resource belongs. - * @param name Name of the static site. + * @param name Name of the static site * @param environmentName The stage site identifier. - * @param appSettings The dictionary containing the static site function app settings to update. + * @param databaseConnectionName Name of the database connection. * @param options The options parameters. */ - createOrUpdateStaticSiteBuildFunctionAppSettings( + getBuildDatabaseConnectionWithDetails( resourceGroupName: string, name: string, environmentName: string, - appSettings: StringDictionary, - options?: StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOptionalParams - ): Promise< - StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse - > { + databaseConnectionName: string, + options?: StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams + ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, environmentName, appSettings, options }, - createOrUpdateStaticSiteBuildFunctionAppSettingsOperationSpec + { + resourceGroupName, + name, + environmentName, + databaseConnectionName, + options + }, + getBuildDatabaseConnectionWithDetailsOperationSpec ); } @@ -1724,6 +2369,25 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * Returns details of database connections for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param options The options parameters. + */ + private _getBuildDatabaseConnectionsWithDetails( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, options }, + getBuildDatabaseConnectionsWithDetailsOperationSpec + ); + } + /** * Description for Gets the details of the user provided function apps registered with a static site * build @@ -1784,8 +2448,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse >, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse @@ -1797,7 +2461,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -1830,9 +2494,9 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, environmentName, @@ -1840,10 +2504,15 @@ export class StaticSitesImpl implements StaticSites { staticSiteUserProvidedFunctionEnvelope, options }, - registerUserProvidedFunctionAppWithStaticSiteBuildOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: registerUserProvidedFunctionAppWithStaticSiteBuildOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse, + OperationState< + StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -1917,14 +2586,14 @@ export class StaticSitesImpl implements StaticSites { environmentName: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -1957,19 +2626,19 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, environmentName, staticSiteZipDeploymentEnvelope, options }, - createZipDeploymentForStaticSiteBuildOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: createZipDeploymentForStaticSiteBuildOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2021,6 +2690,63 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * Description for Gets the basic auth properties for a static site as a collection. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param options The options parameters. + */ + private _listBasicAuth( + resourceGroupName: string, + name: string, + options?: StaticSitesListBasicAuthOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + listBasicAuthOperationSpec + ); + } + + /** + * Description for Gets the basic auth properties for a static site. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param basicAuthName name of the basic auth entry. + * @param options The options parameters. + */ + getBasicAuth( + resourceGroupName: string, + name: string, + basicAuthName: BasicAuthName, + options?: StaticSitesGetBasicAuthOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, basicAuthName, options }, + getBasicAuthOperationSpec + ); + } + + /** + * Description for Adds or updates basic auth for a static site. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param basicAuthName name of the basic auth entry. + * @param basicAuthEnvelope A JSON representation of the basic auth properties. + * @param options The options parameters. + */ + createOrUpdateBasicAuth( + resourceGroupName: string, + name: string, + basicAuthName: BasicAuthName, + basicAuthEnvelope: StaticSiteBasicAuthPropertiesARMResource, + options?: StaticSitesCreateOrUpdateBasicAuthOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, basicAuthName, basicAuthEnvelope, options }, + createOrUpdateBasicAuthOperationSpec + ); + } + /** * Description for Creates or updates the function app settings of a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -2117,10 +2843,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesCreateOrUpdateStaticSiteCustomDomainOptionalParams ): Promise< - PollerLike< - PollOperationState< - StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse - >, + SimplePollerLike< + OperationState, StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse > > { @@ -2130,7 +2854,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2163,19 +2887,22 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, domainName, staticSiteCustomDomainRequestPropertiesEnvelope, options }, - createOrUpdateStaticSiteCustomDomainOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: createOrUpdateStaticSiteCustomDomainOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2221,14 +2948,14 @@ export class StaticSitesImpl implements StaticSites { name: string, domainName: string, options?: StaticSitesDeleteStaticSiteCustomDomainOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2261,13 +2988,13 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, domainName, options }, - deleteStaticSiteCustomDomainOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, domainName, options }, + spec: deleteStaticSiteCustomDomainOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2311,14 +3038,14 @@ export class StaticSitesImpl implements StaticSites { domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2351,19 +3078,19 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, domainName, staticSiteCustomDomainRequestPropertiesEnvelope, options }, - validateCustomDomainCanBeAddedToStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: validateCustomDomainCanBeAddedToStaticSiteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2396,6 +3123,136 @@ export class StaticSitesImpl implements StaticSites { return poller.pollUntilDone(); } + /** + * Returns overviews of database connections for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + private _getDatabaseConnections( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + getDatabaseConnectionsOperationSpec + ); + } + + /** + * Returns overview of a database connection for a static site by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesGetDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, databaseConnectionName, options }, + getDatabaseConnectionOperationSpec + ); + } + + /** + * Description for Create or update a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + createOrUpdateDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnection, + options?: StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope, + options + }, + createOrUpdateDatabaseConnectionOperationSpec + ); + } + + /** + * Delete a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + deleteDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesDeleteDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, databaseConnectionName, options }, + deleteDatabaseConnectionOperationSpec + ); + } + + /** + * Description for Create or update a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + updateDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, + options?: StaticSitesUpdateDatabaseConnectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + databaseConnectionName, + databaseConnectionRequestEnvelope, + options + }, + updateDatabaseConnectionOperationSpec + ); + } + + /** + * Returns details of a database connection for a static site by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getDatabaseConnectionWithDetails( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesGetDatabaseConnectionWithDetailsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, databaseConnectionName, options }, + getDatabaseConnectionWithDetailsOperationSpec + ); + } + /** * Description for Detaches a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -2406,14 +3263,14 @@ export class StaticSitesImpl implements StaticSites { resourceGroupName: string, name: string, options?: StaticSitesDetachStaticSiteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2446,13 +3303,13 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - detachStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: detachStaticSiteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2614,8 +3471,8 @@ export class StaticSitesImpl implements StaticSites { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesApproveOrRejectPrivateEndpointConnectionResponse >, StaticSitesApproveOrRejectPrivateEndpointConnectionResponse @@ -2627,7 +3484,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2660,19 +3517,24 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, privateEndpointWrapper, options }, - approveOrRejectPrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: approveOrRejectPrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesApproveOrRejectPrivateEndpointConnectionResponse, + OperationState< + StaticSitesApproveOrRejectPrivateEndpointConnectionResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2717,8 +3579,8 @@ export class StaticSitesImpl implements StaticSites { privateEndpointConnectionName: string, options?: StaticSitesDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesDeletePrivateEndpointConnectionResponse > > { @@ -2728,7 +3590,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2761,13 +3623,16 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, privateEndpointConnectionName, options }, - deletePrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, options }, + spec: deletePrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesDeletePrivateEndpointConnectionResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -2832,6 +3697,23 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * Returns details of database connections for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + private _getDatabaseConnectionsWithDetails( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + getDatabaseConnectionsWithDetailsOperationSpec + ); + } + /** * Description for Gets the details of the user provided function apps registered with a static site * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -2884,8 +3766,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse >, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse @@ -2897,7 +3779,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -2930,19 +3812,24 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, functionAppName, staticSiteUserProvidedFunctionEnvelope, options }, - registerUserProvidedFunctionAppWithStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: registerUserProvidedFunctionAppWithStaticSiteOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse, + OperationState< + StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3007,14 +3894,14 @@ export class StaticSitesImpl implements StaticSites { name: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3047,13 +3934,18 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, staticSiteZipDeploymentEnvelope, options }, - createZipDeploymentForStaticSiteOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + name, + staticSiteZipDeploymentEnvelope, + options + }, + spec: createZipDeploymentForStaticSiteOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3098,14 +3990,14 @@ export class StaticSitesImpl implements StaticSites { linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3138,19 +4030,19 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, linkedBackendName, staticSiteLinkedBackendEnvelope, options }, - validateBackendOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: validateBackendOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3200,14 +4092,14 @@ export class StaticSitesImpl implements StaticSites { linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendForBuildOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3240,9 +4132,9 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, environmentName, @@ -3250,10 +4142,10 @@ export class StaticSitesImpl implements StaticSites { staticSiteLinkedBackendEnvelope, options }, - validateBackendForBuildOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: validateBackendForBuildOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3360,8 +4252,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesLinkBackendResponse > > { @@ -3371,7 +4263,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3404,19 +4296,22 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, linkedBackendName, staticSiteLinkedBackendEnvelope, options }, - linkBackendOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: linkBackendOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesLinkBackendResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3507,8 +4402,8 @@ export class StaticSitesImpl implements StaticSites { staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendToBuildOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesLinkBackendToBuildResponse > > { @@ -3518,7 +4413,7 @@ export class StaticSitesImpl implements StaticSites { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -3551,9 +4446,9 @@ export class StaticSitesImpl implements StaticSites { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, environmentName, @@ -3561,10 +4456,13 @@ export class StaticSitesImpl implements StaticSites { staticSiteLinkedBackendEnvelope, options }, - linkBackendToBuildOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: linkBackendToBuildOperationSpec + }); + const poller = await createHttpPoller< + StaticSitesLinkBackendToBuildResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -3689,8 +4587,30 @@ export class StaticSitesImpl implements StaticSites { options?: StaticSitesGetStaticSiteBuildsNextOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, nextLink, options }, - getStaticSiteBuildsNextOperationSpec + { resourceGroupName, name, nextLink, options }, + getStaticSiteBuildsNextOperationSpec + ); + } + + /** + * GetBuildDatabaseConnectionsNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param nextLink The nextLink from the previous successful call to the GetBuildDatabaseConnections + * method. + * @param options The options parameters. + */ + private _getBuildDatabaseConnectionsNext( + resourceGroupName: string, + name: string, + environmentName: string, + nextLink: string, + options?: StaticSitesGetBuildDatabaseConnectionsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, nextLink, options }, + getBuildDatabaseConnectionsNextOperationSpec ); } @@ -3716,6 +4636,28 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * GetBuildDatabaseConnectionsWithDetailsNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param nextLink The nextLink from the previous successful call to the + * GetBuildDatabaseConnectionsWithDetails method. + * @param options The options parameters. + */ + private _getBuildDatabaseConnectionsWithDetailsNext( + resourceGroupName: string, + name: string, + environmentName: string, + nextLink: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, environmentName, nextLink, options }, + getBuildDatabaseConnectionsWithDetailsNextOperationSpec + ); + } + /** * GetUserProvidedFunctionAppsForStaticSiteBuildNext * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3740,6 +4682,25 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * ListBasicAuthNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param nextLink The nextLink from the previous successful call to the ListBasicAuth method. + * @param options The options parameters. + */ + private _listBasicAuthNext( + resourceGroupName: string, + name: string, + nextLink: string, + options?: StaticSitesListBasicAuthNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, nextLink, options }, + listBasicAuthNextOperationSpec + ); + } + /** * ListStaticSiteCustomDomainsNext * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3760,6 +4721,25 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * GetDatabaseConnectionsNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param nextLink The nextLink from the previous successful call to the GetDatabaseConnections method. + * @param options The options parameters. + */ + private _getDatabaseConnectionsNext( + resourceGroupName: string, + name: string, + nextLink: string, + options?: StaticSitesGetDatabaseConnectionsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, nextLink, options }, + getDatabaseConnectionsNextOperationSpec + ); + } + /** * ListStaticSiteFunctionsNext * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3800,6 +4780,26 @@ export class StaticSitesImpl implements StaticSites { ); } + /** + * GetDatabaseConnectionsWithDetailsNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param nextLink The nextLink from the previous successful call to the + * GetDatabaseConnectionsWithDetails method. + * @param options The options parameters. + */ + private _getDatabaseConnectionsWithDetailsNext( + resourceGroupName: string, + name: string, + nextLink: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, nextLink, options }, + getDatabaseConnectionsWithDetailsNextOperationSpec + ); + } + /** * GetUserProvidedFunctionAppsForStaticSiteNext * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -4219,6 +5219,152 @@ const createOrUpdateStaticSiteBuildFunctionAppSettingsOperationSpec: coreClient. mediaType: "json", serializer }; +const getBuildDatabaseConnectionsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2 + ], + headerParameters: [Parameters.accept], + serializer +}; +const getBuildDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections/{databaseConnectionName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateBuildDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections/{databaseConnectionName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.databaseConnectionRequestEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteBuildDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections/{databaseConnectionName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; +const updateBuildDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections/{databaseConnectionName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.databaseConnectionRequestEnvelope1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const getBuildDatabaseConnectionWithDetailsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/databaseConnections/{databaseConnectionName}/show", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; const listStaticSiteBuildFunctionsOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/functions", @@ -4288,6 +5434,29 @@ const listStaticSiteBuildFunctionAppSettingsOperationSpec: coreClient.OperationS headerParameters: [Parameters.accept], serializer }; +const getBuildDatabaseConnectionsWithDetailsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/showDatabaseConnections", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName2 + ], + headerParameters: [Parameters.accept], + serializer +}; const getUserProvidedFunctionAppsForStaticSiteBuildOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/builds/{environmentName}/userProvidedFunctionApps", @@ -4406,38 +5575,108 @@ const createZipDeploymentForStaticSiteBuildOperationSpec: coreClient.OperationSp bodyMapper: Mappers.DefaultErrorResponse } }, - requestBody: Parameters.staticSiteZipDeploymentEnvelope, + requestBody: Parameters.staticSiteZipDeploymentEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.environmentName1 + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const createOrUpdateStaticSiteAppSettingsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/config/appsettings", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.StringDictionary + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.appSettings, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listBasicAuthOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/basicAuth", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.StaticSiteBasicAuthPropertiesCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept], + serializer +}; +const getBasicAuthOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/basicAuth/{basicAuthName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.StaticSiteBasicAuthPropertiesARMResource + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.environmentName1 + Parameters.basicAuthName ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", + headerParameters: [Parameters.accept], serializer }; -const createOrUpdateStaticSiteAppSettingsOperationSpec: coreClient.OperationSpec = { +const createOrUpdateBasicAuthOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/config/appsettings", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/basicAuth/{basicAuthName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.StringDictionary + bodyMapper: Mappers.StaticSiteBasicAuthPropertiesARMResource }, default: { bodyMapper: Mappers.DefaultErrorResponse } }, - requestBody: Parameters.appSettings, + requestBody: Parameters.basicAuthEnvelope, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.name, + Parameters.basicAuthName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -4620,6 +5859,146 @@ const validateCustomDomainCanBeAddedToStaticSiteOperationSpec: coreClient.Operat mediaType: "json", serializer }; +const getDatabaseConnectionsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept], + serializer +}; +const getDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections/{databaseConnectionName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections/{databaseConnectionName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.databaseConnectionRequestEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections/{databaseConnectionName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; +const updateDatabaseConnectionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections/{databaseConnectionName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.databaseConnectionRequestEnvelope1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const getDatabaseConnectionWithDetailsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/databaseConnections/{databaseConnectionName}/show", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.databaseConnectionName + ], + headerParameters: [Parameters.accept], + serializer +}; const detachStaticSiteOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/detach", @@ -4916,6 +6295,28 @@ const resetStaticSiteApiKeyOperationSpec: coreClient.OperationSpec = { mediaType: "json", serializer }; +const getDatabaseConnectionsWithDetailsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/showDatabaseConnections", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept], + serializer +}; const getUserProvidedFunctionAppsForStaticSiteOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/userProvidedFunctionApps", @@ -5312,7 +6713,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5332,7 +6732,6 @@ const getStaticSitesByResourceGroupNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5353,7 +6752,6 @@ const listStaticSiteUsersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5376,7 +6774,6 @@ const getStaticSiteBuildsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5387,6 +6784,28 @@ const getStaticSiteBuildsNextOperationSpec: coreClient.OperationSpec = { headerParameters: [Parameters.accept], serializer }; +const getBuildDatabaseConnectionsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink, + Parameters.environmentName2 + ], + headerParameters: [Parameters.accept], + serializer +}; const listStaticSiteBuildFunctionsNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", @@ -5398,7 +6817,6 @@ const listStaticSiteBuildFunctionsNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5410,6 +6828,28 @@ const listStaticSiteBuildFunctionsNextOperationSpec: coreClient.OperationSpec = headerParameters: [Parameters.accept], serializer }; +const getBuildDatabaseConnectionsWithDetailsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink, + Parameters.environmentName2 + ], + headerParameters: [Parameters.accept], + serializer +}; const getUserProvidedFunctionAppsForStaticSiteBuildNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", @@ -5421,7 +6861,6 @@ const getUserProvidedFunctionAppsForStaticSiteBuildNextOperationSpec: coreClient bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5433,6 +6872,27 @@ const getUserProvidedFunctionAppsForStaticSiteBuildNextOperationSpec: coreClient headerParameters: [Parameters.accept], serializer }; +const listBasicAuthNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.StaticSiteBasicAuthPropertiesCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; const listStaticSiteCustomDomainsNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", @@ -5444,7 +6904,27 @@ const listStaticSiteCustomDomainsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const getDatabaseConnectionsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5466,7 +6946,6 @@ const listStaticSiteFunctionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5488,7 +6967,27 @@ const getPrivateEndpointConnectionListNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const getDatabaseConnectionsWithDetailsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DatabaseConnectionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5510,7 +7009,6 @@ const getUserProvidedFunctionAppsForStaticSiteNextOperationSpec: coreClient.Oper bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5532,7 +7030,6 @@ const getLinkedBackendsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -5554,7 +7051,6 @@ const getLinkedBackendsForBuildNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/topLevelDomains.ts b/sdk/appservice/arm-appservice/src/operations/topLevelDomains.ts index b16fe7b5f42f..86aab2407d10 100644 --- a/sdk/appservice/arm-appservice/src/operations/topLevelDomains.ts +++ b/sdk/appservice/arm-appservice/src/operations/topLevelDomains.ts @@ -315,7 +315,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -335,7 +334,6 @@ const listAgreementsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/webApps.ts b/sdk/appservice/arm-appservice/src/operations/webApps.ts index 0c687a6313be..4258f1865721 100644 --- a/sdk/appservice/arm-appservice/src/operations/webApps.ts +++ b/sdk/appservice/arm-appservice/src/operations/webApps.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { Site, WebAppsListNextOptionalParams, @@ -238,6 +242,13 @@ import { WebAppsListWebJobsNextOptionalParams, WebAppsListWebJobsOptionalParams, WebAppsListWebJobsResponse, + WorkflowEnvelope, + WebAppsListInstanceWorkflowsSlotNextOptionalParams, + WebAppsListInstanceWorkflowsSlotOptionalParams, + WebAppsListInstanceWorkflowsSlotResponse, + WebAppsListWorkflowsNextOptionalParams, + WebAppsListWorkflowsOptionalParams, + WebAppsListWorkflowsResponse, WebAppsGetOptionalParams, WebAppsGetResponse, WebAppsCreateOrUpdateOptionalParams, @@ -850,6 +861,16 @@ import { WebAppsUpdateVnetConnectionGatewayResponse, WebAppsGetWebJobOptionalParams, WebAppsGetWebJobResponse, + WebAppsDeployWorkflowArtifactsOptionalParams, + WebAppsDeployWorkflowArtifactsSlotOptionalParams, + WebAppsGetInstanceWorkflowSlotOptionalParams, + WebAppsGetInstanceWorkflowSlotResponse, + WebAppsListWorkflowsConnectionsSlotOptionalParams, + WebAppsListWorkflowsConnectionsSlotResponse, + WebAppsGetWorkflowOptionalParams, + WebAppsGetWorkflowResponse, + WebAppsListWorkflowsConnectionsOptionalParams, + WebAppsListWorkflowsConnectionsResponse, WebAppsListNextResponse, WebAppsListByResourceGroupNextResponse, WebAppsListBackupsNextResponse, @@ -914,7 +935,9 @@ import { WebAppsListTriggeredWebJobsNextResponse, WebAppsListTriggeredWebJobHistoryNextResponse, WebAppsListUsagesNextResponse, - WebAppsListWebJobsNextResponse + WebAppsListWebJobsNextResponse, + WebAppsListInstanceWorkflowsSlotNextResponse, + WebAppsListWorkflowsNextResponse } from "../models"; /// @@ -6759,6 +6782,175 @@ export class WebAppsImpl implements WebApps { } } + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + public listInstanceWorkflowsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListInstanceWorkflowsSlotOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listInstanceWorkflowsSlotPagingAll( + resourceGroupName, + name, + slot, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listInstanceWorkflowsSlotPagingPage( + resourceGroupName, + name, + slot, + options, + settings + ); + } + }; + } + + private async *listInstanceWorkflowsSlotPagingPage( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListInstanceWorkflowsSlotOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: WebAppsListInstanceWorkflowsSlotResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listInstanceWorkflowsSlot( + resourceGroupName, + name, + slot, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listInstanceWorkflowsSlotNext( + resourceGroupName, + name, + slot, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listInstanceWorkflowsSlotPagingAll( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListInstanceWorkflowsSlotOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listInstanceWorkflowsSlotPagingPage( + resourceGroupName, + name, + slot, + options + )) { + yield* page; + } + } + + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + public listWorkflows( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listWorkflowsPagingAll(resourceGroupName, name, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listWorkflowsPagingPage( + resourceGroupName, + name, + options, + settings + ); + } + }; + } + + private async *listWorkflowsPagingPage( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: WebAppsListWorkflowsResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listWorkflows(resourceGroupName, name, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listWorkflowsNext( + resourceGroupName, + name, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listWorkflowsPagingAll( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listWorkflowsPagingPage( + resourceGroupName, + name, + options + )) { + yield* page; + } + } + /** * Description for Get all apps for a subscription. * @param options The options parameters. @@ -6816,8 +7008,8 @@ export class WebAppsImpl implements WebApps { siteEnvelope: Site, options?: WebAppsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateResponse > > { @@ -6827,7 +7019,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -6860,13 +7052,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, siteEnvelope, options }, - createOrUpdateOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, siteEnvelope, options }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -7083,14 +7278,14 @@ export class WebAppsImpl implements WebApps { backupId: string, request: RestoreRequest, options?: WebAppsRestoreOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -7123,13 +7318,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, backupId, request, options }, - restoreOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, backupId, request, options }, + spec: restoreOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -7674,8 +7869,8 @@ export class WebAppsImpl implements WebApps { name: string, options?: WebAppsListPublishingCredentialsOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsListPublishingCredentialsResponse > > { @@ -7685,7 +7880,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -7718,13 +7913,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - listPublishingCredentialsOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: listPublishingCredentialsOperationSpec + }); + const poller = await createHttpPoller< + WebAppsListPublishingCredentialsResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -8093,8 +8291,8 @@ export class WebAppsImpl implements WebApps { deploymentStatusId: string, options?: WebAppsGetProductionSiteDeploymentStatusOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsGetProductionSiteDeploymentStatusResponse > > { @@ -8104,7 +8302,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -8137,13 +8335,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, deploymentStatusId, options }, - getProductionSiteDeploymentStatusOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, deploymentStatusId, options }, + spec: getProductionSiteDeploymentStatusOperationSpec + }); + const poller = await createHttpPoller< + WebAppsGetProductionSiteDeploymentStatusResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -8430,8 +8631,8 @@ export class WebAppsImpl implements WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateMSDeployOperationResponse > > { @@ -8441,7 +8642,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -8474,13 +8675,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, mSDeploy, options }, - createMSDeployOperationOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, mSDeploy, options }, + spec: createMSDeployOperationOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateMSDeployOperationResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -8629,8 +8833,8 @@ export class WebAppsImpl implements WebApps { functionEnvelope: FunctionEnvelope, options?: WebAppsCreateFunctionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateFunctionResponse > > { @@ -8640,7 +8844,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -8673,13 +8877,22 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, functionName, functionEnvelope, options }, - createFunctionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + name, + functionName, + functionEnvelope, + options + }, + spec: createFunctionOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateFunctionResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -9271,8 +9484,8 @@ export class WebAppsImpl implements WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceMSDeployOperationResponse > > { @@ -9282,7 +9495,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -9315,13 +9528,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, instanceId, mSDeploy, options }, - createInstanceMSDeployOperationOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, instanceId, mSDeploy, options }, + spec: createInstanceMSDeployOperationOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateInstanceMSDeployOperationResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -9597,8 +9813,8 @@ export class WebAppsImpl implements WebApps { migrationOptions: StorageMigrationOptions, options?: WebAppsMigrateStorageOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsMigrateStorageResponse > > { @@ -9608,7 +9824,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -9641,13 +9857,22 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { subscriptionName, resourceGroupName, name, migrationOptions, options }, - migrateStorageOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { + subscriptionName, + resourceGroupName, + name, + migrationOptions, + options + }, + spec: migrateStorageOperationSpec + }); + const poller = await createHttpPoller< + WebAppsMigrateStorageResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -9692,8 +9917,8 @@ export class WebAppsImpl implements WebApps { migrationRequestEnvelope: MigrateMySqlRequest, options?: WebAppsMigrateMySqlOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsMigrateMySqlResponse > > { @@ -9703,7 +9928,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -9736,13 +9961,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, migrationRequestEnvelope, options }, - migrateMySqlOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, migrationRequestEnvelope, options }, + spec: migrateMySqlOperationSpec + }); + const poller = await createHttpPoller< + WebAppsMigrateMySqlResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -9936,8 +10164,8 @@ export class WebAppsImpl implements WebApps { name: string, options?: WebAppsStartWebSiteNetworkTraceOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartWebSiteNetworkTraceOperationResponse > > { @@ -9947,7 +10175,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -9980,13 +10208,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - startWebSiteNetworkTraceOperationOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: startWebSiteNetworkTraceOperationOperationSpec + }); + const poller = await createHttpPoller< + WebAppsStartWebSiteNetworkTraceOperationResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -10326,10 +10557,8 @@ export class WebAppsImpl implements WebApps { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< - WebAppsApproveOrRejectPrivateEndpointConnectionResponse - >, + SimplePollerLike< + OperationState, WebAppsApproveOrRejectPrivateEndpointConnectionResponse > > { @@ -10339,7 +10568,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -10372,19 +10601,22 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, privateEndpointWrapper, options }, - approveOrRejectPrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: approveOrRejectPrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + WebAppsApproveOrRejectPrivateEndpointConnectionResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -10429,8 +10661,8 @@ export class WebAppsImpl implements WebApps { privateEndpointConnectionName: string, options?: WebAppsDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsDeletePrivateEndpointConnectionResponse > > { @@ -10440,7 +10672,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -10473,13 +10705,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, privateEndpointConnectionName, options }, - deletePrivateEndpointConnectionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, options }, + spec: deletePrivateEndpointConnectionOperationSpec + }); + const poller = await createHttpPoller< + WebAppsDeletePrivateEndpointConnectionResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -10813,14 +11048,14 @@ export class WebAppsImpl implements WebApps { name: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -10853,13 +11088,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, request, options }, - restoreFromBackupBlobOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, request, options }, + spec: restoreFromBackupBlobOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -10900,14 +11135,14 @@ export class WebAppsImpl implements WebApps { name: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -10940,13 +11175,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, restoreRequest, options }, - restoreFromDeletedAppOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, restoreRequest, options }, + spec: restoreFromDeletedAppOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -10988,14 +11223,14 @@ export class WebAppsImpl implements WebApps { name: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -11028,13 +11263,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, restoreRequest, options }, - restoreSnapshotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, restoreRequest, options }, + spec: restoreSnapshotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -11113,8 +11348,8 @@ export class WebAppsImpl implements WebApps { siteExtensionId: string, options?: WebAppsInstallSiteExtensionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsInstallSiteExtensionResponse > > { @@ -11124,7 +11359,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -11157,13 +11392,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, siteExtensionId, options }, - installSiteExtensionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, siteExtensionId, options }, + spec: installSiteExtensionOperationSpec + }); + const poller = await createHttpPoller< + WebAppsInstallSiteExtensionResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -11265,8 +11503,8 @@ export class WebAppsImpl implements WebApps { siteEnvelope: Site, options?: WebAppsCreateOrUpdateSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSlotResponse > > { @@ -11276,7 +11514,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -11309,13 +11547,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, siteEnvelope, options }, - createOrUpdateSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, siteEnvelope, options }, + spec: createOrUpdateSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateOrUpdateSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -11563,14 +11804,14 @@ export class WebAppsImpl implements WebApps { slot: string, request: RestoreRequest, options?: WebAppsRestoreSlotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -11603,13 +11844,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, backupId, slot, request, options }, - restoreSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, backupId, slot, request, options }, + spec: restoreSlotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -12246,8 +12487,8 @@ export class WebAppsImpl implements WebApps { slot: string, options?: WebAppsListPublishingCredentialsSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsListPublishingCredentialsSlotResponse > > { @@ -12257,7 +12498,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -12290,13 +12531,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, options }, - listPublishingCredentialsSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, options }, + spec: listPublishingCredentialsSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsListPublishingCredentialsSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -12678,8 +12922,8 @@ export class WebAppsImpl implements WebApps { deploymentStatusId: string, options?: WebAppsGetSlotSiteDeploymentStatusSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsGetSlotSiteDeploymentStatusSlotResponse > > { @@ -12689,7 +12933,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -12722,13 +12966,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, deploymentStatusId, options }, - getSlotSiteDeploymentStatusSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, deploymentStatusId, options }, + spec: getSlotSiteDeploymentStatusSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsGetSlotSiteDeploymentStatusSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -13058,8 +13305,8 @@ export class WebAppsImpl implements WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateMSDeployOperationSlotResponse > > { @@ -13069,7 +13316,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -13102,13 +13349,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, mSDeploy, options }, - createMSDeployOperationSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, mSDeploy, options }, + spec: createMSDeployOperationSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateMSDeployOperationSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -13235,8 +13485,8 @@ export class WebAppsImpl implements WebApps { functionEnvelope: FunctionEnvelope, options?: WebAppsCreateInstanceFunctionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceFunctionSlotResponse > > { @@ -13246,7 +13496,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -13279,9 +13529,9 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, functionName, @@ -13289,10 +13539,13 @@ export class WebAppsImpl implements WebApps { functionEnvelope, options }, - createInstanceFunctionSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: createInstanceFunctionSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateInstanceFunctionSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -13970,8 +14223,8 @@ export class WebAppsImpl implements WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceMSDeployOperationSlotResponse > > { @@ -13981,7 +14234,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -14014,13 +14267,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, instanceId, mSDeploy, options }, - createInstanceMSDeployOperationSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, instanceId, mSDeploy, options }, + spec: createInstanceMSDeployOperationSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateInstanceMSDeployOperationSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -14512,8 +14768,8 @@ export class WebAppsImpl implements WebApps { slot: string, options?: WebAppsStartWebSiteNetworkTraceOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartWebSiteNetworkTraceOperationSlotResponse > > { @@ -14523,7 +14779,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -14556,13 +14812,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, options }, - startWebSiteNetworkTraceOperationSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, options }, + spec: startWebSiteNetworkTraceOperationSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsStartWebSiteNetworkTraceOperationSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -14962,8 +15221,8 @@ export class WebAppsImpl implements WebApps { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse >, WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse @@ -14975,7 +15234,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15008,9 +15267,9 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, privateEndpointConnectionName, @@ -15018,10 +15277,15 @@ export class WebAppsImpl implements WebApps { privateEndpointWrapper, options }, - approveOrRejectPrivateEndpointConnectionSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: approveOrRejectPrivateEndpointConnectionSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse, + OperationState< + WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse + > + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15071,8 +15335,8 @@ export class WebAppsImpl implements WebApps { slot: string, options?: WebAppsDeletePrivateEndpointConnectionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsDeletePrivateEndpointConnectionSlotResponse > > { @@ -15082,7 +15346,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15115,13 +15379,22 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, privateEndpointConnectionName, slot, options }, - deletePrivateEndpointConnectionSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + name, + privateEndpointConnectionName, + slot, + options + }, + spec: deletePrivateEndpointConnectionSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsDeletePrivateEndpointConnectionSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15506,14 +15779,14 @@ export class WebAppsImpl implements WebApps { slot: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobSlotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15546,13 +15819,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, request, options }, - restoreFromBackupBlobSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, request, options }, + spec: restoreFromBackupBlobSlotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15599,14 +15872,14 @@ export class WebAppsImpl implements WebApps { slot: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppSlotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15639,13 +15912,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, restoreRequest, options }, - restoreFromDeletedAppSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, restoreRequest, options }, + spec: restoreFromDeletedAppSlotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15692,14 +15965,14 @@ export class WebAppsImpl implements WebApps { slot: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotSlotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15732,13 +16005,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, restoreRequest, options }, - restoreSnapshotSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, restoreRequest, options }, + spec: restoreSnapshotSlotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15829,8 +16102,8 @@ export class WebAppsImpl implements WebApps { slot: string, options?: WebAppsInstallSiteExtensionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsInstallSiteExtensionSlotResponse > > { @@ -15840,7 +16113,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -15873,13 +16146,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, siteExtensionId, slot, options }, - installSiteExtensionSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, siteExtensionId, slot, options }, + spec: installSiteExtensionSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsInstallSiteExtensionSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -15971,14 +16247,14 @@ export class WebAppsImpl implements WebApps { slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -16011,13 +16287,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, slotSwapEntity, options }, - swapSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, slotSwapEntity, options }, + spec: swapSlotOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -16124,8 +16400,8 @@ export class WebAppsImpl implements WebApps { siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSourceControlSlotResponse > > { @@ -16135,7 +16411,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -16168,13 +16444,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, siteSourceControl, options }, - createOrUpdateSourceControlSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, siteSourceControl, options }, + spec: createOrUpdateSourceControlSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateOrUpdateSourceControlSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -16282,8 +16561,8 @@ export class WebAppsImpl implements WebApps { slot: string, options?: WebAppsStartNetworkTraceSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartNetworkTraceSlotResponse > > { @@ -16293,7 +16572,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -16326,13 +16605,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slot, options }, - startNetworkTraceSlotOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slot, options }, + spec: startNetworkTraceSlotOperationSpec + }); + const poller = await createHttpPoller< + WebAppsStartNetworkTraceSlotResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -16869,14 +17151,14 @@ export class WebAppsImpl implements WebApps { name: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotWithProductionOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -16909,13 +17191,13 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, slotSwapEntity, options }, - swapSlotWithProductionOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, slotSwapEntity, options }, + spec: swapSlotWithProductionOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -17008,8 +17290,8 @@ export class WebAppsImpl implements WebApps { siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSourceControlResponse > > { @@ -17019,7 +17301,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -17052,13 +17334,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, siteSourceControl, options }, - createOrUpdateSourceControlOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, siteSourceControl, options }, + spec: createOrUpdateSourceControlOperationSpec + }); + const poller = await createHttpPoller< + WebAppsCreateOrUpdateSourceControlResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -17151,8 +17436,8 @@ export class WebAppsImpl implements WebApps { name: string, options?: WebAppsStartNetworkTraceOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartNetworkTraceResponse > > { @@ -17162,7 +17447,7 @@ export class WebAppsImpl implements WebApps { ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -17195,13 +17480,16 @@ export class WebAppsImpl implements WebApps { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, options }, - startNetworkTraceOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, options }, + spec: startNetworkTraceOperationSpec + }); + const poller = await createHttpPoller< + WebAppsStartNetworkTraceResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -17643,11 +17931,159 @@ export class WebAppsImpl implements WebApps { } /** - * ListNext - * @param nextLink The nextLink from the previous successful call to the List method. + * Description for Creates the artifacts for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. * @param options The options parameters. */ - private _listNext( + deployWorkflowArtifacts( + resourceGroupName: string, + name: string, + options?: WebAppsDeployWorkflowArtifactsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + deployWorkflowArtifactsOperationSpec + ); + } + + /** + * Description for Creates the artifacts for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + deployWorkflowArtifactsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsDeployWorkflowArtifactsSlotOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, options }, + deployWorkflowArtifactsSlotOperationSpec + ); + } + + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + private _listInstanceWorkflowsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListInstanceWorkflowsSlotOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, options }, + listInstanceWorkflowsSlotOperationSpec + ); + } + + /** + * Get workflow information by its ID for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param workflowName Workflow name. + * @param options The options parameters. + */ + getInstanceWorkflowSlot( + resourceGroupName: string, + name: string, + slot: string, + workflowName: string, + options?: WebAppsGetInstanceWorkflowSlotOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, workflowName, options }, + getInstanceWorkflowSlotOperationSpec + ); + } + + /** + * Lists logic app's connections for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + listWorkflowsConnectionsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListWorkflowsConnectionsSlotOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, options }, + listWorkflowsConnectionsSlotOperationSpec + ); + } + + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + private _listWorkflows( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + listWorkflowsOperationSpec + ); + } + + /** + * Get workflow information by its ID for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param workflowName Workflow name. + * @param options The options parameters. + */ + getWorkflow( + resourceGroupName: string, + name: string, + workflowName: string, + options?: WebAppsGetWorkflowOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, workflowName, options }, + getWorkflowOperationSpec + ); + } + + /** + * Lists logic app's connections for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + listWorkflowsConnections( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsConnectionsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + listWorkflowsConnectionsOperationSpec + ); + } + + /** + * ListNext + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( nextLink: string, options?: WebAppsListNextOptionalParams ): Promise { @@ -19046,6 +19482,47 @@ export class WebAppsImpl implements WebApps { listWebJobsNextOperationSpec ); } + + /** + * ListInstanceWorkflowsSlotNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param nextLink The nextLink from the previous successful call to the ListInstanceWorkflowsSlot + * method. + * @param options The options parameters. + */ + private _listInstanceWorkflowsSlotNext( + resourceGroupName: string, + name: string, + slot: string, + nextLink: string, + options?: WebAppsListInstanceWorkflowsSlotNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, nextLink, options }, + listInstanceWorkflowsSlotNextOperationSpec + ); + } + + /** + * ListWorkflowsNext + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param nextLink The nextLink from the previous successful call to the ListWorkflows method. + * @param options The options parameters. + */ + private _listWorkflowsNext( + resourceGroupName: string, + name: string, + nextLink: string, + options?: WebAppsListWorkflowsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, nextLink, options }, + listWorkflowsNextOperationSpec + ); + } } // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); @@ -29100,6 +29577,194 @@ const getWebJobOperationSpec: coreClient.OperationSpec = { headerParameters: [Parameters.accept], serializer }; +const deployWorkflowArtifactsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployWorkflowArtifacts", + httpMethod: "POST", + responses: { + 200: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.workflowArtifacts, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deployWorkflowArtifactsSlotOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployWorkflowArtifacts", + httpMethod: "POST", + responses: { + 200: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.workflowArtifacts, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.slot + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listInstanceWorkflowsSlotOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/workflows", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelopeCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.slot + ], + headerParameters: [Parameters.accept], + serializer +}; +const getInstanceWorkflowSlotOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/workflows/{workflowName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelope + }, + 404: { + isError: true + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.slot, + Parameters.workflowName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listWorkflowsConnectionsSlotOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/listWorkflowsConnections", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelope + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.slot + ], + headerParameters: [Parameters.accept], + serializer +}; +const listWorkflowsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/workflows", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelopeCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept], + serializer +}; +const getWorkflowOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/workflows/{workflowName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelope + }, + 404: { + isError: true + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.workflowName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listWorkflowsConnectionsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/listWorkflowsConnections", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelope + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name + ], + headerParameters: [Parameters.accept], + serializer +}; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", @@ -29111,7 +29776,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29131,7 +29795,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.includeSlots], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29152,7 +29815,6 @@ const listBackupsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29174,7 +29836,6 @@ const listBasicPublishingCredentialsPoliciesNextOperationSpec: coreClient.Operat bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29196,7 +29857,6 @@ const listConfigurationsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29218,7 +29878,6 @@ const getAppSettingsKeyVaultReferencesNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29240,7 +29899,6 @@ const getSiteConnectionStringKeyVaultReferencesNextOperationSpec: coreClient.Ope bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29262,7 +29920,6 @@ const listConfigurationSnapshotInfoNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29284,7 +29941,6 @@ const listContinuousWebJobsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29306,7 +29962,6 @@ const listProductionSiteDeploymentStatusesNextOperationSpec: coreClient.Operatio bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29328,7 +29983,6 @@ const listDeploymentsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29350,7 +30004,6 @@ const listDomainOwnershipIdentifiersNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29375,7 +30028,6 @@ const listFunctionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29397,7 +30049,6 @@ const listHostNameBindingsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29419,7 +30070,6 @@ const listInstanceIdentifiersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29444,7 +30094,6 @@ const listInstanceProcessesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29470,7 +30119,6 @@ const listInstanceProcessModulesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29497,7 +30145,6 @@ const listInstanceProcessThreadsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29521,7 +30168,6 @@ const listSiteBackupsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29543,7 +30189,6 @@ const listPerfMonCountersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29565,7 +30210,6 @@ const getPrivateEndpointConnectionListNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29590,7 +30234,6 @@ const listProcessesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29615,7 +30258,6 @@ const listProcessModulesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29641,7 +30283,6 @@ const listProcessThreadsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29664,7 +30305,6 @@ const listPublicCertificatesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29689,7 +30329,6 @@ const listSiteExtensionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29711,7 +30350,6 @@ const listSlotsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29733,7 +30371,6 @@ const listBackupsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29756,7 +30393,6 @@ const listBasicPublishingCredentialsPoliciesSlotNextOperationSpec: coreClient.Op bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29779,7 +30415,6 @@ const listConfigurationsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29802,7 +30437,6 @@ const getAppSettingsKeyVaultReferencesSlotNextOperationSpec: coreClient.Operatio bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29825,7 +30459,6 @@ const getSiteConnectionStringKeyVaultReferencesSlotNextOperationSpec: coreClient bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29848,7 +30481,6 @@ const listConfigurationSnapshotInfoSlotNextOperationSpec: coreClient.OperationSp bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29871,7 +30503,6 @@ const listContinuousWebJobsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29894,7 +30525,6 @@ const listSlotSiteDeploymentStatusesSlotNextOperationSpec: coreClient.OperationS bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29917,7 +30547,6 @@ const listDeploymentsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29940,7 +30569,6 @@ const listDomainOwnershipIdentifiersSlotNextOperationSpec: coreClient.OperationS bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29966,7 +30594,6 @@ const listInstanceFunctionsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -29989,7 +30616,6 @@ const listHostNameBindingsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30012,7 +30638,6 @@ const listInstanceIdentifiersSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30038,7 +30663,6 @@ const listInstanceProcessesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30065,7 +30689,6 @@ const listInstanceProcessModulesSlotNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30093,7 +30716,6 @@ const listInstanceProcessThreadsSlotNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30118,7 +30740,6 @@ const listSiteBackupsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30141,7 +30762,6 @@ const listPerfMonCountersSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30164,7 +30784,6 @@ const getPrivateEndpointConnectionListSlotNextOperationSpec: coreClient.Operatio bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30190,7 +30809,6 @@ const listProcessesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30216,7 +30834,6 @@ const listProcessModulesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30243,7 +30860,6 @@ const listProcessThreadsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30267,7 +30883,6 @@ const listPublicCertificatesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30293,7 +30908,6 @@ const listSiteExtensionsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30316,7 +30930,6 @@ const listSlotDifferencesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30340,7 +30953,6 @@ const listSnapshotsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30363,7 +30975,6 @@ const listSnapshotsFromDRSecondarySlotNextOperationSpec: coreClient.OperationSpe bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30386,7 +30997,6 @@ const listTriggeredWebJobsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30412,7 +31022,6 @@ const listTriggeredWebJobHistorySlotNextOperationSpec: coreClient.OperationSpec bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30436,7 +31045,6 @@ const listUsagesSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30459,7 +31067,6 @@ const listWebJobsSlotNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30482,7 +31089,6 @@ const listSlotDifferencesFromProductionNextOperationSpec: coreClient.OperationSp bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30505,7 +31111,6 @@ const listSnapshotsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30527,7 +31132,6 @@ const listSnapshotsFromDRSecondaryNextOperationSpec: coreClient.OperationSpec = bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30549,7 +31153,6 @@ const listTriggeredWebJobsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30574,7 +31177,6 @@ const listTriggeredWebJobHistoryNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30597,7 +31199,6 @@ const listUsagesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -30619,7 +31220,49 @@ const listWebJobsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const listInstanceWorkflowsSlotNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelopeCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.name, + Parameters.nextLink, + Parameters.slot + ], + headerParameters: [Parameters.accept], + serializer +}; +const listWorkflowsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.WorkflowEnvelopeCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitions.ts b/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitions.ts index 7bbe6e13eb7b..7c01f84ce061 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitions.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitions.ts @@ -452,7 +452,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], @@ -477,7 +477,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName @@ -503,7 +503,7 @@ const listExpressionTracesOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName @@ -522,14 +522,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], @@ -547,14 +546,13 @@ const listExpressionTracesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName diff --git a/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitionsRequestHistories.ts b/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitionsRequestHistories.ts index 3b822c21ff1a..f87b80ead777 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitionsRequestHistories.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowRunActionRepetitionsRequestHistories.ts @@ -283,7 +283,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName @@ -309,7 +309,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName, @@ -329,14 +329,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName diff --git a/sdk/appservice/arm-appservice/src/operations/workflowRunActionScopeRepetitions.ts b/sdk/appservice/arm-appservice/src/operations/workflowRunActionScopeRepetitions.ts index 514ee1d4bf03..33c0953af050 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowRunActionScopeRepetitions.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowRunActionScopeRepetitions.ts @@ -258,7 +258,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], @@ -283,7 +283,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName, Parameters.repetitionName @@ -302,14 +302,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], diff --git a/sdk/appservice/arm-appservice/src/operations/workflowRunActions.ts b/sdk/appservice/arm-appservice/src/operations/workflowRunActions.ts index d8f9876c836a..7bc176cc0ce5 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowRunActions.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowRunActions.ts @@ -398,7 +398,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName ], headerParameters: [Parameters.accept], @@ -422,7 +422,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], @@ -447,7 +447,7 @@ const listExpressionTracesOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], @@ -465,14 +465,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.top1, Parameters.filter1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName ], headerParameters: [Parameters.accept], @@ -489,14 +488,13 @@ const listExpressionTracesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName, Parameters.actionName ], diff --git a/sdk/appservice/arm-appservice/src/operations/workflowRuns.ts b/sdk/appservice/arm-appservice/src/operations/workflowRuns.ts index a7bd4aed6c81..4e96cdc0d8f8 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowRuns.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowRuns.ts @@ -228,7 +228,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer @@ -251,7 +251,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName ], headerParameters: [Parameters.accept], @@ -273,7 +273,7 @@ const cancelOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.runName ], headerParameters: [Parameters.accept], @@ -290,14 +290,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.top1, Parameters.filter1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/appservice/arm-appservice/src/operations/workflowTriggerHistories.ts b/sdk/appservice/arm-appservice/src/operations/workflowTriggerHistories.ts index 61b3d405e5a4..e6e4fc653495 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowTriggerHistories.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowTriggerHistories.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { WorkflowTriggerHistory, WorkflowTriggerHistoriesListNextOptionalParams, @@ -210,14 +214,14 @@ export class WorkflowTriggerHistoriesImpl implements WorkflowTriggerHistories { triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesResubmitOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -250,9 +254,9 @@ export class WorkflowTriggerHistoriesImpl implements WorkflowTriggerHistories { }; }; - const lro = new LroImpl( - sendOperation, - { + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, workflowName, @@ -260,10 +264,10 @@ export class WorkflowTriggerHistoriesImpl implements WorkflowTriggerHistories { historyName, options }, - resubmitOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + spec: resubmitOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -343,7 +347,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], @@ -367,7 +371,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName, Parameters.historyName ], @@ -393,7 +397,7 @@ const resubmitOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName, Parameters.historyName ], @@ -411,14 +415,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.top1, Parameters.filter1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], diff --git a/sdk/appservice/arm-appservice/src/operations/workflowTriggers.ts b/sdk/appservice/arm-appservice/src/operations/workflowTriggers.ts index c42540e123c5..c343ab1261b2 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowTriggers.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowTriggers.ts @@ -13,8 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { WebSiteManagementClient } from "../webSiteManagementClient"; -import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; -import { LroImpl } from "../lroImpl"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { WorkflowTrigger, WorkflowTriggersListNextOptionalParams, @@ -206,14 +210,14 @@ export class WorkflowTriggersImpl implements WorkflowTriggers { workflowName: string, triggerName: string, options?: WorkflowTriggersRunOptionalParams - ): Promise, void>> { + ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ): Promise => { return this.client.sendOperationRequest(args, spec); }; - const sendOperation = async ( + const sendOperationFn = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec ) => { @@ -246,13 +250,13 @@ export class WorkflowTriggersImpl implements WorkflowTriggers { }; }; - const lro = new LroImpl( - sendOperation, - { resourceGroupName, name, workflowName, triggerName, options }, - runOperationSpec - ); - const poller = new LroEngine(lro, { - resumeFrom: options?.resumeFrom, + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, name, workflowName, triggerName, options }, + spec: runOperationSpec + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs }); await poller.poll(); @@ -347,7 +351,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer @@ -370,7 +374,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], @@ -394,7 +398,7 @@ const listCallbackUrlOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], @@ -419,7 +423,7 @@ const runOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], @@ -443,7 +447,7 @@ const getSchemaJsonOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.triggerName ], headerParameters: [Parameters.accept], @@ -460,14 +464,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.top1, Parameters.filter1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/appservice/arm-appservice/src/operations/workflowVersions.ts b/sdk/appservice/arm-appservice/src/operations/workflowVersions.ts index 4e8bfbfc5f80..ba53fc2db9bc 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflowVersions.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflowVersions.ts @@ -206,7 +206,7 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer @@ -229,7 +229,7 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName, + Parameters.workflowName1, Parameters.versionId ], headerParameters: [Parameters.accept], @@ -246,14 +246,13 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.top1], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, Parameters.nextLink, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/appservice/arm-appservice/src/operations/workflows.ts b/sdk/appservice/arm-appservice/src/operations/workflows.ts index ddd3bf17eb65..259a0110c215 100644 --- a/sdk/appservice/arm-appservice/src/operations/workflows.ts +++ b/sdk/appservice/arm-appservice/src/operations/workflows.ts @@ -92,7 +92,7 @@ const regenerateAccessKeyOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -115,7 +115,7 @@ const validateOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.name, - Parameters.workflowName + Parameters.workflowName1 ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceCertificateOrders.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceCertificateOrders.ts index 4c7da7194c98..0ba7079ec92c 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceCertificateOrders.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceCertificateOrders.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { AppServiceCertificateOrder, AppServiceCertificateOrdersListOptionalParams, @@ -111,8 +111,8 @@ export interface AppServiceCertificateOrders { certificateDistinguishedName: AppServiceCertificateOrder, options?: AppServiceCertificateOrdersCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceCertificateOrdersCreateOrUpdateResponse > >; @@ -181,8 +181,8 @@ export interface AppServiceCertificateOrders { keyVaultCertificate: AppServiceCertificateResource, options?: AppServiceCertificateOrdersCreateOrUpdateCertificateOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceCertificateOrdersCreateOrUpdateCertificateResponse >, AppServiceCertificateOrdersCreateOrUpdateCertificateResponse diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceEnvironments.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceEnvironments.ts index 8709e7477500..3e312ae08ca4 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceEnvironments.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServiceEnvironments.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { AppServiceEnvironmentResource, AppServiceEnvironmentsListOptionalParams, @@ -378,8 +378,8 @@ export interface AppServiceEnvironments { hostingEnvironmentEnvelope: AppServiceEnvironmentResource, options?: AppServiceEnvironmentsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateResponse > >; @@ -406,7 +406,7 @@ export interface AppServiceEnvironments { resourceGroupName: string, name: string, options?: AppServiceEnvironmentsDeleteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Delete an App Service Environment. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -553,10 +553,8 @@ export interface AppServiceEnvironments { multiRolePoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateMultiRolePoolOptionalParams ): Promise< - PollerLike< - PollOperationState< - AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse - >, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateMultiRolePoolResponse > >; @@ -607,7 +605,7 @@ export interface AppServiceEnvironments { resourceGroupName: string, name: string, options?: AppServiceEnvironmentsUpgradeOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Initiate an upgrade of an App Service Environment if one is available. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -658,8 +656,8 @@ export interface AppServiceEnvironments { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse >, AppServiceEnvironmentsApproveOrRejectPrivateEndpointConnectionResponse @@ -695,8 +693,8 @@ export interface AppServiceEnvironments { privateEndpointConnectionName: string, options?: AppServiceEnvironmentsDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse >, AppServiceEnvironmentsDeletePrivateEndpointConnectionResponse @@ -765,10 +763,8 @@ export interface AppServiceEnvironments { workerPoolEnvelope: WorkerPoolResource, options?: AppServiceEnvironmentsCreateOrUpdateWorkerPoolOptionalParams ): Promise< - PollerLike< - PollOperationState< - AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse - >, + SimplePollerLike< + OperationState, AppServiceEnvironmentsCreateOrUpdateWorkerPoolResponse > >; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServicePlans.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServicePlans.ts index 4a511c2670a0..6219a6e22de3 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/appServicePlans.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/appServicePlans.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { AppServicePlan, AppServicePlansListOptionalParams, @@ -152,8 +152,8 @@ export interface AppServicePlans { appServicePlan: AppServicePlan, options?: AppServicePlansCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, AppServicePlansCreateOrUpdateResponse > >; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/containerApps.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/containerApps.ts index 82620cbfab63..377bd8cbe91c 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/containerApps.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/containerApps.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { ContainerApp, ContainerAppsListBySubscriptionOptionalParams, @@ -64,8 +64,8 @@ export interface ContainerApps { containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, ContainerAppsCreateOrUpdateResponse > >; @@ -92,7 +92,7 @@ export interface ContainerApps { resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Delete a Container App. * @param resourceGroupName Name of the resource group to which the resource belongs. diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/domains.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/domains.ts index 5afd75680b86..815080772fa6 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/domains.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/domains.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { Domain, DomainsListOptionalParams, @@ -118,8 +118,8 @@ export interface Domains { domain: Domain, options?: DomainsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, DomainsCreateOrUpdateResponse > >; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/kubeEnvironments.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/kubeEnvironments.ts index 680675744ad8..c11588380c4a 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/kubeEnvironments.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/kubeEnvironments.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { KubeEnvironment, KubeEnvironmentsListBySubscriptionOptionalParams, @@ -65,8 +65,8 @@ export interface KubeEnvironments { kubeEnvironmentEnvelope: KubeEnvironment, options?: KubeEnvironmentsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, KubeEnvironmentsCreateOrUpdateResponse > >; @@ -93,7 +93,7 @@ export interface KubeEnvironments { resourceGroupName: string, name: string, options?: KubeEnvironmentsDeleteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Delete a Kubernetes Environment. * @param resourceGroupName Name of the resource group to which the resource belongs. diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/staticSites.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/staticSites.ts index dc24633c3d55..a1e75362c13d 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/staticSites.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/staticSites.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { StaticSiteARMResource, StaticSitesListOptionalParams, @@ -16,15 +16,22 @@ import { StaticSitesListStaticSiteUsersOptionalParams, StaticSiteBuildARMResource, StaticSitesGetStaticSiteBuildsOptionalParams, + DatabaseConnection, + StaticSitesGetBuildDatabaseConnectionsOptionalParams, StaticSiteFunctionOverviewARMResource, StaticSitesListStaticSiteBuildFunctionsOptionalParams, + StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams, StaticSiteUserProvidedFunctionAppARMResource, StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams, + StaticSiteBasicAuthPropertiesARMResource, + StaticSitesListBasicAuthOptionalParams, StaticSiteCustomDomainOverviewARMResource, StaticSitesListStaticSiteCustomDomainsOptionalParams, + StaticSitesGetDatabaseConnectionsOptionalParams, StaticSitesListStaticSiteFunctionsOptionalParams, RemotePrivateEndpointConnectionARMResource, StaticSitesGetPrivateEndpointConnectionListOptionalParams, + StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams, StaticSitesGetUserProvidedFunctionAppsForStaticSiteOptionalParams, StaticSiteLinkedBackendARMResource, StaticSitesGetLinkedBackendsOptionalParams, @@ -51,6 +58,16 @@ import { StaticSitesCreateOrUpdateStaticSiteBuildAppSettingsResponse, StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse, + StaticSitesGetBuildDatabaseConnectionOptionalParams, + StaticSitesGetBuildDatabaseConnectionResponse, + StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams, + StaticSitesCreateOrUpdateBuildDatabaseConnectionResponse, + StaticSitesDeleteBuildDatabaseConnectionOptionalParams, + DatabaseConnectionPatchRequest, + StaticSitesUpdateBuildDatabaseConnectionOptionalParams, + StaticSitesUpdateBuildDatabaseConnectionResponse, + StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams, + StaticSitesGetBuildDatabaseConnectionWithDetailsResponse, StaticSitesListStaticSiteBuildAppSettingsOptionalParams, StaticSitesListStaticSiteBuildAppSettingsResponse, StaticSitesListStaticSiteBuildFunctionAppSettingsOptionalParams, @@ -64,6 +81,11 @@ import { StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams, StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteAppSettingsResponse, + BasicAuthName, + StaticSitesGetBasicAuthOptionalParams, + StaticSitesGetBasicAuthResponse, + StaticSitesCreateOrUpdateBasicAuthOptionalParams, + StaticSitesCreateOrUpdateBasicAuthResponse, StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsOptionalParams, StaticSitesCreateOrUpdateStaticSiteFunctionAppSettingsResponse, StaticSiteUserInvitationRequestResource, @@ -76,6 +98,15 @@ import { StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse, StaticSitesDeleteStaticSiteCustomDomainOptionalParams, StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams, + StaticSitesGetDatabaseConnectionOptionalParams, + StaticSitesGetDatabaseConnectionResponse, + StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams, + StaticSitesCreateOrUpdateDatabaseConnectionResponse, + StaticSitesDeleteDatabaseConnectionOptionalParams, + StaticSitesUpdateDatabaseConnectionOptionalParams, + StaticSitesUpdateDatabaseConnectionResponse, + StaticSitesGetDatabaseConnectionWithDetailsOptionalParams, + StaticSitesGetDatabaseConnectionWithDetailsResponse, StaticSitesDetachStaticSiteOptionalParams, StaticSitesListStaticSiteAppSettingsOptionalParams, StaticSitesListStaticSiteAppSettingsResponse, @@ -159,6 +190,19 @@ export interface StaticSites { name: string, options?: StaticSitesGetStaticSiteBuildsOptionalParams ): PagedAsyncIterableIterator; + /** + * Returns overviews of database connections for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param options The options parameters. + */ + listBuildDatabaseConnections( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets the functions of a particular static site build. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -172,6 +216,19 @@ export interface StaticSites { environmentName: string, options?: StaticSitesListStaticSiteBuildFunctionsOptionalParams ): PagedAsyncIterableIterator; + /** + * Returns details of database connections for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param options The options parameters. + */ + listBuildDatabaseConnectionsWithDetails( + resourceGroupName: string, + name: string, + environmentName: string, + options?: StaticSitesGetBuildDatabaseConnectionsWithDetailsOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets the details of the user provided function apps registered with a static site * build @@ -186,6 +243,17 @@ export interface StaticSites { environmentName: string, options?: StaticSitesGetUserProvidedFunctionAppsForStaticSiteBuildOptionalParams ): PagedAsyncIterableIterator; + /** + * Description for Gets the basic auth properties for a static site as a collection. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param options The options parameters. + */ + listBasicAuth( + resourceGroupName: string, + name: string, + options?: StaticSitesListBasicAuthOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets all static site custom domains for a particular static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -197,6 +265,17 @@ export interface StaticSites { name: string, options?: StaticSitesListStaticSiteCustomDomainsOptionalParams ): PagedAsyncIterableIterator; + /** + * Returns overviews of database connections for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + listDatabaseConnections( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets the functions of a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -219,6 +298,17 @@ export interface StaticSites { name: string, options?: StaticSitesGetPrivateEndpointConnectionListOptionalParams ): PagedAsyncIterableIterator; + /** + * Returns details of database connections for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param options The options parameters. + */ + listDatabaseConnectionsWithDetails( + resourceGroupName: string, + name: string, + options?: StaticSitesGetDatabaseConnectionsWithDetailsOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets the details of the user provided function apps registered with a static site * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -291,8 +381,8 @@ export interface StaticSites { staticSiteEnvelope: StaticSiteARMResource, options?: StaticSitesCreateOrUpdateStaticSiteOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesCreateOrUpdateStaticSiteResponse > >; @@ -320,7 +410,7 @@ export interface StaticSites { resourceGroupName: string, name: string, options?: StaticSitesDeleteStaticSiteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Deletes a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -403,7 +493,7 @@ export interface StaticSites { name: string, environmentName: string, options?: StaticSitesDeleteStaticSiteBuildOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Deletes a static site build. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -449,6 +539,87 @@ export interface StaticSites { ): Promise< StaticSitesCreateOrUpdateStaticSiteBuildFunctionAppSettingsResponse >; + /** + * Returns overview of a database connection for a static site build by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + options?: StaticSitesGetBuildDatabaseConnectionOptionalParams + ): Promise; + /** + * Description for Create or update a database connection for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + createOrUpdateBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnection, + options?: StaticSitesCreateOrUpdateBuildDatabaseConnectionOptionalParams + ): Promise; + /** + * Delete a database connection for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + deleteBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + options?: StaticSitesDeleteBuildDatabaseConnectionOptionalParams + ): Promise; + /** + * Description for Create or update a database connection for a static site build + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + updateBuildDatabaseConnection( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, + options?: StaticSitesUpdateBuildDatabaseConnectionOptionalParams + ): Promise; + /** + * Returns details of a database connection for a static site build by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param environmentName The stage site identifier. + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getBuildDatabaseConnectionWithDetails( + resourceGroupName: string, + name: string, + environmentName: string, + databaseConnectionName: string, + options?: StaticSitesGetBuildDatabaseConnectionWithDetailsOptionalParams + ): Promise; /** * Description for Gets the application settings of a static site build. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -509,8 +680,8 @@ export interface StaticSites { staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse >, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteBuildResponse @@ -566,7 +737,7 @@ export interface StaticSites { environmentName: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteBuildOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Deploys zipped content to a specific environment of a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -596,6 +767,34 @@ export interface StaticSites { appSettings: StringDictionary, options?: StaticSitesCreateOrUpdateStaticSiteAppSettingsOptionalParams ): Promise; + /** + * Description for Gets the basic auth properties for a static site. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param basicAuthName name of the basic auth entry. + * @param options The options parameters. + */ + getBasicAuth( + resourceGroupName: string, + name: string, + basicAuthName: BasicAuthName, + options?: StaticSitesGetBasicAuthOptionalParams + ): Promise; + /** + * Description for Adds or updates basic auth for a static site. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site. + * @param basicAuthName name of the basic auth entry. + * @param basicAuthEnvelope A JSON representation of the basic auth properties. + * @param options The options parameters. + */ + createOrUpdateBasicAuth( + resourceGroupName: string, + name: string, + basicAuthName: BasicAuthName, + basicAuthEnvelope: StaticSiteBasicAuthPropertiesARMResource, + options?: StaticSitesCreateOrUpdateBasicAuthOptionalParams + ): Promise; /** * Description for Creates or updates the function app settings of a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -652,10 +851,8 @@ export interface StaticSites { staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesCreateOrUpdateStaticSiteCustomDomainOptionalParams ): Promise< - PollerLike< - PollOperationState< - StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse - >, + SimplePollerLike< + OperationState, StaticSitesCreateOrUpdateStaticSiteCustomDomainResponse > >; @@ -688,7 +885,7 @@ export interface StaticSites { name: string, domainName: string, options?: StaticSitesDeleteStaticSiteCustomDomainOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Deletes a custom domain. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -717,7 +914,7 @@ export interface StaticSites { domainName: string, staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Validates a particular custom domain can be added to a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -734,6 +931,77 @@ export interface StaticSites { staticSiteCustomDomainRequestPropertiesEnvelope: StaticSiteCustomDomainRequestPropertiesARMResource, options?: StaticSitesValidateCustomDomainCanBeAddedToStaticSiteOptionalParams ): Promise; + /** + * Returns overview of a database connection for a static site by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesGetDatabaseConnectionOptionalParams + ): Promise; + /** + * Description for Create or update a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + createOrUpdateDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnection, + options?: StaticSitesCreateOrUpdateDatabaseConnectionOptionalParams + ): Promise; + /** + * Delete a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + deleteDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesDeleteDatabaseConnectionOptionalParams + ): Promise; + /** + * Description for Create or update a database connection for a static site + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param databaseConnectionRequestEnvelope A JSON representation of the database connection request + * properties + * @param options The options parameters. + */ + updateDatabaseConnection( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + databaseConnectionRequestEnvelope: DatabaseConnectionPatchRequest, + options?: StaticSitesUpdateDatabaseConnectionOptionalParams + ): Promise; + /** + * Returns details of a database connection for a static site by name + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Name of the static site + * @param databaseConnectionName Name of the database connection. + * @param options The options parameters. + */ + getDatabaseConnectionWithDetails( + resourceGroupName: string, + name: string, + databaseConnectionName: string, + options?: StaticSitesGetDatabaseConnectionWithDetailsOptionalParams + ): Promise; /** * Description for Detaches a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -744,7 +1012,7 @@ export interface StaticSites { resourceGroupName: string, name: string, options?: StaticSitesDetachStaticSiteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Detaches a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -828,8 +1096,8 @@ export interface StaticSites { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: StaticSitesApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesApproveOrRejectPrivateEndpointConnectionResponse >, StaticSitesApproveOrRejectPrivateEndpointConnectionResponse @@ -863,8 +1131,8 @@ export interface StaticSites { privateEndpointConnectionName: string, options?: StaticSitesDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesDeletePrivateEndpointConnectionResponse > >; @@ -934,8 +1202,8 @@ export interface StaticSites { staticSiteUserProvidedFunctionEnvelope: StaticSiteUserProvidedFunctionAppARMResource, options?: StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse >, StaticSitesRegisterUserProvidedFunctionAppWithStaticSiteResponse @@ -983,7 +1251,7 @@ export interface StaticSites { name: string, staticSiteZipDeploymentEnvelope: StaticSiteZipDeploymentARMResource, options?: StaticSitesCreateZipDeploymentForStaticSiteOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Deploys zipped content to a static site. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -1013,7 +1281,7 @@ export interface StaticSites { linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Validates that a backend can be linked to a static site * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -1047,7 +1315,7 @@ export interface StaticSites { linkedBackendName: string, staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesValidateBackendForBuildOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Validates that a backend can be linked to a static site build * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -1095,8 +1363,8 @@ export interface StaticSites { staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesLinkBackendResponse > >; @@ -1162,8 +1430,8 @@ export interface StaticSites { staticSiteLinkedBackendEnvelope: StaticSiteLinkedBackendARMResource, options?: StaticSitesLinkBackendToBuildOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, StaticSitesLinkBackendToBuildResponse > >; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/webApps.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/webApps.ts index 58c541850952..a2397728435a 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/webApps.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/webApps.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { Site, WebAppsListOptionalParams, @@ -101,6 +101,9 @@ import { WebAppsListTriggeredWebJobHistoryOptionalParams, WebAppsListUsagesOptionalParams, WebAppsListWebJobsOptionalParams, + WorkflowEnvelope, + WebAppsListInstanceWorkflowsSlotOptionalParams, + WebAppsListWorkflowsOptionalParams, WebAppsGetOptionalParams, WebAppsGetResponse, WebAppsCreateOrUpdateOptionalParams, @@ -712,7 +715,17 @@ import { WebAppsUpdateVnetConnectionGatewayOptionalParams, WebAppsUpdateVnetConnectionGatewayResponse, WebAppsGetWebJobOptionalParams, - WebAppsGetWebJobResponse + WebAppsGetWebJobResponse, + WebAppsDeployWorkflowArtifactsOptionalParams, + WebAppsDeployWorkflowArtifactsSlotOptionalParams, + WebAppsGetInstanceWorkflowSlotOptionalParams, + WebAppsGetInstanceWorkflowSlotResponse, + WebAppsListWorkflowsConnectionsSlotOptionalParams, + WebAppsListWorkflowsConnectionsSlotResponse, + WebAppsGetWorkflowOptionalParams, + WebAppsGetWorkflowResponse, + WebAppsListWorkflowsConnectionsOptionalParams, + WebAppsListWorkflowsConnectionsResponse } from "../models"; /// @@ -1568,6 +1581,30 @@ export interface WebApps { name: string, options?: WebAppsListWebJobsOptionalParams ): PagedAsyncIterableIterator; + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + listInstanceWorkflowsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListInstanceWorkflowsSlotOptionalParams + ): PagedAsyncIterableIterator; + /** + * List the workflows for a web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + listWorkflows( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsOptionalParams + ): PagedAsyncIterableIterator; /** * Description for Gets the details of a web, mobile, or API app. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -1594,8 +1631,8 @@ export interface WebApps { siteEnvelope: Site, options?: WebAppsCreateOrUpdateOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateResponse > >; @@ -1735,7 +1772,7 @@ export interface WebApps { backupId: string, request: RestoreRequest, options?: WebAppsRestoreOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a specific backup to another app (or deployment slot, if specified). * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -2051,8 +2088,8 @@ export interface WebApps { name: string, options?: WebAppsListPublishingCredentialsOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsListPublishingCredentialsResponse > >; @@ -2268,8 +2305,8 @@ export interface WebApps { deploymentStatusId: string, options?: WebAppsGetProductionSiteDeploymentStatusOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsGetProductionSiteDeploymentStatusResponse > >; @@ -2438,8 +2475,8 @@ export interface WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateMSDeployOperationResponse > >; @@ -2529,8 +2566,8 @@ export interface WebApps { functionEnvelope: FunctionEnvelope, options?: WebAppsCreateFunctionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateFunctionResponse > >; @@ -2911,8 +2948,8 @@ export interface WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceMSDeployOperationResponse > >; @@ -3049,8 +3086,8 @@ export interface WebApps { migrationOptions: StorageMigrationOptions, options?: WebAppsMigrateStorageOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsMigrateStorageResponse > >; @@ -3082,8 +3119,8 @@ export interface WebApps { migrationRequestEnvelope: MigrateMySqlRequest, options?: WebAppsMigrateMySqlOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsMigrateMySqlResponse > >; @@ -3217,8 +3254,8 @@ export interface WebApps { name: string, options?: WebAppsStartWebSiteNetworkTraceOperationOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartWebSiteNetworkTraceOperationResponse > >; @@ -3429,10 +3466,8 @@ export interface WebApps { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState< - WebAppsApproveOrRejectPrivateEndpointConnectionResponse - >, + SimplePollerLike< + OperationState, WebAppsApproveOrRejectPrivateEndpointConnectionResponse > >; @@ -3464,8 +3499,8 @@ export interface WebApps { privateEndpointConnectionName: string, options?: WebAppsDeletePrivateEndpointConnectionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsDeletePrivateEndpointConnectionResponse > >; @@ -3640,7 +3675,7 @@ export interface WebApps { name: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores an app from a backup blob in Azure Storage. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3666,7 +3701,7 @@ export interface WebApps { name: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a deleted web app to this web app. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3693,7 +3728,7 @@ export interface WebApps { name: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a web app from a snapshot. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -3734,8 +3769,8 @@ export interface WebApps { siteExtensionId: string, options?: WebAppsInstallSiteExtensionOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsInstallSiteExtensionResponse > >; @@ -3796,8 +3831,8 @@ export interface WebApps { siteEnvelope: Site, options?: WebAppsCreateOrUpdateSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSlotResponse > >; @@ -3964,7 +3999,7 @@ export interface WebApps { slot: string, request: RestoreRequest, options?: WebAppsRestoreSlotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a specific backup to another app (or deployment slot, if specified). * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -4350,8 +4385,8 @@ export interface WebApps { slot: string, options?: WebAppsListPublishingCredentialsSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsListPublishingCredentialsSlotResponse > >; @@ -4582,8 +4617,8 @@ export interface WebApps { deploymentStatusId: string, options?: WebAppsGetSlotSiteDeploymentStatusSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsGetSlotSiteDeploymentStatusSlotResponse > >; @@ -4786,8 +4821,8 @@ export interface WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateMSDeployOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateMSDeployOperationSlotResponse > >; @@ -4864,8 +4899,8 @@ export interface WebApps { functionEnvelope: FunctionEnvelope, options?: WebAppsCreateInstanceFunctionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceFunctionSlotResponse > >; @@ -5309,8 +5344,8 @@ export interface WebApps { mSDeploy: MSDeploy, options?: WebAppsCreateInstanceMSDeployOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateInstanceMSDeployOperationSlotResponse > >; @@ -5594,8 +5629,8 @@ export interface WebApps { slot: string, options?: WebAppsStartWebSiteNetworkTraceOperationSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartWebSiteNetworkTraceOperationSlotResponse > >; @@ -5847,8 +5882,8 @@ export interface WebApps { privateEndpointWrapper: PrivateLinkConnectionApprovalRequestResource, options?: WebAppsApproveOrRejectPrivateEndpointConnectionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState< + SimplePollerLike< + OperationState< WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse >, WebAppsApproveOrRejectPrivateEndpointConnectionSlotResponse @@ -5886,8 +5921,8 @@ export interface WebApps { slot: string, options?: WebAppsDeletePrivateEndpointConnectionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsDeletePrivateEndpointConnectionSlotResponse > >; @@ -6099,7 +6134,7 @@ export interface WebApps { slot: string, request: RestoreRequest, options?: WebAppsRestoreFromBackupBlobSlotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores an app from a backup blob in Azure Storage. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -6130,7 +6165,7 @@ export interface WebApps { slot: string, restoreRequest: DeletedAppRestoreRequest, options?: WebAppsRestoreFromDeletedAppSlotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a deleted web app to this web app. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -6161,7 +6196,7 @@ export interface WebApps { slot: string, restoreRequest: SnapshotRestoreRequest, options?: WebAppsRestoreSnapshotSlotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Restores a web app from a snapshot. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -6210,8 +6245,8 @@ export interface WebApps { slot: string, options?: WebAppsInstallSiteExtensionSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsInstallSiteExtensionSlotResponse > >; @@ -6262,7 +6297,7 @@ export interface WebApps { slot: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Swaps two deployment slots of an app. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -6309,8 +6344,8 @@ export interface WebApps { siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSourceControlSlotResponse > >; @@ -6387,8 +6422,8 @@ export interface WebApps { slot: string, options?: WebAppsStartNetworkTraceSlotOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartNetworkTraceSlotResponse > >; @@ -6694,7 +6729,7 @@ export interface WebApps { name: string, slotSwapEntity: CsmSlotEntity, options?: WebAppsSwapSlotWithProductionOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Description for Swaps two deployment slots of an app. * @param resourceGroupName Name of the resource group to which the resource belongs. @@ -6732,8 +6767,8 @@ export interface WebApps { siteSourceControl: SiteSourceControl, options?: WebAppsCreateOrUpdateSourceControlOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsCreateOrUpdateSourceControlResponse > >; @@ -6796,8 +6831,8 @@ export interface WebApps { name: string, options?: WebAppsStartNetworkTraceOptionalParams ): Promise< - PollerLike< - PollOperationState, + SimplePollerLike< + OperationState, WebAppsStartNetworkTraceResponse > >; @@ -7041,4 +7076,80 @@ export interface WebApps { webJobName: string, options?: WebAppsGetWebJobOptionalParams ): Promise; + /** + * Description for Creates the artifacts for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + deployWorkflowArtifacts( + resourceGroupName: string, + name: string, + options?: WebAppsDeployWorkflowArtifactsOptionalParams + ): Promise; + /** + * Description for Creates the artifacts for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + deployWorkflowArtifactsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsDeployWorkflowArtifactsSlotOptionalParams + ): Promise; + /** + * Get workflow information by its ID for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param workflowName Workflow name. + * @param options The options parameters. + */ + getInstanceWorkflowSlot( + resourceGroupName: string, + name: string, + slot: string, + workflowName: string, + options?: WebAppsGetInstanceWorkflowSlotOptionalParams + ): Promise; + /** + * Lists logic app's connections for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param slot Name of the deployment slot. + * @param options The options parameters. + */ + listWorkflowsConnectionsSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: WebAppsListWorkflowsConnectionsSlotOptionalParams + ): Promise; + /** + * Get workflow information by its ID for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param workflowName Workflow name. + * @param options The options parameters. + */ + getWorkflow( + resourceGroupName: string, + name: string, + workflowName: string, + options?: WebAppsGetWorkflowOptionalParams + ): Promise; + /** + * Lists logic app's connections for web site, or a deployment slot. + * @param resourceGroupName Name of the resource group to which the resource belongs. + * @param name Site name. + * @param options The options parameters. + */ + listWorkflowsConnections( + resourceGroupName: string, + name: string, + options?: WebAppsListWorkflowsConnectionsOptionalParams + ): Promise; } diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggerHistories.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggerHistories.ts index 58a61c68c6f6..363e2f92d763 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggerHistories.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggerHistories.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { WorkflowTriggerHistory, WorkflowTriggerHistoriesListOptionalParams, @@ -69,7 +69,7 @@ export interface WorkflowTriggerHistories { triggerName: string, historyName: string, options?: WorkflowTriggerHistoriesResubmitOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Resubmits a workflow run based on the trigger history. * @param resourceGroupName Name of the resource group to which the resource belongs. diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggers.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggers.ts index 88f92db59326..415a9e360fbc 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggers.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/workflowTriggers.ts @@ -7,7 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { PollerLike, PollOperationState } from "@azure/core-lro"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { WorkflowTrigger, WorkflowTriggersListOptionalParams, @@ -80,7 +80,7 @@ export interface WorkflowTriggers { workflowName: string, triggerName: string, options?: WorkflowTriggersRunOptionalParams - ): Promise, void>>; + ): Promise, void>>; /** * Runs a workflow trigger. * @param resourceGroupName Name of the resource group to which the resource belongs. diff --git a/sdk/appservice/arm-appservice/src/pagingHelper.ts b/sdk/appservice/arm-appservice/src/pagingHelper.ts index d85fc13bce1e..269a2b9814b5 100644 --- a/sdk/appservice/arm-appservice/src/pagingHelper.ts +++ b/sdk/appservice/arm-appservice/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { diff --git a/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts b/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts index a3b64f0f2ffd..622a6524f9a4 100644 --- a/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts +++ b/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts @@ -174,7 +174,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-appservice/13.0.4`; + const packageDetails = `azsdk-js-arm-appservice/14.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -227,7 +227,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2022-03-01"; + this.apiVersion = options.apiVersion || "2022-09-01"; this.appServiceCertificateOrders = new AppServiceCertificateOrdersImpl( this ); @@ -1355,7 +1355,6 @@ const listSourceControlsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], serializer @@ -1371,11 +1370,6 @@ const listBillingMetersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.billingLocation, - Parameters.osType - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1395,7 +1389,6 @@ const listCustomHostNameSitesNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion, Parameters.hostname], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1415,13 +1408,6 @@ const listGeoRegionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.sku, - Parameters.linuxWorkersEnabled, - Parameters.xenonWorkersEnabled, - Parameters.linuxDynamicWorkersEnabled - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1441,7 +1427,6 @@ const listSiteIdentifiersAssignedToHostNameNextOperationSpec: coreClient.Operati bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1462,7 +1447,6 @@ const listPremierAddOnOffersNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId,