From ab17d3595838547e3d4418f18e4acac237b615e5 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Fri, 7 Mar 2025 14:26:36 +0000 Subject: [PATCH] CodeGen from PR 33078 in Azure/azure-rest-api-specs Merge 7e8d38fb9b4b97419a2ba40760ef3e285ce99166 into 41c75918ddbde55ccf0a2a656d820f174b7007d0 --- common/config/rush/pnpm-lock.yaml | 79 +- .../arm-appcontainers/CHANGELOG.md | 110 +- sdk/appcontainers/arm-appcontainers/LICENSE | 2 +- sdk/appcontainers/arm-appcontainers/README.md | 13 +- .../arm-appcontainers/_meta.json | 8 +- .../arm-appcontainers/api-extractor.json | 6 +- .../arm-appcontainers/assets.json | 6 - .../arm-appcontainers/package.json | 38 +- .../review/arm-appcontainers.api.md | 1733 +--- .../arm-appcontainers/sample.env | 5 +- .../appResiliencyCreateOrUpdateSample.ts | 65 - .../samples-dev/appResiliencyDeleteSample.ts | 34 - .../samples-dev/appResiliencyGetSample.ts | 34 - .../samples-dev/appResiliencyListSample.ts | 36 - .../samples-dev/appResiliencyUpdateSample.ts | 46 - .../availableWorkloadProfilesGetSample.ts | 35 - .../samples-dev/billingMetersGetSample.ts | 32 - .../samples-dev/buildAuthTokenListSample.ts | 34 - .../buildersCreateOrUpdateSample.ts | 63 - .../samples-dev/buildersDeleteSample.ts | 33 - .../samples-dev/buildersGetSample.ts | 33 - .../buildersListByResourceGroupSample.ts | 35 - .../buildersListBySubscriptionSample.ts | 34 - .../samples-dev/buildersUpdateSample.ts | 41 - .../buildsByBuilderResourceListSample.ts | 36 - .../samples-dev/buildsCreateOrUpdateSample.ts | 100 - .../samples-dev/buildsDeleteSample.ts | 34 - .../samples-dev/buildsGetSample.ts | 34 - .../certificatesCreateOrUpdateSample.ts | 92 - .../samples-dev/certificatesDeleteSample.ts | 38 - .../samples-dev/certificatesGetSample.ts | 34 - .../samples-dev/certificatesListSample.ts | 36 - .../samples-dev/certificatesUpdateSample.ts | 43 - ...onmentsCertificatesCreateOrUpdateSample.ts | 53 - ...tedEnvironmentsCertificatesDeleteSample.ts | 38 - ...nectedEnvironmentsCertificatesGetSample.ts | 38 - ...ectedEnvironmentsCertificatesListSample.ts | 39 - ...tedEnvironmentsCertificatesUpdateSample.ts | 43 - ...EnvironmentsCheckNameAvailabilitySample.ts | 42 - ...nnectedEnvironmentsCreateOrUpdateSample.ts | 49 - ...mentsDaprComponentsCreateOrUpdateSample.ts | 62 - ...dEnvironmentsDaprComponentsDeleteSample.ts | 38 - ...ctedEnvironmentsDaprComponentsGetSample.ts | 38 - ...tedEnvironmentsDaprComponentsListSample.ts | 39 - ...ronmentsDaprComponentsListSecretsSample.ts | 38 - .../connectedEnvironmentsDeleteSample.ts | 36 - .../connectedEnvironmentsGetSample.ts | 36 - ...edEnvironmentsListByResourceGroupSample.ts | 35 - ...tedEnvironmentsListBySubscriptionSample.ts | 34 - ...nvironmentsStoragesCreateOrUpdateSample.ts | 50 - ...nnectedEnvironmentsStoragesDeleteSample.ts | 38 - .../connectedEnvironmentsStoragesGetSample.ts | 38 - ...connectedEnvironmentsStoragesListSample.ts | 36 - .../connectedEnvironmentsUpdateSample.ts | 36 - ...inerAppsAuthConfigsCreateOrUpdateSample.ts | 53 - .../containerAppsAuthConfigsDeleteSample.ts | 38 - .../containerAppsAuthConfigsGetSample.ts | 38 - ...AppsAuthConfigsListByContainerAppSample.ts | 39 - ...ainerAppsBuildsByContainerAppListSample.ts | 39 - .../containerAppsBuildsDeleteSample.ts | 38 - .../containerAppsBuildsGetSample.ts | 38 - .../containerAppsCreateOrUpdateSample.ts | 723 -- .../samples-dev/containerAppsDeleteSample.ts | 33 - ...ntainerAppsDiagnosticsGetDetectorSample.ts | 39 - ...ntainerAppsDiagnosticsGetRevisionSample.ts | 38 - .../containerAppsDiagnosticsGetRootSample.ts | 33 - ...ainerAppsDiagnosticsListDetectorsSample.ts | 40 - ...ainerAppsDiagnosticsListRevisionsSample.ts | 39 - .../containerAppsGetAuthTokenSample.ts | 33 - .../samples-dev/containerAppsGetSample.ts | 33 - .../containerAppsListByResourceGroupSample.ts | 35 - .../containerAppsListBySubscriptionSample.ts | 34 - ...nerAppsListCustomHostNameAnalysisSample.ts | 42 - .../containerAppsListSecretsSample.ts | 33 - .../containerAppsPatchesApplySample.ts | 38 - .../containerAppsPatchesDeleteSample.ts | 38 - .../containerAppsPatchesGetSample.ts | 38 - ...inerAppsPatchesListByContainerAppSample.ts | 39 - ...containerAppsPatchesSkipConfigureSample.ts | 41 - ...nerAppsRevisionReplicasGetReplicaSample.ts | 40 - ...rAppsRevisionReplicasListReplicasSample.ts | 38 - ...inerAppsRevisionsActivateRevisionSample.ts | 38 - ...erAppsRevisionsDeactivateRevisionSample.ts | 38 - ...containerAppsRevisionsGetRevisionSample.ts | 38 - ...ntainerAppsRevisionsListRevisionsSample.ts | 39 - ...ainerAppsRevisionsRestartRevisionSample.ts | 38 - ...nerAppsSessionPoolsCreateOrUpdateSample.ts | 66 - .../containerAppsSessionPoolsDeleteSample.ts | 36 - .../containerAppsSessionPoolsGetSample.ts | 33 - ...psSessionPoolsListByResourceGroupSample.ts | 37 - ...ppsSessionPoolsListBySubscriptionSample.ts | 34 - .../containerAppsSessionPoolsUpdateSample.ts | 61 - ...rAppsSourceControlsCreateOrUpdateSample.ts | 73 - ...containerAppsSourceControlsDeleteSample.ts | 48 - .../containerAppsSourceControlsGetSample.ts | 38 - ...sSourceControlsListByContainerAppSample.ts | 39 - .../samples-dev/containerAppsStartSample.ts | 33 - .../samples-dev/containerAppsStopSample.ts | 33 - .../samples-dev/containerAppsUpdateSample.ts | 155 - ...tResiliencyPoliciesCreateOrUpdateSample.ts | 156 - ...ComponentResiliencyPoliciesDeleteSample.ts | 40 - ...aprComponentResiliencyPoliciesGetSample.ts | 40 - ...prComponentResiliencyPoliciesListSample.ts | 41 - .../daprComponentsCreateOrUpdateSample.ts | 108 - .../samples-dev/daprComponentsDeleteSample.ts | 38 - .../samples-dev/daprComponentsGetSample.ts | 53 - .../samples-dev/daprComponentsListSample.ts | 36 - .../daprComponentsListSecretsSample.ts | 38 - .../daprSubscriptionsCreateOrUpdateSample.ts | 116 - .../daprSubscriptionsDeleteSample.ts | 34 - .../samples-dev/daprSubscriptionsGetSample.ts | 72 - .../daprSubscriptionsListSample.ts | 36 - .../dotNetComponentsCreateOrUpdateSample.ts | 79 - .../dotNetComponentsDeleteSample.ts | 38 - .../samples-dev/dotNetComponentsGetSample.ts | 53 - .../samples-dev/dotNetComponentsListSample.ts | 57 - .../dotNetComponentsUpdateSample.ts | 79 - ...tionsExtensionInvokeFunctionsHostSample.ts | 40 - .../getCustomDomainVerificationIdSample.ts | 31 - .../javaComponentsCreateOrUpdateSample.ts | 97 - .../samples-dev/javaComponentsDeleteSample.ts | 38 - .../samples-dev/javaComponentsGetSample.ts | 53 - .../samples-dev/javaComponentsListSample.ts | 57 - .../samples-dev/javaComponentsUpdateSample.ts | 97 - .../samples-dev/jobExecutionSample.ts | 34 - .../samples-dev/jobsCreateOrUpdateSample.ts | 245 - .../samples-dev/jobsDeleteSample.ts | 33 - .../samples-dev/jobsExecutionsListSample.ts | 36 - .../samples-dev/jobsGetDetectorSample.ts | 35 - .../samples-dev/jobsGetSample.ts | 33 - .../jobsListByResourceGroupSample.ts | 35 - .../jobsListBySubscriptionSample.ts | 34 - .../samples-dev/jobsListDetectorsSample.ts | 37 - .../samples-dev/jobsListSecretsSample.ts | 33 - .../samples-dev/jobsProxyGetSample.ts | 34 - .../samples-dev/jobsResumeSample.ts | 33 - .../samples-dev/jobsStartSample.ts | 53 - .../samples-dev/jobsStopExecutionSample.ts | 38 - .../jobsStopMultipleExecutionsSample.ts | 33 - .../samples-dev/jobsSuspendSample.ts | 33 - .../samples-dev/jobsUpdateSample.ts | 73 - .../logicAppsCreateOrUpdateSample.ts | 41 - .../samples-dev/logicAppsDeleteSample.ts | 34 - .../logicAppsDeployWorkflowArtifactsSample.ts | 120 - .../samples-dev/logicAppsGetSample.ts | 34 - .../samples-dev/logicAppsGetWorkflowSample.ts | 40 - .../samples-dev/logicAppsInvokeSample.ts | 40 - ...logicAppsListWorkflowsConnectionsSample.ts | 38 - .../logicAppsListWorkflowsSample.ts | 41 - ...managedCertificatesCreateOrUpdateSample.ts | 53 - .../managedCertificatesDeleteSample.ts | 38 - .../managedCertificatesGetSample.ts | 38 - .../managedCertificatesListSample.ts | 36 - .../managedCertificatesUpdateSample.ts | 43 - ...EnvironmentDiagnosticsGetDetectorSample.ts | 39 - ...vironmentDiagnosticsListDetectorsSample.ts | 37 - ...EndpointConnectionsCreateOrUpdateSample.ts | 47 - ...tPrivateEndpointConnectionsDeleteSample.ts | 38 - ...mentPrivateEndpointConnectionsGetSample.ts | 38 - ...entPrivateEndpointConnectionsListSample.ts | 39 - ...vironmentPrivateLinkResourcesListSample.ts | 39 - .../managedEnvironmentUsagesListSample.ts | 38 - ...managedEnvironmentsCreateOrUpdateSample.ts | 177 - .../managedEnvironmentsDeleteSample.ts | 36 - ...gedEnvironmentsDiagnosticsGetRootSample.ts | 36 - .../managedEnvironmentsGetAuthTokenSample.ts | 33 - .../managedEnvironmentsGetSample.ts | 33 - ...edEnvironmentsListByResourceGroupSample.ts | 35 - ...gedEnvironmentsListBySubscriptionSample.ts | 34 - ...ronmentsListWorkloadProfileStatesSample.ts | 39 - ...nvironmentsStoragesCreateOrUpdateSample.ts | 83 - ...managedEnvironmentsStoragesDeleteSample.ts | 38 - .../managedEnvironmentsStoragesGetSample.ts | 61 - .../managedEnvironmentsStoragesListSample.ts | 33 - .../managedEnvironmentsUpdateSample.ts | 42 - .../namespacesCheckNameAvailabilitySample.ts | 68 - .../samples-dev/operationsListSample.ts | 34 - .../samples-dev/usagesListSample.ts | 34 - .../samples/v2-beta/javascript/README.md | 384 - .../appResiliencyCreateOrUpdateSample.js | 67 - .../javascript/appResiliencyDeleteSample.js | 37 - .../javascript/appResiliencyGetSample.js | 37 - .../javascript/appResiliencyListSample.js | 39 - .../javascript/appResiliencyUpdateSample.js | 48 - .../availableWorkloadProfilesGetSample.js | 38 - .../javascript/billingMetersGetSample.js | 35 - .../javascript/buildAuthTokenListSample.js | 37 - .../buildersCreateOrUpdateSample.js | 65 - .../javascript/buildersDeleteSample.js | 36 - .../v2-beta/javascript/buildersGetSample.js | 36 - .../buildersListByResourceGroupSample.js | 38 - .../buildersListBySubscriptionSample.js | 37 - .../javascript/buildersUpdateSample.js | 43 - .../buildsByBuilderResourceListSample.js | 39 - .../javascript/buildsCreateOrUpdateSample.js | 102 - .../v2-beta/javascript/buildsDeleteSample.js | 37 - .../v2-beta/javascript/buildsGetSample.js | 37 - .../certificatesCreateOrUpdateSample.js | 91 - .../javascript/certificatesDeleteSample.js | 41 - .../javascript/certificatesGetSample.js | 37 - .../javascript/certificatesListSample.js | 39 - .../javascript/certificatesUpdateSample.js | 45 - ...onmentsCertificatesCreateOrUpdateSample.js | 50 - ...tedEnvironmentsCertificatesDeleteSample.js | 41 - ...nectedEnvironmentsCertificatesGetSample.js | 41 - ...ectedEnvironmentsCertificatesListSample.js | 42 - ...tedEnvironmentsCertificatesUpdateSample.js | 45 - ...EnvironmentsCheckNameAvailabilitySample.js | 44 - ...nnectedEnvironmentsCreateOrUpdateSample.js | 51 - ...mentsDaprComponentsCreateOrUpdateSample.js | 64 - ...dEnvironmentsDaprComponentsDeleteSample.js | 41 - ...ctedEnvironmentsDaprComponentsGetSample.js | 41 - ...tedEnvironmentsDaprComponentsListSample.js | 42 - ...ronmentsDaprComponentsListSecretsSample.js | 41 - .../connectedEnvironmentsDeleteSample.js | 39 - .../connectedEnvironmentsGetSample.js | 39 - ...edEnvironmentsListByResourceGroupSample.js | 38 - ...tedEnvironmentsListBySubscriptionSample.js | 37 - ...nvironmentsStoragesCreateOrUpdateSample.js | 52 - ...nnectedEnvironmentsStoragesDeleteSample.js | 41 - .../connectedEnvironmentsStoragesGetSample.js | 41 - ...connectedEnvironmentsStoragesListSample.js | 39 - .../connectedEnvironmentsUpdateSample.js | 39 - ...inerAppsAuthConfigsCreateOrUpdateSample.js | 55 - .../containerAppsAuthConfigsDeleteSample.js | 41 - .../containerAppsAuthConfigsGetSample.js | 41 - ...AppsAuthConfigsListByContainerAppSample.js | 42 - ...ainerAppsBuildsByContainerAppListSample.js | 42 - .../containerAppsBuildsDeleteSample.js | 41 - .../containerAppsBuildsGetSample.js | 41 - .../containerAppsCreateOrUpdateSample.js | 725 -- .../javascript/containerAppsDeleteSample.js | 36 - ...ntainerAppsDiagnosticsGetDetectorSample.js | 42 - ...ntainerAppsDiagnosticsGetRevisionSample.js | 41 - .../containerAppsDiagnosticsGetRootSample.js | 36 - ...ainerAppsDiagnosticsListDetectorsSample.js | 43 - ...ainerAppsDiagnosticsListRevisionsSample.js | 42 - .../containerAppsGetAuthTokenSample.js | 36 - .../javascript/containerAppsGetSample.js | 36 - .../containerAppsListByResourceGroupSample.js | 38 - .../containerAppsListBySubscriptionSample.js | 37 - ...nerAppsListCustomHostNameAnalysisSample.js | 44 - .../containerAppsListSecretsSample.js | 36 - .../containerAppsPatchesApplySample.js | 41 - .../containerAppsPatchesDeleteSample.js | 41 - .../containerAppsPatchesGetSample.js | 41 - ...inerAppsPatchesListByContainerAppSample.js | 42 - ...containerAppsPatchesSkipConfigureSample.js | 43 - ...nerAppsRevisionReplicasGetReplicaSample.js | 43 - ...rAppsRevisionReplicasListReplicasSample.js | 41 - ...inerAppsRevisionsActivateRevisionSample.js | 41 - ...erAppsRevisionsDeactivateRevisionSample.js | 41 - ...containerAppsRevisionsGetRevisionSample.js | 41 - ...ntainerAppsRevisionsListRevisionsSample.js | 42 - ...ainerAppsRevisionsRestartRevisionSample.js | 41 - ...nerAppsSessionPoolsCreateOrUpdateSample.js | 68 - .../containerAppsSessionPoolsDeleteSample.js | 39 - .../containerAppsSessionPoolsGetSample.js | 36 - ...psSessionPoolsListByResourceGroupSample.js | 38 - ...ppsSessionPoolsListBySubscriptionSample.js | 37 - .../containerAppsSessionPoolsUpdateSample.js | 63 - ...rAppsSourceControlsCreateOrUpdateSample.js | 72 - ...containerAppsSourceControlsDeleteSample.js | 50 - .../containerAppsSourceControlsGetSample.js | 41 - ...sSourceControlsListByContainerAppSample.js | 42 - .../javascript/containerAppsStartSample.js | 36 - .../javascript/containerAppsStopSample.js | 36 - .../javascript/containerAppsUpdateSample.js | 157 - ...tResiliencyPoliciesCreateOrUpdateSample.js | 158 - ...ComponentResiliencyPoliciesDeleteSample.js | 43 - ...aprComponentResiliencyPoliciesGetSample.js | 43 - ...prComponentResiliencyPoliciesListSample.js | 44 - .../daprComponentsCreateOrUpdateSample.js | 110 - .../javascript/daprComponentsDeleteSample.js | 41 - .../javascript/daprComponentsGetSample.js | 56 - .../javascript/daprComponentsListSample.js | 39 - .../daprComponentsListSecretsSample.js | 41 - .../daprSubscriptionsCreateOrUpdateSample.js | 118 - .../daprSubscriptionsDeleteSample.js | 37 - .../javascript/daprSubscriptionsGetSample.js | 75 - .../javascript/daprSubscriptionsListSample.js | 39 - .../dotNetComponentsCreateOrUpdateSample.js | 81 - .../dotNetComponentsDeleteSample.js | 41 - .../javascript/dotNetComponentsGetSample.js | 56 - .../javascript/dotNetComponentsListSample.js | 60 - .../dotNetComponentsUpdateSample.js | 81 - ...tionsExtensionInvokeFunctionsHostSample.js | 43 - .../getCustomDomainVerificationIdSample.js | 34 - .../javaComponentsCreateOrUpdateSample.js | 99 - .../javascript/javaComponentsDeleteSample.js | 41 - .../javascript/javaComponentsGetSample.js | 56 - .../javascript/javaComponentsListSample.js | 60 - .../javascript/javaComponentsUpdateSample.js | 99 - .../v2-beta/javascript/jobExecutionSample.js | 37 - .../javascript/jobsCreateOrUpdateSample.js | 247 - .../v2-beta/javascript/jobsDeleteSample.js | 36 - .../javascript/jobsExecutionsListSample.js | 39 - .../javascript/jobsGetDetectorSample.js | 38 - .../v2-beta/javascript/jobsGetSample.js | 36 - .../jobsListByResourceGroupSample.js | 38 - .../jobsListBySubscriptionSample.js | 37 - .../javascript/jobsListDetectorsSample.js | 40 - .../javascript/jobsListSecretsSample.js | 36 - .../v2-beta/javascript/jobsProxyGetSample.js | 37 - .../v2-beta/javascript/jobsResumeSample.js | 36 - .../v2-beta/javascript/jobsStartSample.js | 55 - .../javascript/jobsStopExecutionSample.js | 41 - .../jobsStopMultipleExecutionsSample.js | 36 - .../v2-beta/javascript/jobsSuspendSample.js | 36 - .../v2-beta/javascript/jobsUpdateSample.js | 75 - .../logicAppsCreateOrUpdateSample.js | 43 - .../javascript/logicAppsDeleteSample.js | 37 - .../logicAppsDeployWorkflowArtifactsSample.js | 119 - .../v2-beta/javascript/logicAppsGetSample.js | 37 - .../javascript/logicAppsGetWorkflowSample.js | 43 - .../javascript/logicAppsInvokeSample.js | 43 - ...logicAppsListWorkflowsConnectionsSample.js | 41 - .../logicAppsListWorkflowsSample.js | 44 - ...managedCertificatesCreateOrUpdateSample.js | 52 - .../managedCertificatesDeleteSample.js | 41 - .../managedCertificatesGetSample.js | 41 - .../managedCertificatesListSample.js | 39 - .../managedCertificatesUpdateSample.js | 45 - ...EnvironmentDiagnosticsGetDetectorSample.js | 42 - ...vironmentDiagnosticsListDetectorsSample.js | 40 - ...EndpointConnectionsCreateOrUpdateSample.js | 49 - ...tPrivateEndpointConnectionsDeleteSample.js | 41 - ...mentPrivateEndpointConnectionsGetSample.js | 41 - ...entPrivateEndpointConnectionsListSample.js | 42 - ...vironmentPrivateLinkResourcesListSample.js | 42 - .../managedEnvironmentUsagesListSample.js | 38 - ...managedEnvironmentsCreateOrUpdateSample.js | 179 - .../managedEnvironmentsDeleteSample.js | 39 - ...gedEnvironmentsDiagnosticsGetRootSample.js | 39 - .../managedEnvironmentsGetAuthTokenSample.js | 36 - .../managedEnvironmentsGetSample.js | 36 - ...edEnvironmentsListByResourceGroupSample.js | 38 - ...gedEnvironmentsListBySubscriptionSample.js | 37 - ...ronmentsListWorkloadProfileStatesSample.js | 42 - ...nvironmentsStoragesCreateOrUpdateSample.js | 85 - ...managedEnvironmentsStoragesDeleteSample.js | 41 - .../managedEnvironmentsStoragesGetSample.js | 64 - .../managedEnvironmentsStoragesListSample.js | 36 - .../managedEnvironmentsUpdateSample.js | 44 - .../namespacesCheckNameAvailabilitySample.js | 70 - .../javascript/operationsListSample.js | 37 - .../samples/v2-beta/javascript/package.json | 32 - .../samples/v2-beta/javascript/sample.env | 4 - .../v2-beta/javascript/usagesListSample.js | 37 - .../samples/v2-beta/typescript/README.md | 397 - .../samples/v2-beta/typescript/package.json | 41 - .../samples/v2-beta/typescript/sample.env | 4 - .../src/appResiliencyCreateOrUpdateSample.ts | 74 - .../src/appResiliencyDeleteSample.ts | 39 - .../typescript/src/appResiliencyGetSample.ts | 39 - .../typescript/src/appResiliencyListSample.ts | 40 - .../src/appResiliencyUpdateSample.ts | 49 - .../src/availableWorkloadProfilesGetSample.ts | 36 - .../typescript/src/billingMetersGetSample.ts | 33 - .../src/buildAuthTokenListSample.ts | 39 - .../src/buildersCreateOrUpdateSample.ts | 66 - .../typescript/src/buildersDeleteSample.ts | 37 - .../typescript/src/buildersGetSample.ts | 34 - .../src/buildersListByResourceGroupSample.ts | 38 - .../src/buildersListBySubscriptionSample.ts | 35 - .../typescript/src/buildersUpdateSample.ts | 44 - .../src/buildsByBuilderResourceListSample.ts | 40 - .../src/buildsCreateOrUpdateSample.ts | 104 - .../typescript/src/buildsDeleteSample.ts | 39 - .../v2-beta/typescript/src/buildsGetSample.ts | 39 - .../src/certificatesCreateOrUpdateSample.ts | 96 - .../src/certificatesDeleteSample.ts | 40 - .../typescript/src/certificatesGetSample.ts | 40 - .../typescript/src/certificatesListSample.ts | 41 - .../src/certificatesUpdateSample.ts | 47 - ...onmentsCertificatesCreateOrUpdateSample.ts | 54 - ...tedEnvironmentsCertificatesDeleteSample.ts | 40 - ...nectedEnvironmentsCertificatesGetSample.ts | 40 - ...ectedEnvironmentsCertificatesListSample.ts | 41 - ...tedEnvironmentsCertificatesUpdateSample.ts | 47 - ...EnvironmentsCheckNameAvailabilitySample.ts | 46 - ...nnectedEnvironmentsCreateOrUpdateSample.ts | 53 - ...mentsDaprComponentsCreateOrUpdateSample.ts | 67 - ...dEnvironmentsDaprComponentsDeleteSample.ts | 40 - ...ctedEnvironmentsDaprComponentsGetSample.ts | 40 - ...tedEnvironmentsDaprComponentsListSample.ts | 41 - ...ronmentsDaprComponentsListSecretsSample.ts | 40 - .../src/connectedEnvironmentsDeleteSample.ts | 38 - .../src/connectedEnvironmentsGetSample.ts | 38 - ...edEnvironmentsListByResourceGroupSample.ts | 39 - ...tedEnvironmentsListBySubscriptionSample.ts | 35 - ...nvironmentsStoragesCreateOrUpdateSample.ts | 54 - ...nnectedEnvironmentsStoragesDeleteSample.ts | 40 - .../connectedEnvironmentsStoragesGetSample.ts | 40 - ...connectedEnvironmentsStoragesListSample.ts | 38 - .../src/connectedEnvironmentsUpdateSample.ts | 38 - ...inerAppsAuthConfigsCreateOrUpdateSample.ts | 54 - .../containerAppsAuthConfigsDeleteSample.ts | 40 - .../src/containerAppsAuthConfigsGetSample.ts | 40 - ...AppsAuthConfigsListByContainerAppSample.ts | 41 - ...ainerAppsBuildsByContainerAppListSample.ts | 40 - .../src/containerAppsBuildsDeleteSample.ts | 39 - .../src/containerAppsBuildsGetSample.ts | 39 - .../src/containerAppsCreateOrUpdateSample.ts | 740 -- .../src/containerAppsDeleteSample.ts | 37 - ...ntainerAppsDiagnosticsGetDetectorSample.ts | 40 - ...ntainerAppsDiagnosticsGetRevisionSample.ts | 39 - .../containerAppsDiagnosticsGetRootSample.ts | 37 - ...ainerAppsDiagnosticsListDetectorsSample.ts | 41 - ...ainerAppsDiagnosticsListRevisionsSample.ts | 40 - .../src/containerAppsGetAuthTokenSample.ts | 37 - .../typescript/src/containerAppsGetSample.ts | 37 - .../containerAppsListByResourceGroupSample.ts | 38 - .../containerAppsListBySubscriptionSample.ts | 35 - ...nerAppsListCustomHostNameAnalysisSample.ts | 45 - .../src/containerAppsListSecretsSample.ts | 37 - .../src/containerAppsPatchesApplySample.ts | 39 - .../src/containerAppsPatchesDeleteSample.ts | 39 - .../src/containerAppsPatchesGetSample.ts | 39 - ...inerAppsPatchesListByContainerAppSample.ts | 40 - ...containerAppsPatchesSkipConfigureSample.ts | 44 - ...nerAppsRevisionReplicasGetReplicaSample.ts | 42 - ...rAppsRevisionReplicasListReplicasSample.ts | 40 - ...inerAppsRevisionsActivateRevisionSample.ts | 39 - ...erAppsRevisionsDeactivateRevisionSample.ts | 39 - ...containerAppsRevisionsGetRevisionSample.ts | 39 - ...ntainerAppsRevisionsListRevisionsSample.ts | 40 - ...ainerAppsRevisionsRestartRevisionSample.ts | 39 - ...nerAppsSessionPoolsCreateOrUpdateSample.ts | 67 - .../containerAppsSessionPoolsDeleteSample.ts | 37 - .../src/containerAppsSessionPoolsGetSample.ts | 37 - ...psSessionPoolsListByResourceGroupSample.ts | 38 - ...ppsSessionPoolsListBySubscriptionSample.ts | 35 - .../containerAppsSessionPoolsUpdateSample.ts | 64 - ...rAppsSourceControlsCreateOrUpdateSample.ts | 76 - ...containerAppsSourceControlsDeleteSample.ts | 52 - .../containerAppsSourceControlsGetSample.ts | 40 - ...sSourceControlsListByContainerAppSample.ts | 41 - .../src/containerAppsStartSample.ts | 37 - .../typescript/src/containerAppsStopSample.ts | 37 - .../src/containerAppsUpdateSample.ts | 159 - ...tResiliencyPoliciesCreateOrUpdateSample.ts | 164 - ...ComponentResiliencyPoliciesDeleteSample.ts | 42 - ...aprComponentResiliencyPoliciesGetSample.ts | 42 - ...prComponentResiliencyPoliciesListSample.ts | 43 - .../src/daprComponentsCreateOrUpdateSample.ts | 114 - .../src/daprComponentsDeleteSample.ts | 40 - .../typescript/src/daprComponentsGetSample.ts | 65 - .../src/daprComponentsListSample.ts | 41 - .../src/daprComponentsListSecretsSample.ts | 40 - .../daprSubscriptionsCreateOrUpdateSample.ts | 124 - .../src/daprSubscriptionsDeleteSample.ts | 40 - .../src/daprSubscriptionsGetSample.ts | 90 - .../src/daprSubscriptionsListSample.ts | 41 - .../dotNetComponentsCreateOrUpdateSample.ts | 85 - .../src/dotNetComponentsDeleteSample.ts | 40 - .../src/dotNetComponentsGetSample.ts | 65 - .../src/dotNetComponentsListSample.ts | 67 - .../src/dotNetComponentsUpdateSample.ts | 85 - ...tionsExtensionInvokeFunctionsHostSample.ts | 41 - .../getCustomDomainVerificationIdSample.ts | 32 - .../src/javaComponentsCreateOrUpdateSample.ts | 103 - .../src/javaComponentsDeleteSample.ts | 40 - .../typescript/src/javaComponentsGetSample.ts | 65 - .../src/javaComponentsListSample.ts | 67 - .../src/javaComponentsUpdateSample.ts | 103 - .../typescript/src/jobExecutionSample.ts | 39 - .../src/jobsCreateOrUpdateSample.ts | 247 - .../typescript/src/jobsDeleteSample.ts | 37 - .../src/jobsExecutionsListSample.ts | 40 - .../typescript/src/jobsGetDetectorSample.ts | 40 - .../v2-beta/typescript/src/jobsGetSample.ts | 34 - .../src/jobsListByResourceGroupSample.ts | 36 - .../src/jobsListBySubscriptionSample.ts | 35 - .../typescript/src/jobsListDetectorsSample.ts | 41 - .../typescript/src/jobsListSecretsSample.ts | 34 - .../typescript/src/jobsProxyGetSample.ts | 39 - .../typescript/src/jobsResumeSample.ts | 37 - .../v2-beta/typescript/src/jobsStartSample.ts | 61 - .../typescript/src/jobsStopExecutionSample.ts | 39 - .../src/jobsStopMultipleExecutionsSample.ts | 37 - .../typescript/src/jobsSuspendSample.ts | 37 - .../typescript/src/jobsUpdateSample.ts | 80 - .../src/logicAppsCreateOrUpdateSample.ts | 42 - .../typescript/src/logicAppsDeleteSample.ts | 40 - .../logicAppsDeployWorkflowArtifactsSample.ts | 124 - .../typescript/src/logicAppsGetSample.ts | 40 - .../src/logicAppsGetWorkflowSample.ts | 42 - .../typescript/src/logicAppsInvokeSample.ts | 42 - ...logicAppsListWorkflowsConnectionsSample.ts | 40 - .../src/logicAppsListWorkflowsSample.ts | 43 - ...managedCertificatesCreateOrUpdateSample.ts | 55 - .../src/managedCertificatesDeleteSample.ts | 40 - .../src/managedCertificatesGetSample.ts | 40 - .../src/managedCertificatesListSample.ts | 41 - .../src/managedCertificatesUpdateSample.ts | 47 - ...EnvironmentDiagnosticsGetDetectorSample.ts | 40 - ...vironmentDiagnosticsListDetectorsSample.ts | 38 - ...EndpointConnectionsCreateOrUpdateSample.ts | 51 - ...tPrivateEndpointConnectionsDeleteSample.ts | 41 - ...mentPrivateEndpointConnectionsGetSample.ts | 40 - ...entPrivateEndpointConnectionsListSample.ts | 41 - ...vironmentPrivateLinkResourcesListSample.ts | 41 - .../src/managedEnvironmentUsagesListSample.ts | 40 - ...managedEnvironmentsCreateOrUpdateSample.ts | 183 - .../src/managedEnvironmentsDeleteSample.ts | 38 - ...gedEnvironmentsDiagnosticsGetRootSample.ts | 38 - .../managedEnvironmentsGetAuthTokenSample.ts | 37 - .../src/managedEnvironmentsGetSample.ts | 38 - ...edEnvironmentsListByResourceGroupSample.ts | 39 - ...gedEnvironmentsListBySubscriptionSample.ts | 35 - ...ronmentsListWorkloadProfileStatesSample.ts | 41 - ...nvironmentsStoragesCreateOrUpdateSample.ts | 89 - ...managedEnvironmentsStoragesDeleteSample.ts | 40 - .../managedEnvironmentsStoragesGetSample.ts | 65 - .../managedEnvironmentsStoragesListSample.ts | 38 - .../src/managedEnvironmentsUpdateSample.ts | 46 - .../namespacesCheckNameAvailabilitySample.ts | 74 - .../typescript/src/operationsListSample.ts | 35 - .../typescript/src/usagesListSample.ts | 35 - .../samples/v2-beta/typescript/tsconfig.json | 17 - .../src/containerAppsAPIClient.ts | 70 +- .../arm-appcontainers/src/lroImpl.ts | 4 + .../arm-appcontainers/src/models/index.ts | 2771 +----- .../arm-appcontainers/src/models/mappers.ts | 7971 ++++++----------- .../src/models/parameters.ts | 325 +- .../src/operations/appResiliencyOperations.ts | 374 - .../src/operations/buildAuthToken.ts | 74 - .../src/operations/builders.ts | 728 -- .../src/operations/builds.ts | 347 - .../src/operations/buildsByBuilderResource.ts | 193 - .../src/operations/certificates.ts | 4 +- .../src/operations/connectedEnvironments.ts | 4 +- .../connectedEnvironmentsCertificates.ts | 7 +- .../connectedEnvironmentsDaprComponents.ts | 5 +- .../connectedEnvironmentsStorages.ts | 5 +- .../src/operations/containerApps.ts | 4 +- .../operations/containerAppsAuthConfigs.ts | 4 +- .../src/operations/containerAppsBuilds.ts | 208 - .../containerAppsBuildsByContainerApp.ts | 199 - .../operations/containerAppsDiagnostics.ts | 4 +- .../src/operations/containerAppsPatches.ts | 648 -- .../src/operations/containerAppsRevisions.ts | 2 +- .../operations/containerAppsSessionPools.ts | 4 +- .../operations/containerAppsSourceControls.ts | 16 +- .../daprComponentResiliencyPolicies.ts | 369 - .../src/operations/daprComponents.ts | 2 +- .../src/operations/daprSubscriptions.ts | 337 - .../src/operations/dotNetComponents.ts | 655 -- .../src/operations/functionsExtension.ts | 83 - .../arm-appcontainers/src/operations/index.ts | 15 - .../src/operations/javaComponents.ts | 12 +- .../arm-appcontainers/src/operations/jobs.ts | 236 +- .../src/operations/logicApps.ts | 549 -- .../src/operations/managedCertificates.ts | 4 +- ...edEnvironmentPrivateEndpointConnections.ts | 534 -- .../managedEnvironmentPrivateLinkResources.ts | 199 - .../src/operations/managedEnvironments.ts | 4 +- .../operations/managedEnvironmentsStorages.ts | 2 +- .../src/operations/namespaces.ts | 2 +- .../appResiliencyOperations.ts | 92 - .../operationsInterfaces/buildAuthToken.ts | 29 - .../src/operationsInterfaces/builders.ts | 145 - .../src/operationsInterfaces/builds.ts | 98 - .../buildsByBuilderResource.ts | 29 - .../containerAppsBuilds.ts | 63 - .../containerAppsBuildsByContainerApp.ts | 29 - .../containerAppsPatches.ts | 149 - .../daprComponentResiliencyPolicies.ts | 84 - .../operationsInterfaces/daprSubscriptions.ts | 75 - .../operationsInterfaces/dotNetComponents.ts | 152 - .../functionsExtension.ts | 31 - .../src/operationsInterfaces/index.ts | 15 - .../src/operationsInterfaces/jobs.ts | 52 - .../src/operationsInterfaces/logicApps.ts | 144 - ...edEnvironmentPrivateEndpointConnections.ts | 120 - .../managedEnvironmentPrivateLinkResources.ts | 29 - .../test/appcontainers_examples.spec.ts | 132 - .../arm-appcontainers/test/sampleTest.ts | 40 + .../arm-appcontainers/test/snippets.spec.ts | 18 +- .../tsconfig.browser.config.json | 19 +- .../arm-appcontainers/tsconfig.json | 36 +- .../vitest.browser.config.ts | 6 +- .../arm-appcontainers/vitest.config.ts | 3 +- .../review/core-rest-pipeline.api.md | 4 +- 585 files changed, 3290 insertions(+), 44824 deletions(-) delete mode 100644 sdk/appcontainers/arm-appcontainers/assets.json delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/availableWorkloadProfilesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/billingMetersGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildAuthTokenListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildersUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildsByBuilderResourceListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/buildsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/certificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/certificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/certificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/certificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/certificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCheckNameAvailabilitySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsByContainerAppListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRootSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListRevisionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetAuthTokenSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesApplySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesSkipConfigureSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsActivateRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsGetRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsListRevisionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsRestartRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStartSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStopSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/functionsExtensionInvokeFunctionsHostSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/getCustomDomainVerificationIdSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobExecutionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsExecutionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsProxyGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsResumeSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsStartSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopExecutionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopMultipleExecutionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsSuspendSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/jobsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeployWorkflowArtifactsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetWorkflowSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsInvokeSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsConnectionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateLinkResourcesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentUsagesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDiagnosticsGetRootSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetAuthTokenSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListWorkloadProfileStatesSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/namespacesCheckNameAvailabilitySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/operationsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples-dev/usagesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/README.md delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/availableWorkloadProfilesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/billingMetersGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildAuthTokenListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsByBuilderResourceListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCheckNameAvailabilitySample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSecretsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsByContainerAppListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetDetectorSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRevisionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRootSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListDetectorsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListRevisionsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetAuthTokenSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListSecretsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesApplySample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesListByContainerAppSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesSkipConfigureSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsActivateRevisionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsGetRevisionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsListRevisionsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsRestartRevisionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStartSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStopSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSecretsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/functionsExtensionInvokeFunctionsHostSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/getCustomDomainVerificationIdSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobExecutionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsExecutionsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetDetectorSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListDetectorsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListSecretsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsProxyGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsResumeSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStartSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopExecutionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopMultipleExecutionsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsSuspendSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeployWorkflowArtifactsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetWorkflowSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsInvokeSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsConnectionsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsGetDetectorSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsListDetectorsSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateLinkResourcesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentUsagesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDiagnosticsGetRootSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetAuthTokenSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListByResourceGroupSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListBySubscriptionSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListWorkloadProfileStatesSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesDeleteSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesGetSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsUpdateSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/namespacesCheckNameAvailabilitySample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/operationsListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/package.json delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/sample.env delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/usagesListSample.js delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/README.md delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/package.json delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/sample.env delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/availableWorkloadProfilesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/billingMetersGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildAuthTokenListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsByBuilderResourceListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCheckNameAvailabilitySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsByContainerAppListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRootSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListRevisionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetAuthTokenSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesApplySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesSkipConfigureSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStartSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStopSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/functionsExtensionInvokeFunctionsHostSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/getCustomDomainVerificationIdSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobExecutionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsExecutionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListSecretsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsProxyGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsResumeSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStartSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopExecutionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopMultipleExecutionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsSuspendSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeployWorkflowArtifactsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetWorkflowSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsInvokeSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsConnectionsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsGetDetectorSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsListDetectorsSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateLinkResourcesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentUsagesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDiagnosticsGetRootSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetAuthTokenSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListWorkloadProfileStatesSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsUpdateSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/namespacesCheckNameAvailabilitySample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/operationsListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/usagesListSample.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/tsconfig.json delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/appResiliencyOperations.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/buildAuthToken.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/builders.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/builds.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/buildsByBuilderResource.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuilds.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuildsByContainerApp.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/containerAppsPatches.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/daprComponentResiliencyPolicies.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/daprSubscriptions.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/dotNetComponents.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/functionsExtension.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/logicApps.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateEndpointConnections.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateLinkResources.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/appResiliencyOperations.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildAuthToken.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builders.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builds.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildsByBuilderResource.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuilds.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuildsByContainerApp.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsPatches.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprComponentResiliencyPolicies.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprSubscriptions.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/dotNetComponents.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/functionsExtension.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/logicApps.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateEndpointConnections.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateLinkResources.ts delete mode 100644 sdk/appcontainers/arm-appcontainers/test/appcontainers_examples.spec.ts create mode 100644 sdk/appcontainers/arm-appcontainers/test/sampleTest.ts diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 1a2803bf0af9..655a7225bf7c 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -2540,7 +2540,7 @@ packages: version: 0.0.0 '@rush-temp/ai-inference@file:projects/ai-inference.tgz': - resolution: {integrity: sha512-jy3iCFAJq8qZFdMN0GEK8XNPi3lTfEIQEOM4jNCqE850gODahI+XXRqHMbrGUJd2tjmZMm0cKc6CQbjVxFsi/Q==, tarball: file:projects/ai-inference.tgz} + resolution: {integrity: sha512-3F/JVas1qHmWihXHHGxX6EUigHTNsftXBjspS6BMU6/lu/xDNMxKAY30DJMK90KyhH5UxZ+ZRwWlWbhKWW+2ow==, tarball: file:projects/ai-inference.tgz} version: 0.0.0 '@rush-temp/ai-language-conversations@file:projects/ai-language-conversations.tgz': @@ -2560,7 +2560,7 @@ packages: version: 0.0.0 '@rush-temp/ai-projects@file:projects/ai-projects.tgz': - resolution: {integrity: sha512-olWaOR+lScYd4KfOBFDagJ6zLA728vt+08hSgNDsM182EdAAAYN2c5dqJ7BsN/1rv7I6rb6lywdCSQ5gK9pABQ==, tarball: file:projects/ai-projects.tgz} + resolution: {integrity: sha512-rbzbhwz+05oHf7CC83pshBtWypNW2LVlSpfOOwkX3BmqB4MiHah+CmjehPDEKqpnn0vgU4GzdM0BeD4HoI9J1w==, tarball: file:projects/ai-projects.tgz} version: 0.0.0 '@rush-temp/ai-text-analytics@file:projects/ai-text-analytics.tgz': @@ -2624,7 +2624,7 @@ packages: version: 0.0.0 '@rush-temp/arm-appcontainers@file:projects/arm-appcontainers.tgz': - resolution: {integrity: sha512-zMm6NFy0V6brFj0mLpyVgpGhdK8jH6XDTsFR3+/uoAisz0fwKzQ9XD8LUBSHWwqNFSzYykLFE4VLaQoEa1cLhA==, tarball: file:projects/arm-appcontainers.tgz} + resolution: {integrity: sha512-0EGJMAsELZEs1eXv7lsEEH5jdaicNXeMLRcguqzND1JPVeNftHNN2BcRmtjTaujBxDGKSSYfqeK/5U7q4mkcjA==, tarball: file:projects/arm-appcontainers.tgz} version: 0.0.0 '@rush-temp/arm-appinsights@file:projects/arm-appinsights.tgz': @@ -3648,7 +3648,7 @@ packages: version: 0.0.0 '@rush-temp/communication-rooms@file:projects/communication-rooms.tgz': - resolution: {integrity: sha512-K/mZVvKYYhjrrQDbShm4Ce+SuL1L8OaN6eeLfdQoSnsM2RNwvFOE7Tu/khStZuiAKvNDV038ct8fpPIhJ1sAiw==, tarball: file:projects/communication-rooms.tgz} + resolution: {integrity: sha512-wcpWrS8VO0FKg6DaO+xs5VO3UNA/6+conA2cUSEMv+4WFvyxnkdr5IOlR8u0Svky3hGVa1SIZvc5jBbbqATlag==, tarball: file:projects/communication-rooms.tgz} version: 0.0.0 '@rush-temp/communication-short-codes@file:projects/communication-short-codes.tgz': @@ -3884,7 +3884,7 @@ packages: version: 0.0.0 '@rush-temp/mixed-reality-remote-rendering@file:projects/mixed-reality-remote-rendering.tgz': - resolution: {integrity: sha512-4Wx6KxuTYKmgYWfmzLs2BW2MkwATk98Fdx88WL7/sa632gevVbfOCT5WWUUsqW2OtLN36jpr8Vi6UfKrxEON0g==, tarball: file:projects/mixed-reality-remote-rendering.tgz} + resolution: {integrity: sha512-TN6cq8PIrYAy/tJ4mQIkcRn1Wkr5lBxnDY8UeSvQP9D61ZN0iESKb4j+wnXPJp2RNKa9tBpg8NcOt5Jc7qhwaQ==, tarball: file:projects/mixed-reality-remote-rendering.tgz} version: 0.0.0 '@rush-temp/mock-hub@file:projects/mock-hub.tgz': @@ -3900,11 +3900,11 @@ packages: version: 0.0.0 '@rush-temp/monitor-opentelemetry@file:projects/monitor-opentelemetry.tgz': - resolution: {integrity: sha512-1K08pDS3mRgyqyPHPU/PS/Kwhn10bdtrh9sU9itLgfy+cj+Rn/KkMG0Y0ZIAqhPRYc1/LUdXBVR1LZ/l3gx0Iw==, tarball: file:projects/monitor-opentelemetry.tgz} + resolution: {integrity: sha512-HH9DSuPu9Flo0w2YXzGUnayl/lDLcTwcGEhht0VdjPe7ZwhakhOH8/VoxrZKQTdgseCZMpYDmWgB2BaKkUr/Mg==, tarball: file:projects/monitor-opentelemetry.tgz} version: 0.0.0 '@rush-temp/monitor-query@file:projects/monitor-query.tgz': - resolution: {integrity: sha512-FfDHQlhugBYGKJAG+Qvo0eA9RxpyaY0LHrPOjcmIyF8gy3hxeJf0+Z9/XSfi3jDrCdv+l1K3as1cbuiY48Or4Q==, tarball: file:projects/monitor-query.tgz} + resolution: {integrity: sha512-bQ0lyAnF/GBcL7pwA66f/U6sjezndhPmHkMCjdmz1MD93PYpaQvasNEGspFvjrnt8Xwcg0CmdnzeWbHE6obY1w==, tarball: file:projects/monitor-query.tgz} version: 0.0.0 '@rush-temp/notification-hubs@file:projects/notification-hubs.tgz': @@ -3912,7 +3912,7 @@ packages: version: 0.0.0 '@rush-temp/openai@file:projects/openai.tgz': - resolution: {integrity: sha512-QnN8rZhPnF3/GYsh3cLlyCb6JgnWdpPVrjGoau5jvxZQWcBIWb108P7yNZwXptJcPti/jGYJPFQuwRWW7CxgvA==, tarball: file:projects/openai.tgz} + resolution: {integrity: sha512-EB6z+wWho8coz2hCDFUcYTJ+Jw5CfJ20yzKpIZeNk4OxpglGY7XTSiWxsuCHa++eVGTTXRHMwG/gdOtAv9mZkw==, tarball: file:projects/openai.tgz} version: 0.0.0 '@rush-temp/opentelemetry-instrumentation-azure-sdk@file:projects/opentelemetry-instrumentation-azure-sdk.tgz': @@ -3980,7 +3980,7 @@ packages: version: 0.0.0 '@rush-temp/perf-monitor-opentelemetry@file:projects/perf-monitor-opentelemetry.tgz': - resolution: {integrity: sha512-dwzpNIZPU6i3RcqjhLVipjyiz3ZZMtjs7dOuCSH4TtaOyj5vgqVvQC61FbEsnQrI5coVWW0NEOmbNYbzkih1Yw==, tarball: file:projects/perf-monitor-opentelemetry.tgz} + resolution: {integrity: sha512-B6GNjGVtP+BWESkV/d2t2Kg4FhgyWAibL4khmjnhduwd14Cjtqf/Aoz7B71usfgEXEUE9KvkL3VUg2IVm+MLSw==, tarball: file:projects/perf-monitor-opentelemetry.tgz} version: 0.0.0 '@rush-temp/perf-monitor-query@file:projects/perf-monitor-query.tgz': @@ -4056,7 +4056,7 @@ packages: version: 0.0.0 '@rush-temp/service-bus@file:projects/service-bus.tgz': - resolution: {integrity: sha512-ICttr5Vkcza3Jpy5WP+rciaUvO8NRkplh7TEOk7RWExZR9GFF0hXTNbH11Id8/OSZ17v/vuWtwt+9GFLBeDsZw==, tarball: file:projects/service-bus.tgz} + resolution: {integrity: sha512-CEMwNWHdlbtYASoZFKNN3dzVF8Uno0LED5f7xmGV7kjawCq6iJuwxz4UhBDpDDdYYdG+cAIIcMZfUEj+cdcQsA==, tarball: file:projects/service-bus.tgz} version: 0.0.0 '@rush-temp/storage-blob-changefeed@file:projects/storage-blob-changefeed.tgz': @@ -6991,11 +6991,21 @@ packages: engines: {node: '>=18'} hasBin: true + playwright-core@1.51.0: + resolution: {integrity: sha512-x47yPE3Zwhlil7wlNU/iktF7t2r/URR3VLbH6EknJd/04Qc/PSJ0EY3CMXipmglLG+zyRxW6HNo2EGbKLHPWMg==} + engines: {node: '>=18'} + hasBin: true + playwright@1.50.1: resolution: {integrity: sha512-G8rwsOQJ63XG6BbKj2w5rHeavFjy5zynBA9zsJMMtBoe/Uf757oG12NXz6e6OirF7RCrTVAKFXbLmn1RbL7Qaw==} engines: {node: '>=18'} hasBin: true + playwright@1.51.0: + resolution: {integrity: sha512-442pTfGM0xxfCYxuBa/Pu6B2OqxqqaYq39JS8QDMGThUvIOCd6s0ANDog3uwA0cHavVlnTQzGCN7Id2YekDSXA==} + engines: {node: '>=18'} + hasBin: true + polite-json@5.0.0: resolution: {integrity: sha512-OLS/0XeUAcE8a2fdwemNja+udKgXNnY6yKVIXqAD2zVRx1KvY6Ato/rZ2vdzbxqYwPW0u6SCNC/bAMPNzpzxbw==} engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} @@ -10732,12 +10742,12 @@ snapshots: dependencies: '@azure/core-lro': 2.7.2 '@types/node': 18.19.76 - '@vitest/browser': 3.0.6(@types/node@18.19.76)(playwright@1.50.1)(typescript@5.7.3)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) + '@vitest/browser': 3.0.6(@types/node@18.19.76)(playwright@1.51.0)(typescript@5.6.3)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) '@vitest/coverage-istanbul': 3.0.6(vitest@3.0.6) dotenv: 16.4.7 - playwright: 1.50.1 + playwright: 1.51.0 tslib: 2.8.1 - typescript: 5.7.3 + typescript: 5.6.3 vitest: 3.0.6(@types/debug@4.1.12)(@types/node@18.19.76)(@vitest/browser@3.0.6)(msw@2.7.2(@types/node@22.7.9)(typescript@5.8.2))(tsx@4.19.3)(yaml@2.7.0) transitivePeerDependencies: - '@edge-runtime/vm' @@ -23879,7 +23889,7 @@ snapshots: '@types/chai-as-promised@7.1.8': dependencies: - '@types/chai': 4.3.20 + '@types/chai': 5.0.1 '@types/chai-as-promised@8.0.1': dependencies: @@ -24246,6 +24256,27 @@ snapshots: - utf-8-validate - vite + '@vitest/browser@3.0.6(@types/node@18.19.76)(playwright@1.51.0)(typescript@5.6.3)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6)': + dependencies: + '@testing-library/dom': 10.4.0 + '@testing-library/user-event': 14.6.1(@testing-library/dom@10.4.0) + '@vitest/mocker': 3.0.6(msw@2.7.2(@types/node@22.7.9)(typescript@5.8.2))(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0)) + '@vitest/utils': 3.0.6 + magic-string: 0.30.17 + msw: 2.7.2(@types/node@18.19.76)(typescript@5.6.3) + sirv: 3.0.1 + tinyrainbow: 2.0.0 + vitest: 3.0.6(@types/debug@4.1.12)(@types/node@22.7.9)(@vitest/browser@3.0.6)(msw@2.7.2(@types/node@22.7.9)(typescript@5.8.2))(tsx@4.19.3)(yaml@2.7.0) + ws: 8.18.1 + optionalDependencies: + playwright: 1.51.0 + transitivePeerDependencies: + - '@types/node' + - bufferutil + - typescript + - utf-8-validate + - vite + '@vitest/browser@3.0.6(@types/node@22.7.9)(playwright@1.50.1)(typescript@5.7.3)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6)': dependencies: '@testing-library/dom': 10.4.0 @@ -24267,7 +24298,7 @@ snapshots: - utf-8-validate - vite - '@vitest/browser@3.0.6(@types/node@22.7.9)(playwright@1.50.1)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6)': + '@vitest/browser@3.0.6(@types/node@22.7.9)(playwright@1.51.0)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6)': dependencies: '@testing-library/dom': 10.4.0 '@testing-library/user-event': 14.6.1(@testing-library/dom@10.4.0) @@ -24280,7 +24311,7 @@ snapshots: vitest: 3.0.6(@types/debug@4.1.12)(@types/node@22.7.9)(@vitest/browser@3.0.6)(msw@2.7.2(@types/node@22.7.9)(typescript@5.8.2))(tsx@4.19.3)(yaml@2.7.0) ws: 8.18.1 optionalDependencies: - playwright: 1.50.1 + playwright: 1.51.0 transitivePeerDependencies: - '@types/node' - bufferutil @@ -27044,12 +27075,20 @@ snapshots: playwright-core@1.50.1: {} + playwright-core@1.51.0: {} + playwright@1.50.1: dependencies: playwright-core: 1.50.1 optionalDependencies: fsevents: 2.3.2 + playwright@1.51.0: + dependencies: + playwright-core: 1.51.0 + optionalDependencies: + fsevents: 2.3.2 + polite-json@5.0.0: {} possible-typed-array-names@1.1.0: {} @@ -27933,7 +27972,7 @@ snapshots: resolve-import: 1.4.6 rimraf: 5.0.10 sync-content: 1.0.2 - typescript: 5.7.3 + typescript: 5.8.2 walk-up-path: 3.0.1 tslib@2.8.1: {} @@ -28210,7 +28249,7 @@ snapshots: optionalDependencies: '@types/debug': 4.1.12 '@types/node': 18.19.76 - '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.50.1)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) + '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.51.0)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) transitivePeerDependencies: - jiti - less @@ -28250,7 +28289,7 @@ snapshots: optionalDependencies: '@types/debug': 4.1.12 '@types/node': 20.17.19 - '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.50.1)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) + '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.51.0)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) transitivePeerDependencies: - jiti - less @@ -28290,7 +28329,7 @@ snapshots: optionalDependencies: '@types/debug': 4.1.12 '@types/node': 22.7.9 - '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.50.1)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) + '@vitest/browser': 3.0.6(@types/node@22.7.9)(playwright@1.51.0)(typescript@5.8.2)(vite@6.1.1(@types/node@22.7.9)(tsx@4.19.3)(yaml@2.7.0))(vitest@3.0.6) transitivePeerDependencies: - jiti - less diff --git a/sdk/appcontainers/arm-appcontainers/CHANGELOG.md b/sdk/appcontainers/arm-appcontainers/CHANGELOG.md index 146c15cc83c4..71d48ecca943 100644 --- a/sdk/appcontainers/arm-appcontainers/CHANGELOG.md +++ b/sdk/appcontainers/arm-appcontainers/CHANGELOG.md @@ -1,15 +1,107 @@ # Release History - -## 2.2.0-beta.2 (Unreleased) - + +## 2.2.0 (2025-03-07) + ### Features Added -### Breaking Changes - -### Bugs Fixed - -### Other Changes - + - Added operation group ContainerAppsSessionPools + - Added operation group JavaComponents + - Added Interface CertificateKeyVaultProperties + - Added Interface ContainerAppsSessionPoolsCreateOrUpdateOptionalParams + - Added Interface ContainerAppsSessionPoolsDeleteHeaders + - Added Interface ContainerAppsSessionPoolsDeleteOptionalParams + - Added Interface ContainerAppsSessionPoolsGetOptionalParams + - Added Interface ContainerAppsSessionPoolsListByResourceGroupNextOptionalParams + - Added Interface ContainerAppsSessionPoolsListByResourceGroupOptionalParams + - Added Interface ContainerAppsSessionPoolsListBySubscriptionNextOptionalParams + - Added Interface ContainerAppsSessionPoolsListBySubscriptionOptionalParams + - Added Interface ContainerAppsSessionPoolsUpdateHeaders + - Added Interface ContainerAppsSessionPoolsUpdateOptionalParams + - Added Interface CustomContainerTemplate + - Added Interface DynamicPoolConfiguration + - Added Interface JavaComponent + - Added Interface JavaComponentConfigurationProperty + - Added Interface JavaComponentIngress + - Added Interface JavaComponentProperties + - Added Interface JavaComponentPropertiesScale + - Added Interface JavaComponentsCollection + - Added Interface JavaComponentsCreateOrUpdateOptionalParams + - Added Interface JavaComponentsDeleteHeaders + - Added Interface JavaComponentsDeleteOptionalParams + - Added Interface JavaComponentServiceBind + - Added Interface JavaComponentsGetOptionalParams + - Added Interface JavaComponentsListNextOptionalParams + - Added Interface JavaComponentsListOptionalParams + - Added Interface JavaComponentsUpdateHeaders + - Added Interface JavaComponentsUpdateOptionalParams + - Added Interface LifecycleConfiguration + - Added Interface ManagedIdentitySetting + - Added Interface NfsAzureFileProperties + - Added Interface Runtime + - Added Interface RuntimeJava + - Added Interface ScaleConfiguration + - Added Interface SessionContainer + - Added Interface SessionContainerResources + - Added Interface SessionIngress + - Added Interface SessionNetworkConfiguration + - Added Interface SessionPool + - Added Interface SessionPoolCollection + - Added Interface SessionPoolSecret + - Added Interface SessionPoolUpdatableProperties + - Added Interface SessionRegistryCredentials + - Added Interface SpringBootAdminComponent + - Added Interface SpringCloudConfigComponent + - Added Interface SpringCloudEurekaComponent + - Added Type Alias ContainerAppRunningStatus + - Added Type Alias ContainerAppsSessionPoolsCreateOrUpdateResponse + - Added Type Alias ContainerAppsSessionPoolsDeleteResponse + - Added Type Alias ContainerAppsSessionPoolsGetResponse + - Added Type Alias ContainerAppsSessionPoolsListByResourceGroupNextResponse + - Added Type Alias ContainerAppsSessionPoolsListByResourceGroupResponse + - Added Type Alias ContainerAppsSessionPoolsListBySubscriptionNextResponse + - Added Type Alias ContainerAppsSessionPoolsListBySubscriptionResponse + - Added Type Alias ContainerAppsSessionPoolsUpdateResponse + - Added Type Alias ContainerType + - Added Type Alias IdentitySettingsLifeCycle + - Added Type Alias JavaComponentPropertiesUnion + - Added Type Alias JavaComponentProvisioningState + - Added Type Alias JavaComponentsCreateOrUpdateResponse + - Added Type Alias JavaComponentsDeleteResponse + - Added Type Alias JavaComponentsGetResponse + - Added Type Alias JavaComponentsListNextResponse + - Added Type Alias JavaComponentsListResponse + - Added Type Alias JavaComponentsUpdateResponse + - Added Type Alias JavaComponentType + - Added Type Alias LifecycleType + - Added Type Alias PoolManagementType + - Added Type Alias SessionNetworkStatus + - Added Type Alias SessionPoolProvisioningState + - Interface CertificateProperties has a new optional parameter certificateKeyVaultProperties + - Interface Configuration has a new optional parameter runtime + - Interface ContainerApp has a new optional parameter runningStatus + - Interface CustomDomainConfiguration has a new optional parameter certificateKeyVaultProperties + - Interface CustomScaleRule has a new optional parameter identity + - Interface HttpScaleRule has a new optional parameter identity + - Interface JobScaleRule has a new optional parameter identity + - Interface ManagedEnvironment has a new optional parameter identity + - Interface ManagedEnvironmentStorageProperties has a new optional parameter nfsAzureFile + - Interface QueueScaleRule has a new optional parameter accountName + - Interface QueueScaleRule has a new optional parameter identity + - Interface Scale has a new optional parameter cooldownPeriod + - Interface Scale has a new optional parameter pollingInterval + - Interface TcpScaleRule has a new optional parameter identity + - Added Enum KnownContainerAppRunningStatus + - Added Enum KnownContainerType + - Added Enum KnownIdentitySettingsLifeCycle + - Added Enum KnownJavaComponentProvisioningState + - Added Enum KnownJavaComponentType + - Added Enum KnownLifecycleType + - Added Enum KnownPoolManagementType + - Added Enum KnownSessionNetworkStatus + - Added Enum KnownSessionPoolProvisioningState + - Enum KnownStorageType has a new value NfsAzureFile + + ## 2.2.0-beta.1 (2024-10-18) Compared with version 2.1.0 diff --git a/sdk/appcontainers/arm-appcontainers/LICENSE b/sdk/appcontainers/arm-appcontainers/LICENSE index b2f52a2bad4e..63447fd8bbbf 100644 --- a/sdk/appcontainers/arm-appcontainers/LICENSE +++ b/sdk/appcontainers/arm-appcontainers/LICENSE @@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +SOFTWARE. \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/README.md b/sdk/appcontainers/arm-appcontainers/README.md index 31f0739d6215..4651e200d168 100644 --- a/sdk/appcontainers/arm-appcontainers/README.md +++ b/sdk/appcontainers/arm-appcontainers/README.md @@ -2,11 +2,11 @@ This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure ContainerApps API client. -Functions is an extension resource to revisions and the api listed is used to proxy the call from Web RP to the function app's host process, this api is not exposed to users and only Web RP is allowed to invoke functions extension resource. + [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers) | [Package (NPM)](https://www.npmjs.com/package/@azure/arm-appcontainers) | -[API reference documentation](https://learn.microsoft.com/javascript/api/@azure/arm-appcontainers?view=azure-node-preview) | +[API reference documentation](https://learn.microsoft.com/javascript/api/@azure/arm-appcontainers) | [Samples](https://github.com/Azure-Samples/azure-samples-js-management) ## Getting started @@ -44,7 +44,6 @@ npm install @azure/identity ``` You will also need to **register a new AAD application and grant access to Azure ContainerApps API** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions). -Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`. For more information about how to create an Azure AD Application check out [this guide](https://learn.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal). @@ -64,16 +63,14 @@ For browser environments, use the `InteractiveBrowserCredential` from the `@azur import { InteractiveBrowserCredential } from "@azure/identity"; import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -const subscriptionId = "00000000-0000-0000-0000-000000000000"; const credential = new InteractiveBrowserCredential({ tenantId: "", - clientId: "", -}); + clientId: "" + }); const client = new ContainerAppsAPIClient(credential, subscriptionId); ``` ### JavaScript Bundle - To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling). ## Key concepts @@ -108,7 +105,7 @@ If you'd like to contribute to this library, please read the [contributing guide - [Microsoft Azure SDK for JavaScript](https://github.com/Azure/azure-sdk-for-js) - +![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Fappcontainers%2Farm-appcontainers%2FREADME.png) [azure_cli]: https://learn.microsoft.com/cli/azure [azure_sub]: https://azure.microsoft.com/free/ diff --git a/sdk/appcontainers/arm-appcontainers/_meta.json b/sdk/appcontainers/arm-appcontainers/_meta.json index c4cbe15de54a..c65274825458 100644 --- a/sdk/appcontainers/arm-appcontainers/_meta.json +++ b/sdk/appcontainers/arm-appcontainers/_meta.json @@ -1,8 +1,8 @@ { - "commit": "abe3209e7c6924a58ab560ebab2349bc8fde6aa7", + "commit": "d8bfad13bd9f03808044ef8c8d953894d4cc8976", "readme": "specification/app/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.7 --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\\app\\resource-manager\\readme.md --use=@autorest/typescript@6.0.27 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/app/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.15", - "use": "@autorest/typescript@6.0.27" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.21", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/api-extractor.json b/sdk/appcontainers/arm-appcontainers/api-extractor.json index 63d7d7d4a422..05e35e108750 100644 --- a/sdk/appcontainers/arm-appcontainers/api-extractor.json +++ b/sdk/appcontainers/arm-appcontainers/api-extractor.json @@ -1,6 +1,6 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", - "mainEntryPointFilePath": "dist/esm/index.d.ts", + "mainEntryPointFilePath": "./dist-esm/src/index.d.ts", "docModel": { "enabled": true }, @@ -11,7 +11,7 @@ "dtsRollup": { "enabled": true, "untrimmedFilePath": "", - "publicTrimmedFilePath": "dist/arm-appcontainers.d.ts" + "publicTrimmedFilePath": "./types/arm-appcontainers.d.ts" }, "messages": { "tsdocMessageReporting": { @@ -28,4 +28,4 @@ } } } -} +} \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/assets.json b/sdk/appcontainers/arm-appcontainers/assets.json deleted file mode 100644 index a907a1588e05..000000000000 --- a/sdk/appcontainers/arm-appcontainers/assets.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "AssetsRepo": "Azure/azure-sdk-assets", - "AssetsRepoPrefixPath": "js", - "TagPrefix": "js/appcontainers/arm-appcontainers", - "Tag": "js/appcontainers/arm-appcontainers_44aafabde5" -} diff --git a/sdk/appcontainers/arm-appcontainers/package.json b/sdk/appcontainers/arm-appcontainers/package.json index b39cd50cc339..fb055334fe62 100644 --- a/sdk/appcontainers/arm-appcontainers/package.json +++ b/sdk/appcontainers/arm-appcontainers/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ContainerAppsAPIClient.", - "version": "2.2.0-beta.2", + "version": "2.2.0", "engines": { "node": ">=18.0.0" }, "dependencies": { "@azure/abort-controller": "^2.1.2", "@azure/core-auth": "^1.9.0", - "@azure/core-client": "^1.9.2", + "@azure/core-client": "^1.9.3", "@azure/core-lro": "^2.5.4", "@azure/core-paging": "^1.6.2", - "@azure/core-rest-pipeline": "^1.18.1", + "@azure/core-rest-pipeline": "^1.19.1", "tslib": "^2.8.1" }, "keywords": [ @@ -21,29 +21,31 @@ "azure", "typescript", "browser", - "isomorphic", - "cloud" + "isomorphic" ], "license": "MIT", "main": "./dist/commonjs/index.js", - "module": "./dist/esm/index.js", + "module": "./dist-esm/src/index.js", "types": "./dist/commonjs/index.d.ts", "devDependencies": { "@azure-tools/test-credential": "^2.0.0", "@azure-tools/test-recorder": "^4.1.0", "@azure-tools/test-utils-vitest": "^1.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.5.0", + "@azure/identity": "^4.7.0", "@azure/logger": "^1.1.4", "@types/node": "^18.0.0", - "@vitest/browser": "^3.0.3", - "@vitest/coverage-istanbul": "^3.0.3", + "@vitest/browser": "^3.0.6", + "@vitest/coverage-istanbul": "^3.0.6", "dotenv": "^16.0.0", - "playwright": "^1.49.1", - "typescript": "~5.7.2", - "vitest": "^3.0.3" + "playwright": "^1.51.0", + "typescript": "~5.6.2", + "vitest": "^3.0.6" + }, + "repository": { + "type": "git", + "url": "https://github.com/Azure/azure-sdk-for-js.git" }, - "repository": "github:Azure/azure-sdk-for-js", "bugs": { "url": "https://github.com/Azure/azure-sdk-for-js/issues" }, @@ -91,14 +93,6 @@ }, "autoPublish": true, "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://learn.microsoft.com/javascript/api/@azure/arm-appcontainers?view=azure-node-preview" - }, "type": "module", "tshy": { "project": "./tsconfig.src.json", @@ -139,4 +133,4 @@ } } } -} +} \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/review/arm-appcontainers.api.md b/sdk/appcontainers/arm-appcontainers/review/arm-appcontainers.api.md index ebd783c5e11a..96d49559fbea 100644 --- a/sdk/appcontainers/arm-appcontainers/review/arm-appcontainers.api.md +++ b/sdk/appcontainers/arm-appcontainers/review/arm-appcontainers.api.md @@ -33,11 +33,6 @@ export interface AllowedPrincipals { identities?: string[]; } -// @public -export interface AppInsightsConfiguration { - connectionString?: string; -} - // @public export interface Apple { enabled?: boolean; @@ -69,70 +64,6 @@ export interface AppRegistration { appSecretSettingName?: string; } -// @public -export interface AppResiliency extends ProxyResource { - circuitBreakerPolicy?: CircuitBreakerPolicy; - httpConnectionPool?: HttpConnectionPool; - httpRetryPolicy?: HttpRetryPolicy; - tcpConnectionPool?: TcpConnectionPool; - tcpRetryPolicy?: TcpRetryPolicy; - timeoutPolicy?: TimeoutPolicy; -} - -// @public -export interface AppResiliencyCollection { - readonly nextLink?: string; - value: AppResiliency[]; -} - -// @public -export interface AppResiliencyCreateOrUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type AppResiliencyCreateOrUpdateResponse = AppResiliency; - -// @public -export interface AppResiliencyDeleteOptionalParams extends coreClient.OperationOptions { -} - -// @public -export interface AppResiliencyGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type AppResiliencyGetResponse = AppResiliency; - -// @public -export interface AppResiliencyListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type AppResiliencyListNextResponse = AppResiliencyCollection; - -// @public -export interface AppResiliencyListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type AppResiliencyListResponse = AppResiliencyCollection; - -// @public -export interface AppResiliencyOperations { - createOrUpdate(resourceGroupName: string, appName: string, name: string, resiliencyEnvelope: AppResiliency, options?: AppResiliencyCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, appName: string, name: string, options?: AppResiliencyDeleteOptionalParams): Promise; - get(resourceGroupName: string, appName: string, name: string, options?: AppResiliencyGetOptionalParams): Promise; - list(resourceGroupName: string, appName: string, options?: AppResiliencyListOptionalParams): PagedAsyncIterableIterator; - update(resourceGroupName: string, appName: string, name: string, resiliencyEnvelope: AppResiliency, options?: AppResiliencyUpdateOptionalParams): Promise; -} - -// @public -export interface AppResiliencyUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type AppResiliencyUpdateResponse = AppResiliency; - // @public export interface AuthConfig extends ProxyResource { encryptionSettings?: EncryptionSettings; @@ -268,20 +199,15 @@ export interface BaseContainer { command?: string[]; env?: EnvironmentVar[]; image?: string; - imageType?: ImageType; name?: string; resources?: ContainerResources; volumeMounts?: VolumeMount[]; } // @public -export interface BillingMeter { - readonly id?: string; +export interface BillingMeter extends ProxyResource { location?: string; - readonly name?: string; properties?: BillingMeterProperties; - readonly systemData?: SystemData; - readonly type?: string; } // @public @@ -316,240 +242,6 @@ export interface BlobStorageTokenStore { sasUrlSettingName: string; } -// @public -export interface BuildAuthToken { - list(resourceGroupName: string, builderName: string, buildName: string, options?: BuildAuthTokenListOptionalParams): Promise; -} - -// @public -export interface BuildAuthTokenListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildAuthTokenListResponse = BuildToken; - -// @public -export interface BuildCollection { - nextLink?: string; - value: BuildResource[]; -} - -// @public -export interface BuildConfiguration { - baseOs?: string; - environmentVariables?: EnvironmentVariable[]; - platform?: string; - platformVersion?: string; - preBuildSteps?: PreBuildStep[]; -} - -// @public -export interface BuilderCollection { - nextLink?: string; - value: BuilderResource[]; -} - -// @public -export type BuilderProvisioningState = string; - -// @public -export interface BuilderResource extends TrackedResource { - containerRegistries?: ContainerRegistry[]; - environmentId?: string; - identity?: ManagedServiceIdentity; - readonly provisioningState?: BuilderProvisioningState; -} - -// @public -export interface BuilderResourceUpdate { - environmentId?: string; - identity?: ManagedServiceIdentity; - tags?: { - [propertyName: string]: string; - }; -} - -// @public -export interface Builders { - beginCreateOrUpdate(resourceGroupName: string, builderName: string, builderEnvelope: BuilderResource, options?: BuildersCreateOrUpdateOptionalParams): Promise, BuildersCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, builderName: string, builderEnvelope: BuilderResource, options?: BuildersCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, builderName: string, options?: BuildersDeleteOptionalParams): Promise, BuildersDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, builderName: string, options?: BuildersDeleteOptionalParams): Promise; - beginUpdate(resourceGroupName: string, builderName: string, builderEnvelope: BuilderResourceUpdate, options?: BuildersUpdateOptionalParams): Promise, BuildersUpdateResponse>>; - beginUpdateAndWait(resourceGroupName: string, builderName: string, builderEnvelope: BuilderResourceUpdate, options?: BuildersUpdateOptionalParams): Promise; - get(resourceGroupName: string, builderName: string, options?: BuildersGetOptionalParams): Promise; - listByResourceGroup(resourceGroupName: string, options?: BuildersListByResourceGroupOptionalParams): PagedAsyncIterableIterator; - listBySubscription(options?: BuildersListBySubscriptionOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface BuildersCreateOrUpdateHeaders { - // (undocumented) - azureAsyncOperation?: string; -} - -// @public -export interface BuildersCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type BuildersCreateOrUpdateResponse = BuilderResource; - -// @public -export interface BuildersDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface BuildersDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type BuildersDeleteResponse = BuildersDeleteHeaders; - -// @public -export interface BuildersGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildersGetResponse = BuilderResource; - -// @public -export interface BuildersListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildersListByResourceGroupNextResponse = BuilderCollection; - -// @public -export interface BuildersListByResourceGroupOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildersListByResourceGroupResponse = BuilderCollection; - -// @public -export interface BuildersListBySubscriptionNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildersListBySubscriptionNextResponse = BuilderCollection; - -// @public -export interface BuildersListBySubscriptionOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildersListBySubscriptionResponse = BuilderCollection; - -// @public -export interface BuildersUpdateHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface BuildersUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type BuildersUpdateResponse = BuilderResource; - -// @public -export type BuildProvisioningState = string; - -// @public -export interface BuildResource extends ProxyResource { - readonly buildStatus?: BuildStatus; - configuration?: BuildConfiguration; - destinationContainerRegistry?: ContainerRegistryWithCustomImage; - readonly logStreamEndpoint?: string; - readonly provisioningState?: BuildProvisioningState; - readonly tokenEndpoint?: string; - readonly uploadEndpoint?: string; -} - -// @public -export interface Builds { - beginCreateOrUpdate(resourceGroupName: string, builderName: string, buildName: string, buildEnvelope: BuildResource, options?: BuildsCreateOrUpdateOptionalParams): Promise, BuildsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, builderName: string, buildName: string, buildEnvelope: BuildResource, options?: BuildsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, builderName: string, buildName: string, options?: BuildsDeleteOptionalParams): Promise, BuildsDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, builderName: string, buildName: string, options?: BuildsDeleteOptionalParams): Promise; - get(resourceGroupName: string, builderName: string, buildName: string, options?: BuildsGetOptionalParams): Promise; -} - -// @public -export interface BuildsByBuilderResource { - list(resourceGroupName: string, builderName: string, options?: BuildsByBuilderResourceListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface BuildsByBuilderResourceListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildsByBuilderResourceListNextResponse = BuildCollection; - -// @public -export interface BuildsByBuilderResourceListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildsByBuilderResourceListResponse = BuildCollection; - -// @public -export interface BuildsCreateOrUpdateHeaders { - // (undocumented) - azureAsyncOperation?: string; -} - -// @public -export interface BuildsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type BuildsCreateOrUpdateResponse = BuildResource; - -// @public -export interface BuildsDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface BuildsDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type BuildsDeleteResponse = BuildsDeleteHeaders; - -// @public -export interface BuildsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type BuildsGetResponse = BuildResource; - -// @public -export type BuildStatus = string; - -// @public -export interface BuildToken { - readonly expires?: Date; - readonly token?: string; -} - // @public export interface Certificate extends TrackedResource { properties?: CertificateProperties; @@ -577,7 +269,6 @@ export interface CertificatePatch { // @public export interface CertificateProperties { certificateKeyVaultProperties?: CertificateKeyVaultProperties; - certificateType?: CertificateType; readonly expirationDate?: Date; readonly issueDate?: Date; readonly issuer?: string; @@ -643,9 +334,6 @@ export interface CertificatesUpdateOptionalParams extends coreClient.OperationOp // @public export type CertificatesUpdateResponse = Certificate; -// @public -export type CertificateType = string; - // @public export type CheckNameAvailabilityReason = string; @@ -662,13 +350,6 @@ export interface CheckNameAvailabilityResponse { reason?: CheckNameAvailabilityReason; } -// @public -export interface CircuitBreakerPolicy { - consecutiveErrors?: number; - intervalInSeconds?: number; - maxEjectionPercent?: number; -} - // @public export interface ClientRegistration { clientId?: string; @@ -679,7 +360,6 @@ export interface ClientRegistration { export interface Configuration { activeRevisionsMode?: ActiveRevisionsMode; dapr?: Dapr; - identitySettings?: IdentitySettings[]; ingress?: Ingress; maxInactiveRevisions?: number; registries?: RegistryCredentials[]; @@ -922,7 +602,6 @@ export interface ConnectedEnvironmentStorage extends ProxyResource { // @public export interface ConnectedEnvironmentStorageProperties { azureFile?: AzureFileProperties; - smb?: SmbStorage; } // @public @@ -946,20 +625,18 @@ export interface Container extends BaseContainer { export interface ContainerApp extends TrackedResource { configuration?: Configuration; readonly customDomainVerificationId?: string; - readonly deploymentErrors?: string; environmentId?: string; readonly eventStreamEndpoint?: string; extendedLocation?: ExtendedLocation; identity?: ManagedServiceIdentity; - kind?: Kind; readonly latestReadyRevisionName?: string; readonly latestRevisionFqdn?: string; readonly latestRevisionName?: string; managedBy?: string; managedEnvironmentId?: string; readonly outboundIpAddresses?: string[]; - patchingConfiguration?: ContainerAppPropertiesPatchingConfiguration; readonly provisioningState?: ContainerAppProvisioningState; + readonly runningStatus?: ContainerAppRunningStatus; template?: Template; workloadProfileName?: string; } @@ -1019,17 +696,15 @@ export interface ContainerAppProbeTcpSocket { port: number; } -// @public -export interface ContainerAppPropertiesPatchingConfiguration { - patchingMode?: PatchingMode; -} - // @public export type ContainerAppProvisioningState = string; // @public export type ContainerAppReplicaRunningState = string; +// @public +export type ContainerAppRunningStatus = string; + // @public export interface ContainerApps { beginCreateOrUpdate(resourceGroupName: string, containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise, ContainerAppsCreateOrUpdateResponse>>; @@ -1058,20 +733,10 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) apiVersion: string; // (undocumented) - appResiliencyOperations: AppResiliencyOperations; - // (undocumented) availableWorkloadProfiles: AvailableWorkloadProfiles; // (undocumented) billingMeters: BillingMeters; // (undocumented) - buildAuthToken: BuildAuthToken; - // (undocumented) - builders: Builders; - // (undocumented) - builds: Builds; - // (undocumented) - buildsByBuilderResource: BuildsByBuilderResource; - // (undocumented) certificates: Certificates; // (undocumented) connectedEnvironments: ConnectedEnvironments; @@ -1086,14 +751,8 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) containerAppsAuthConfigs: ContainerAppsAuthConfigs; // (undocumented) - containerAppsBuilds: ContainerAppsBuilds; - // (undocumented) - containerAppsBuildsByContainerApp: ContainerAppsBuildsByContainerApp; - // (undocumented) containerAppsDiagnostics: ContainerAppsDiagnostics; // (undocumented) - containerAppsPatches: ContainerAppsPatches; - // (undocumented) containerAppsRevisionReplicas: ContainerAppsRevisionReplicas; // (undocumented) containerAppsRevisions: ContainerAppsRevisions; @@ -1102,15 +761,7 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) containerAppsSourceControls: ContainerAppsSourceControls; // (undocumented) - daprComponentResiliencyPolicies: DaprComponentResiliencyPolicies; - // (undocumented) daprComponents: DaprComponents; - // (undocumented) - daprSubscriptions: DaprSubscriptions; - // (undocumented) - dotNetComponents: DotNetComponents; - // (undocumented) - functionsExtension: FunctionsExtension; getCustomDomainVerificationId(options?: GetCustomDomainVerificationIdOptionalParams): Promise; // (undocumented) javaComponents: JavaComponents; @@ -1120,16 +771,10 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) jobsExecutions: JobsExecutions; // (undocumented) - logicApps: LogicApps; - // (undocumented) managedCertificates: ManagedCertificates; // (undocumented) managedEnvironmentDiagnostics: ManagedEnvironmentDiagnostics; // (undocumented) - managedEnvironmentPrivateEndpointConnections: ManagedEnvironmentPrivateEndpointConnections; - // (undocumented) - managedEnvironmentPrivateLinkResources: ManagedEnvironmentPrivateLinkResources; - // (undocumented) managedEnvironments: ManagedEnvironments; // (undocumented) managedEnvironmentsDiagnostics: ManagedEnvironmentsDiagnostics; @@ -1195,127 +840,55 @@ export interface ContainerAppsAuthConfigsListByContainerAppOptionalParams extend export type ContainerAppsAuthConfigsListByContainerAppResponse = AuthConfigCollection; // @public -export interface ContainerAppsBuildCollection { - nextLink?: string; - value: ContainerAppsBuildResource[]; +export interface ContainerAppsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public -export interface ContainerAppsBuildConfiguration { - readonly baseOs?: string; - readonly environmentVariables?: EnvironmentVariable[]; - readonly platform?: string; - readonly platformVersion?: string; - readonly preBuildSteps?: PreBuildStep[]; -} +export type ContainerAppsCreateOrUpdateResponse = ContainerApp; // @public -export interface ContainerAppsBuildResource extends ProxyResource { - readonly buildStatus?: BuildStatus; - readonly configuration?: ContainerAppsBuildConfiguration; - readonly destinationContainerRegistry?: ContainerRegistryWithCustomImage; - readonly logStreamEndpoint?: string; - readonly provisioningState?: BuildProvisioningState; +export interface ContainerAppsDeleteHeaders { + // (undocumented) + location?: string; } // @public -export interface ContainerAppsBuilds { - beginDelete(resourceGroupName: string, containerAppName: string, buildName: string, options?: ContainerAppsBuildsDeleteOptionalParams): Promise, ContainerAppsBuildsDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, containerAppName: string, buildName: string, options?: ContainerAppsBuildsDeleteOptionalParams): Promise; - get(resourceGroupName: string, containerAppName: string, buildName: string, options?: ContainerAppsBuildsGetOptionalParams): Promise; +export interface ContainerAppsDeleteOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public -export interface ContainerAppsBuildsByContainerApp { - list(resourceGroupName: string, containerAppName: string, options?: ContainerAppsBuildsByContainerAppListOptionalParams): PagedAsyncIterableIterator; +export interface ContainerAppsDiagnostics { + getDetector(resourceGroupName: string, containerAppName: string, detectorName: string, options?: ContainerAppsDiagnosticsGetDetectorOptionalParams): Promise; + getRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsDiagnosticsGetRevisionOptionalParams): Promise; + getRoot(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsGetRootOptionalParams): Promise; + listDetectors(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsListDetectorsOptionalParams): PagedAsyncIterableIterator; + listRevisions(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsListRevisionsOptionalParams): PagedAsyncIterableIterator; } // @public -export interface ContainerAppsBuildsByContainerAppListNextOptionalParams extends coreClient.OperationOptions { +export interface ContainerAppsDiagnosticsGetDetectorOptionalParams extends coreClient.OperationOptions { } // @public -export type ContainerAppsBuildsByContainerAppListNextResponse = ContainerAppsBuildCollection; +export type ContainerAppsDiagnosticsGetDetectorResponse = Diagnostics; // @public -export interface ContainerAppsBuildsByContainerAppListOptionalParams extends coreClient.OperationOptions { +export interface ContainerAppsDiagnosticsGetRevisionOptionalParams extends coreClient.OperationOptions { } // @public -export type ContainerAppsBuildsByContainerAppListResponse = ContainerAppsBuildCollection; +export type ContainerAppsDiagnosticsGetRevisionResponse = Revision; // @public -export interface ContainerAppsBuildsDeleteHeaders { - // (undocumented) - location?: string; +export interface ContainerAppsDiagnosticsGetRootOptionalParams extends coreClient.OperationOptions { } // @public -export interface ContainerAppsBuildsDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ContainerAppsBuildsDeleteResponse = ContainerAppsBuildsDeleteHeaders; - -// @public -export interface ContainerAppsBuildsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsBuildsGetResponse = ContainerAppsBuildResource; - -// @public -export interface ContainerAppsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ContainerAppsCreateOrUpdateResponse = ContainerApp; - -// @public -export interface ContainerAppsDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface ContainerAppsDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export interface ContainerAppsDiagnostics { - getDetector(resourceGroupName: string, containerAppName: string, detectorName: string, options?: ContainerAppsDiagnosticsGetDetectorOptionalParams): Promise; - getRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsDiagnosticsGetRevisionOptionalParams): Promise; - getRoot(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsGetRootOptionalParams): Promise; - listDetectors(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsListDetectorsOptionalParams): PagedAsyncIterableIterator; - listRevisions(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDiagnosticsListRevisionsOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface ContainerAppsDiagnosticsGetDetectorOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsDiagnosticsGetDetectorResponse = Diagnostics; - -// @public -export interface ContainerAppsDiagnosticsGetRevisionOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsDiagnosticsGetRevisionResponse = Revision; - -// @public -export interface ContainerAppsDiagnosticsGetRootOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsDiagnosticsGetRootResponse = ContainerApp; +export type ContainerAppsDiagnosticsGetRootResponse = ContainerApp; // @public export interface ContainerAppsDiagnosticsListDetectorsNextOptionalParams extends coreClient.OperationOptions { @@ -1411,92 +984,6 @@ export interface ContainerAppsListSecretsOptionalParams extends coreClient.Opera // @public export type ContainerAppsListSecretsResponse = SecretsCollection; -// @public -export interface ContainerAppsPatches { - beginApply(resourceGroupName: string, containerAppName: string, patchName: string, options?: ContainerAppsPatchesApplyOptionalParams): Promise, ContainerAppsPatchesApplyResponse>>; - beginApplyAndWait(resourceGroupName: string, containerAppName: string, patchName: string, options?: ContainerAppsPatchesApplyOptionalParams): Promise; - beginDelete(resourceGroupName: string, containerAppName: string, patchName: string, options?: ContainerAppsPatchesDeleteOptionalParams): Promise, ContainerAppsPatchesDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, containerAppName: string, patchName: string, options?: ContainerAppsPatchesDeleteOptionalParams): Promise; - beginSkipConfigure(resourceGroupName: string, containerAppName: string, patchName: string, patchSkipConfig: PatchSkipConfig, options?: ContainerAppsPatchesSkipConfigureOptionalParams): Promise, ContainerAppsPatchesSkipConfigureResponse>>; - beginSkipConfigureAndWait(resourceGroupName: string, containerAppName: string, patchName: string, patchSkipConfig: PatchSkipConfig, options?: ContainerAppsPatchesSkipConfigureOptionalParams): Promise; - get(resourceGroupName: string, containerAppName: string, patchName: string, options?: ContainerAppsPatchesGetOptionalParams): Promise; - listByContainerApp(resourceGroupName: string, containerAppName: string, options?: ContainerAppsPatchesListByContainerAppOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface ContainerAppsPatchesApplyHeaders { - // (undocumented) - azureAsyncOperation?: string; - // (undocumented) - location?: string; -} - -// @public -export interface ContainerAppsPatchesApplyOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ContainerAppsPatchesApplyResponse = ContainerAppsPatchResource; - -// @public -export interface ContainerAppsPatchesDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface ContainerAppsPatchesDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ContainerAppsPatchesDeleteResponse = ContainerAppsPatchesDeleteHeaders; - -// @public -export interface ContainerAppsPatchesGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsPatchesGetResponse = ContainerAppsPatchResource; - -// @public -export interface ContainerAppsPatchesListByContainerAppNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ContainerAppsPatchesListByContainerAppNextResponse = PatchCollection; - -// @public -export interface ContainerAppsPatchesListByContainerAppOptionalParams extends coreClient.OperationOptions { - filter?: string; -} - -// @public -export type ContainerAppsPatchesListByContainerAppResponse = PatchCollection; - -// @public -export interface ContainerAppsPatchesSkipConfigureHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface ContainerAppsPatchesSkipConfigureOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ContainerAppsPatchesSkipConfigureResponse = ContainerAppsPatchesSkipConfigureHeaders; - -// @public -export interface ContainerAppsPatchResource extends ProxyResource { - readonly properties?: PatchProperties; -} - // @public export interface ContainerAppsRevisionReplicas { getReplica(resourceGroupName: string, containerAppName: string, revisionName: string, replicaName: string, options?: ContainerAppsRevisionReplicasGetReplicaOptionalParams): Promise; @@ -1661,7 +1148,6 @@ export interface ContainerAppsSourceControls { export interface ContainerAppsSourceControlsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; updateIntervalInMs?: number; - xMsGithubAuxiliary?: string; } // @public @@ -1669,11 +1155,8 @@ export type ContainerAppsSourceControlsCreateOrUpdateResponse = SourceControl; // @public export interface ContainerAppsSourceControlsDeleteOptionalParams extends coreClient.OperationOptions { - deleteWorkflow?: boolean; - ignoreWorkflowDeletionFailure?: boolean; resumeFrom?: string; updateIntervalInMs?: number; - xMsGithubAuxiliary?: string; } // @public @@ -1742,26 +1225,6 @@ export interface ContainerAppsUpdateOptionalParams extends coreClient.OperationO // @public export type ContainerAppsUpdateResponse = ContainerApp; -// @public -export interface ContainerExecutionStatus { - additionalInformation?: string; - code?: number; - name?: string; - status?: string; -} - -// @public -export interface ContainerRegistry { - containerRegistryServer: string; - identityResourceId: string; -} - -// @public -export interface ContainerRegistryWithCustomImage { - image?: string; - server: string; -} - // @public export interface ContainerResources { cpu?: number; @@ -1889,93 +1352,9 @@ export interface DaprComponent extends ProxyResource { scopes?: string[]; secrets?: Secret[]; secretStoreComponent?: string; - serviceComponentBind?: DaprComponentServiceBinding[]; version?: string; } -// @public -export interface DaprComponentResiliencyPolicies { - createOrUpdate(resourceGroupName: string, environmentName: string, componentName: string, name: string, daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy, options?: DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, environmentName: string, componentName: string, name: string, options?: DaprComponentResiliencyPoliciesDeleteOptionalParams): Promise; - get(resourceGroupName: string, environmentName: string, componentName: string, name: string, options?: DaprComponentResiliencyPoliciesGetOptionalParams): Promise; - list(resourceGroupName: string, environmentName: string, componentName: string, options?: DaprComponentResiliencyPoliciesListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface DaprComponentResiliencyPoliciesCollection { - readonly nextLink?: string; - value: DaprComponentResiliencyPolicy[]; -} - -// @public -export interface DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprComponentResiliencyPoliciesCreateOrUpdateResponse = DaprComponentResiliencyPolicy; - -// @public -export interface DaprComponentResiliencyPoliciesDeleteOptionalParams extends coreClient.OperationOptions { -} - -// @public -export interface DaprComponentResiliencyPoliciesGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprComponentResiliencyPoliciesGetResponse = DaprComponentResiliencyPolicy; - -// @public -export interface DaprComponentResiliencyPoliciesListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprComponentResiliencyPoliciesListNextResponse = DaprComponentResiliencyPoliciesCollection; - -// @public -export interface DaprComponentResiliencyPoliciesListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprComponentResiliencyPoliciesListResponse = DaprComponentResiliencyPoliciesCollection; - -// @public -export interface DaprComponentResiliencyPolicy extends ProxyResource { - inboundPolicy?: DaprComponentResiliencyPolicyConfiguration; - outboundPolicy?: DaprComponentResiliencyPolicyConfiguration; -} - -// @public -export interface DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration { - consecutiveErrors?: number; - intervalInSeconds?: number; - timeoutInSeconds?: number; -} - -// @public -export interface DaprComponentResiliencyPolicyConfiguration { - circuitBreakerPolicy?: DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration; - httpRetryPolicy?: DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration; - timeoutPolicy?: DaprComponentResiliencyPolicyTimeoutPolicyConfiguration; -} - -// @public -export interface DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration { - initialDelayInMilliseconds?: number; - maxIntervalInMilliseconds?: number; -} - -// @public -export interface DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration { - maxRetries?: number; - retryBackOff?: DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration; -} - -// @public -export interface DaprComponentResiliencyPolicyTimeoutPolicyConfiguration { - responseTimeoutInSeconds?: number; -} - // @public export interface DaprComponents { createOrUpdate(resourceGroupName: string, environmentName: string, componentName: string, daprComponentEnvelope: DaprComponent, options?: DaprComponentsCreateOrUpdateOptionalParams): Promise; @@ -2002,13 +1381,6 @@ export type DaprComponentsCreateOrUpdateResponse = DaprComponent; export interface DaprComponentsDeleteOptionalParams extends coreClient.OperationOptions { } -// @public -export interface DaprComponentServiceBinding { - metadata?: DaprServiceBindMetadata; - name?: string; - serviceId?: string; -} - // @public export interface DaprComponentsGetOptionalParams extends coreClient.OperationOptions { } @@ -2060,96 +1432,6 @@ export interface DaprSecretsCollection { value: DaprSecret[]; } -// @public -export interface DaprServiceBindMetadata { - name?: string; - value?: string; -} - -// @public -export interface DaprSubscription extends ProxyResource { - bulkSubscribe?: DaprSubscriptionBulkSubscribeOptions; - deadLetterTopic?: string; - metadata?: { - [propertyName: string]: string; - }; - pubsubName?: string; - routes?: DaprSubscriptionRoutes; - scopes?: string[]; - topic?: string; -} - -// @public -export interface DaprSubscriptionBulkSubscribeOptions { - enabled?: boolean; - maxAwaitDurationMs?: number; - maxMessagesCount?: number; -} - -// @public -export interface DaprSubscriptionRouteRule { - match?: string; - path?: string; -} - -// @public -export interface DaprSubscriptionRoutes { - default?: string; - rules?: DaprSubscriptionRouteRule[]; -} - -// @public -export interface DaprSubscriptions { - createOrUpdate(resourceGroupName: string, environmentName: string, name: string, daprSubscriptionEnvelope: DaprSubscription, options?: DaprSubscriptionsCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, environmentName: string, name: string, options?: DaprSubscriptionsDeleteOptionalParams): Promise; - get(resourceGroupName: string, environmentName: string, name: string, options?: DaprSubscriptionsGetOptionalParams): Promise; - list(resourceGroupName: string, environmentName: string, options?: DaprSubscriptionsListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface DaprSubscriptionsCollection { - readonly nextLink?: string; - value: DaprSubscription[]; -} - -// @public -export interface DaprSubscriptionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprSubscriptionsCreateOrUpdateResponse = DaprSubscription; - -// @public -export interface DaprSubscriptionsDeleteOptionalParams extends coreClient.OperationOptions { -} - -// @public -export interface DaprSubscriptionsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprSubscriptionsGetResponse = DaprSubscription; - -// @public -export interface DaprSubscriptionsListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprSubscriptionsListNextResponse = DaprSubscriptionsCollection; - -// @public -export interface DaprSubscriptionsListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DaprSubscriptionsListResponse = DaprSubscriptionsCollection; - -// @public -export interface DataDogConfiguration { - key?: string; - site?: string; -} - // @public export interface DefaultAuthorizationPolicy { allowedApplications?: string[]; @@ -2177,15 +1459,6 @@ export interface DefaultErrorResponseErrorDetailsItem { readonly target?: string; } -// @public -export interface DestinationsConfiguration { - dataDogConfiguration?: DataDogConfiguration; - otlpConfigurations?: OtlpConfiguration[]; -} - -// @public -export type DetectionStatus = string; - // @public export interface DiagnosticDataProviderMetadata { propertyBag?: DiagnosticDataProviderMetadataPropertyBagItem[]; @@ -2273,114 +1546,9 @@ export interface DiagnosticSupportTopic { // @public export type DnsVerificationTestResult = "Passed" | "Failed" | "Skipped"; -// @public -export interface DotNetComponent extends ProxyResource { - componentType?: DotNetComponentType; - configurations?: DotNetComponentConfigurationProperty[]; - readonly provisioningState?: DotNetComponentProvisioningState; - serviceBinds?: DotNetComponentServiceBind[]; -} - -// @public -export interface DotNetComponentConfigurationProperty { - propertyName?: string; - value?: string; -} - -// @public -export type DotNetComponentProvisioningState = string; - -// @public -export interface DotNetComponents { - beginCreateOrUpdate(resourceGroupName: string, environmentName: string, name: string, dotNetComponentEnvelope: DotNetComponent, options?: DotNetComponentsCreateOrUpdateOptionalParams): Promise, DotNetComponentsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, environmentName: string, name: string, dotNetComponentEnvelope: DotNetComponent, options?: DotNetComponentsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, environmentName: string, name: string, options?: DotNetComponentsDeleteOptionalParams): Promise, DotNetComponentsDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, environmentName: string, name: string, options?: DotNetComponentsDeleteOptionalParams): Promise; - beginUpdate(resourceGroupName: string, environmentName: string, name: string, dotNetComponentEnvelope: DotNetComponent, options?: DotNetComponentsUpdateOptionalParams): Promise, DotNetComponentsUpdateResponse>>; - beginUpdateAndWait(resourceGroupName: string, environmentName: string, name: string, dotNetComponentEnvelope: DotNetComponent, options?: DotNetComponentsUpdateOptionalParams): Promise; - get(resourceGroupName: string, environmentName: string, name: string, options?: DotNetComponentsGetOptionalParams): Promise; - list(resourceGroupName: string, environmentName: string, options?: DotNetComponentsListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface DotNetComponentsCollection { - readonly nextLink?: string; - value: DotNetComponent[]; -} - -// @public -export interface DotNetComponentsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type DotNetComponentsCreateOrUpdateResponse = DotNetComponent; - -// @public -export interface DotNetComponentsDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface DotNetComponentsDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type DotNetComponentsDeleteResponse = DotNetComponentsDeleteHeaders; - -// @public -export interface DotNetComponentServiceBind { - name?: string; - serviceId?: string; -} - -// @public -export interface DotNetComponentsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DotNetComponentsGetResponse = DotNetComponent; - -// @public -export interface DotNetComponentsListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DotNetComponentsListNextResponse = DotNetComponentsCollection; - -// @public -export interface DotNetComponentsListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DotNetComponentsListResponse = DotNetComponentsCollection; - -// @public -export interface DotNetComponentsUpdateHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface DotNetComponentsUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type DotNetComponentsUpdateResponse = DotNetComponent; - -// @public -export type DotNetComponentType = string; - // @public export interface DynamicPoolConfiguration { - cooldownPeriodInSeconds?: number; - executionType?: ExecutionType; + lifecycleConfiguration?: LifecycleConfiguration; } // @public @@ -2405,12 +1573,6 @@ export interface EnvironmentVar { value?: string; } -// @public -export interface EnvironmentVariable { - name: string; - value: string; -} - // @public export interface ErrorAdditionalInfo { readonly info?: Record; @@ -2426,31 +1588,11 @@ export interface ErrorDetail { readonly target?: string; } -// @public -export interface ErrorEntity { - code?: string; - details?: ErrorEntity[]; - extendedCode?: string; - innerErrors?: ErrorEntity[]; - message?: string; - messageTemplate?: string; - parameters?: string[]; - target?: string; -} - // @public export interface ErrorResponse { error?: ErrorDetail; } -// @public -export interface ExecutionStatus { - replicas?: ReplicaExecutionStatus[]; -} - -// @public -export type ExecutionType = string; - // @public export interface ExtendedLocation { name?: string; @@ -2478,20 +1620,6 @@ export interface ForwardProxy { // @public export type ForwardProxyConvention = "NoProxy" | "Standard" | "Custom"; -// @public -export interface FunctionsExtension { - invokeFunctionsHost(resourceGroupName: string, containerAppName: string, revisionName: string, functionAppName: string, options?: FunctionsExtensionInvokeFunctionsHostOptionalParams): Promise; -} - -// @public -export interface FunctionsExtensionInvokeFunctionsHostOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type FunctionsExtensionInvokeFunctionsHostResponse = { - body: string; -}; - // @public export function getContinuationToken(page: unknown): string | undefined; @@ -2514,9 +1642,7 @@ export interface GitHub { // @public export interface GithubActionConfiguration { azureCredentials?: AzureCredentials; - buildEnvironmentVariables?: EnvironmentVariable[]; contextPath?: string; - dockerfilePath?: string; githubPersonalAccessToken?: string; image?: string; os?: string; @@ -2541,44 +1667,6 @@ export interface Google { validation?: AllowedAudiencesValidation; } -// @public -export interface Header { - key?: string; - value?: string; -} - -// @public -export interface HeaderMatch { - exactMatch?: string; - header?: string; - prefixMatch?: string; - regexMatch?: string; - suffixMatch?: string; -} - -// @public -export interface HttpConnectionPool { - http1MaxPendingRequests?: number; - http2MaxRequests?: number; -} - -// @public -export interface HttpGet { - fileName?: string; - headers?: string[]; - url: string; -} - -// @public -export interface HttpRetryPolicy { - errors?: string[]; - headers?: HeaderMatch[]; - httpStatusCodes?: number[]; - initialDelayInMilliseconds?: number; - maxIntervalInMilliseconds?: number; - maxRetries?: number; -} - // @public export interface HttpScaleRule { auth?: ScaleRuleAuth[]; @@ -2614,18 +1702,9 @@ export interface IdentityProviders { twitter?: Twitter; } -// @public -export interface IdentitySettings { - identity: string; - lifecycle?: IdentitySettingsLifeCycle; -} - // @public export type IdentitySettingsLifeCycle = string; -// @public -export type ImageType = string; - // @public export interface Ingress { additionalPortMappings?: IngressPortMapping[]; @@ -2639,7 +1718,6 @@ export interface Ingress { ipSecurityRestrictions?: IpSecurityRestrictionRule[]; stickySessions?: IngressStickySessions; targetPort?: number; - targetPortHttpScheme?: IngressTargetPortHttpScheme; traffic?: TrafficWeight[]; transport?: IngressTransportMethod; } @@ -2659,9 +1737,6 @@ export interface IngressStickySessions { affinity?: Affinity; } -// @public -export type IngressTargetPortHttpScheme = string; - // @public export type IngressTransportMethod = string; @@ -2695,7 +1770,7 @@ export interface JavaComponentIngress { // @public export interface JavaComponentProperties { - componentType: "SpringCloudGateway" | "SpringBootAdmin" | "Nacos" | "SpringCloudEureka" | "SpringCloudConfig"; + componentType: "SpringBootAdmin" | "SpringCloudEureka" | "SpringCloudConfig"; configurations?: JavaComponentConfigurationProperty[]; readonly provisioningState?: JavaComponentProvisioningState; scale?: JavaComponentPropertiesScale; @@ -2709,7 +1784,7 @@ export interface JavaComponentPropertiesScale { } // @public (undocumented) -export type JavaComponentPropertiesUnion = JavaComponentProperties | SpringCloudGatewayComponent | SpringBootAdminComponent | NacosComponent | SpringCloudEurekaComponent | SpringCloudConfigComponent; +export type JavaComponentPropertiesUnion = JavaComponentProperties | SpringBootAdminComponent | SpringCloudEurekaComponent | SpringCloudConfigComponent; // @public export type JavaComponentProvisioningState = string; @@ -2806,11 +1881,9 @@ export interface Job extends TrackedResource { configuration?: JobConfiguration; environmentId?: string; readonly eventStreamEndpoint?: string; - extendedLocation?: ExtendedLocation; identity?: ManagedServiceIdentity; readonly outboundIpAddresses?: string[]; readonly provisioningState?: JobProvisioningState; - readonly runningState?: JobRunningState; template?: JobTemplate; workloadProfileName?: string; } @@ -2818,7 +1891,6 @@ export interface Job extends TrackedResource { // @public export interface JobConfiguration { eventTriggerConfig?: JobConfigurationEventTriggerConfig; - identitySettings?: IdentitySettings[]; manualTriggerConfig?: JobConfigurationManualTriggerConfig; registries?: RegistryCredentials[]; replicaRetryLimit?: number; @@ -2850,7 +1922,6 @@ export interface JobConfigurationScheduleTriggerConfig { // @public export interface JobExecution { - detailedStatus?: ExecutionStatus; endTime?: Date; id?: string; name?: string; @@ -2899,7 +1970,6 @@ export interface JobExecutionTemplate { // @public export interface JobPatchProperties { - extendedLocation?: ExtendedLocation; identity?: ManagedServiceIdentity; // (undocumented) properties?: JobPatchPropertiesProperties; @@ -2920,25 +1990,18 @@ export interface JobPatchPropertiesProperties { // @public export type JobProvisioningState = string; -// @public -export type JobRunningState = string; - // @public export interface Jobs { beginCreateOrUpdate(resourceGroupName: string, jobName: string, jobEnvelope: Job, options?: JobsCreateOrUpdateOptionalParams): Promise, JobsCreateOrUpdateResponse>>; beginCreateOrUpdateAndWait(resourceGroupName: string, jobName: string, jobEnvelope: Job, options?: JobsCreateOrUpdateOptionalParams): Promise; beginDelete(resourceGroupName: string, jobName: string, options?: JobsDeleteOptionalParams): Promise, void>>; beginDeleteAndWait(resourceGroupName: string, jobName: string, options?: JobsDeleteOptionalParams): Promise; - beginResume(resourceGroupName: string, jobName: string, options?: JobsResumeOptionalParams): Promise, JobsResumeResponse>>; - beginResumeAndWait(resourceGroupName: string, jobName: string, options?: JobsResumeOptionalParams): Promise; beginStart(resourceGroupName: string, jobName: string, options?: JobsStartOptionalParams): Promise, JobsStartResponse>>; beginStartAndWait(resourceGroupName: string, jobName: string, options?: JobsStartOptionalParams): Promise; beginStopExecution(resourceGroupName: string, jobName: string, jobExecutionName: string, options?: JobsStopExecutionOptionalParams): Promise, void>>; beginStopExecutionAndWait(resourceGroupName: string, jobName: string, jobExecutionName: string, options?: JobsStopExecutionOptionalParams): Promise; beginStopMultipleExecutions(resourceGroupName: string, jobName: string, options?: JobsStopMultipleExecutionsOptionalParams): Promise, JobsStopMultipleExecutionsResponse>>; beginStopMultipleExecutionsAndWait(resourceGroupName: string, jobName: string, options?: JobsStopMultipleExecutionsOptionalParams): Promise; - beginSuspend(resourceGroupName: string, jobName: string, options?: JobsSuspendOptionalParams): Promise, JobsSuspendResponse>>; - beginSuspendAndWait(resourceGroupName: string, jobName: string, options?: JobsSuspendOptionalParams): Promise; beginUpdate(resourceGroupName: string, jobName: string, jobEnvelope: JobPatchProperties, options?: JobsUpdateOptionalParams): Promise, JobsUpdateResponse>>; beginUpdateAndWait(resourceGroupName: string, jobName: string, jobEnvelope: JobPatchProperties, options?: JobsUpdateOptionalParams): Promise; get(resourceGroupName: string, jobName: string, options?: JobsGetOptionalParams): Promise; @@ -3089,23 +2152,6 @@ export interface JobsProxyGetOptionalParams extends coreClient.OperationOptions // @public export type JobsProxyGetResponse = Job; -// @public -export interface JobsResumeHeaders { - // (undocumented) - azureAsyncOperation?: string; - // (undocumented) - location?: string; -} - -// @public -export interface JobsResumeOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type JobsResumeResponse = Job; - // @public export interface JobsStartHeaders { // (undocumented) @@ -3149,23 +2195,6 @@ export interface JobsStopMultipleExecutionsOptionalParams extends coreClient.Ope // @public export type JobsStopMultipleExecutionsResponse = ContainerAppJobExecutions; -// @public -export interface JobsSuspendHeaders { - // (undocumented) - azureAsyncOperation?: string; - // (undocumented) - location?: string; -} - -// @public -export interface JobsSuspendOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type JobsSuspendResponse = Job; - // @public export interface JobsUpdateHeaders { // (undocumented) @@ -3199,9 +2228,6 @@ export interface KedaConfiguration { readonly version?: string; } -// @public -export type Kind = string; - // @public export enum KnownAccessMode { ReadOnly = "ReadOnly", @@ -3244,35 +2270,6 @@ export enum KnownBindingType { SniEnabled = "SniEnabled" } -// @public -export enum KnownBuilderProvisioningState { - Canceled = "Canceled", - Creating = "Creating", - Deleting = "Deleting", - Failed = "Failed", - Succeeded = "Succeeded", - Updating = "Updating" -} - -// @public -export enum KnownBuildProvisioningState { - Canceled = "Canceled", - Creating = "Creating", - Deleting = "Deleting", - Failed = "Failed", - Succeeded = "Succeeded", - Updating = "Updating" -} - -// @public -export enum KnownBuildStatus { - Canceled = "Canceled", - Failed = "Failed", - InProgress = "InProgress", - NotStarted = "NotStarted", - Succeeded = "Succeeded" -} - // @public export enum KnownCertificateProvisioningState { Canceled = "Canceled", @@ -3282,12 +2279,6 @@ export enum KnownCertificateProvisioningState { Succeeded = "Succeeded" } -// @public -export enum KnownCertificateType { - ImagePullTrustedCA = "ImagePullTrustedCA", - ServerSSLCertificate = "ServerSSLCertificate" -} - // @public export enum KnownCheckNameAvailabilityReason { AlreadyExists = "AlreadyExists", @@ -3329,6 +2320,15 @@ export enum KnownContainerAppReplicaRunningState { Unknown = "Unknown" } +// @public +export enum KnownContainerAppRunningStatus { + Progressing = "Progressing", + Ready = "Ready", + Running = "Running", + Stopped = "Stopped", + Suspended = "Suspended" +} + // @public export enum KnownContainerType { CustomContainer = "CustomContainer", @@ -3343,27 +2343,6 @@ export enum KnownCreatedByType { User = "User" } -// @public -export enum KnownDetectionStatus { - Failed = "Failed", - RegistryLoginFailed = "RegistryLoginFailed", - Succeeded = "Succeeded" -} - -// @public -export enum KnownDotNetComponentProvisioningState { - Canceled = "Canceled", - Deleting = "Deleting", - Failed = "Failed", - InProgress = "InProgress", - Succeeded = "Succeeded" -} - -// @public -export enum KnownDotNetComponentType { - AspireDashboard = "AspireDashboard" -} - // @public export enum KnownEnvironmentProvisioningState { Canceled = "Canceled", @@ -3378,11 +2357,6 @@ export enum KnownEnvironmentProvisioningState { Waiting = "Waiting" } -// @public -export enum KnownExecutionType { - Timed = "Timed" -} - // @public export enum KnownExtendedLocationTypes { CustomLocation = "CustomLocation" @@ -3390,18 +2364,10 @@ export enum KnownExtendedLocationTypes { // @public export enum KnownIdentitySettingsLifeCycle { - All = "All", - Init = "Init", Main = "Main", None = "None" } -// @public -export enum KnownImageType { - CloudBuild = "CloudBuild", - ContainerImage = "ContainerImage" -} - // @public export enum KnownIngressClientCertificateMode { Accept = "accept", @@ -3409,12 +2375,6 @@ export enum KnownIngressClientCertificateMode { Require = "require" } -// @public -export enum KnownIngressTargetPortHttpScheme { - Http = "http", - Https = "https" -} - // @public export enum KnownIngressTransportMethod { Auto = "auto", @@ -3434,11 +2394,9 @@ export enum KnownJavaComponentProvisioningState { // @public export enum KnownJavaComponentType { - Nacos = "Nacos", SpringBootAdmin = "SpringBootAdmin", SpringCloudConfig = "SpringCloudConfig", - SpringCloudEureka = "SpringCloudEureka", - SpringCloudGateway = "SpringCloudGateway" + SpringCloudEureka = "SpringCloudEureka" } // @public @@ -3462,31 +2420,9 @@ export enum KnownJobProvisioningState { } // @public -export enum KnownJobRunningState { - Progressing = "Progressing", - Ready = "Ready", - Suspended = "Suspended" -} - -// @public -export enum KnownKind { - Workflowapp = "workflowapp" -} - -// @public -export enum KnownLevel { - Debug = "debug", - Error = "error", - Info = "info", - Off = "off", - Trace = "trace", - Warn = "warn" -} - -// @public -export enum KnownLogicAppsProxyMethod { - GET = "GET", - Post = "POST" +export enum KnownLifecycleType { + OnContainerExit = "OnContainerExit", + Timed = "Timed" } // @public @@ -3512,65 +2448,12 @@ export enum KnownManagedServiceIdentityType { UserAssigned = "UserAssigned" } -// @public -export enum KnownPatchApplyStatus { - Canceled = "Canceled", - CreatingRevision = "CreatingRevision", - ImagePushPullFailed = "ImagePushPullFailed", - ManuallySkipped = "ManuallySkipped", - NotStarted = "NotStarted", - RebaseFailed = "RebaseFailed", - RebaseInProgress = "RebaseInProgress", - RevisionCreationFailed = "RevisionCreationFailed", - Succeeded = "Succeeded" -} - -// @public -export enum KnownPatchingMode { - Automatic = "Automatic", - Disabled = "Disabled", - Manual = "Manual" -} - -// @public -export enum KnownPatchType { - FrameworkAndOSSecurity = "FrameworkAndOSSecurity", - FrameworkSecurity = "FrameworkSecurity", - OSSecurity = "OSSecurity", - Other = "Other" -} - // @public export enum KnownPoolManagementType { Dynamic = "Dynamic", Manual = "Manual" } -// @public -export enum KnownPrivateEndpointConnectionProvisioningState { - Canceled = "Canceled", - Deleting = "Deleting", - Failed = "Failed", - Pending = "Pending", - Succeeded = "Succeeded", - Updating = "Updating", - Waiting = "Waiting" -} - -// @public -export enum KnownPrivateEndpointServiceConnectionStatus { - Approved = "Approved", - Disconnected = "Disconnected", - Pending = "Pending", - Rejected = "Rejected" -} - -// @public -export enum KnownPublicNetworkAccess { - Disabled = "Disabled", - Enabled = "Enabled" -} - // @public export enum KnownRevisionHealthState { Healthy = "Healthy", @@ -3598,166 +2481,77 @@ export enum KnownRevisionRunningState { } // @public -export enum KnownScheme { - Http = "HTTP", - Https = "HTTPS" -} - -// @public -export enum KnownSessionNetworkStatus { - EgressDisabled = "EgressDisabled", - EgressEnabled = "EgressEnabled" -} - -// @public -export enum KnownSessionPoolProvisioningState { - Canceled = "Canceled", - Deleting = "Deleting", - Failed = "Failed", - InProgress = "InProgress", - Succeeded = "Succeeded" -} - -// @public -export enum KnownSourceControlOperationState { - Canceled = "Canceled", - Failed = "Failed", - InProgress = "InProgress", - Succeeded = "Succeeded" -} - -// @public -export enum KnownStorageType { - AzureFile = "AzureFile", - EmptyDir = "EmptyDir", - NfsAzureFile = "NfsAzureFile", - Secret = "Secret", - Smb = "Smb" -} - -// @public -export enum KnownTriggerType { - Event = "Event", - Manual = "Manual", - Schedule = "Schedule" -} - -// @public -export enum KnownType { - Liveness = "Liveness", - Readiness = "Readiness", - Startup = "Startup" -} - -// @public -export enum KnownWorkflowState { - Completed = "Completed", - Deleted = "Deleted", - Disabled = "Disabled", - Enabled = "Enabled", - NotSpecified = "NotSpecified", - Suspended = "Suspended" -} - -// @public -export type Level = string; - -// @public (undocumented) -export interface ListUsagesResult { - nextLink?: string; - value?: Usage[]; -} - -// @public -export interface LogAnalyticsConfiguration { - customerId?: string; - dynamicJsonColumns?: boolean; - sharedKey?: string; -} - -// @public -export interface LoggerSetting { - level: Level; - logger: string; -} - -// @public -export interface LogicApp extends ProxyResource { - properties?: Record; -} - -// @public -export interface LogicApps { - createOrUpdate(resourceGroupName: string, containerAppName: string, logicAppName: string, resource: LogicApp, options?: LogicAppsCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, containerAppName: string, logicAppName: string, options?: LogicAppsDeleteOptionalParams): Promise; - deployWorkflowArtifacts(resourceGroupName: string, containerAppName: string, logicAppName: string, options?: LogicAppsDeployWorkflowArtifactsOptionalParams): Promise; - get(resourceGroupName: string, containerAppName: string, logicAppName: string, options?: LogicAppsGetOptionalParams): Promise; - getWorkflow(resourceGroupName: string, containerAppName: string, logicAppName: string, workflowName: string, options?: LogicAppsGetWorkflowOptionalParams): Promise; - invoke(resourceGroupName: string, containerAppName: string, logicAppName: string, xMsLogicAppsProxyPath: string, xMsLogicAppsProxyMethod: LogicAppsProxyMethod, options?: LogicAppsInvokeOptionalParams): Promise; - listWorkflows(resourceGroupName: string, containerAppName: string, logicAppName: string, options?: LogicAppsListWorkflowsOptionalParams): PagedAsyncIterableIterator; - listWorkflowsConnections(resourceGroupName: string, containerAppName: string, logicAppName: string, options?: LogicAppsListWorkflowsConnectionsOptionalParams): Promise; -} - -// @public -export interface LogicAppsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +export enum KnownScheme { + Http = "HTTP", + Https = "HTTPS" } // @public -export type LogicAppsCreateOrUpdateResponse = LogicApp; - -// @public -export interface LogicAppsDeleteOptionalParams extends coreClient.OperationOptions { +export enum KnownSessionNetworkStatus { + EgressDisabled = "EgressDisabled", + EgressEnabled = "EgressEnabled" } // @public -export interface LogicAppsDeployWorkflowArtifactsOptionalParams extends coreClient.OperationOptions { - workflowArtifacts?: WorkflowArtifacts; +export enum KnownSessionPoolProvisioningState { + Canceled = "Canceled", + Deleting = "Deleting", + Failed = "Failed", + InProgress = "InProgress", + Succeeded = "Succeeded" } // @public -export interface LogicAppsGetOptionalParams extends coreClient.OperationOptions { +export enum KnownSourceControlOperationState { + Canceled = "Canceled", + Failed = "Failed", + InProgress = "InProgress", + Succeeded = "Succeeded" } // @public -export type LogicAppsGetResponse = LogicApp; - -// @public -export interface LogicAppsGetWorkflowOptionalParams extends coreClient.OperationOptions { +export enum KnownStorageType { + AzureFile = "AzureFile", + EmptyDir = "EmptyDir", + NfsAzureFile = "NfsAzureFile", + Secret = "Secret" } // @public -export type LogicAppsGetWorkflowResponse = WorkflowEnvelope; - -// @public -export interface LogicAppsInvokeOptionalParams extends coreClient.OperationOptions { +export enum KnownTriggerType { + Event = "Event", + Manual = "Manual", + Schedule = "Schedule" } // @public -export type LogicAppsInvokeResponse = Record; - -// @public -export interface LogicAppsListWorkflowsConnectionsOptionalParams extends coreClient.OperationOptions { +export enum KnownType { + Liveness = "Liveness", + Readiness = "Readiness", + Startup = "Startup" } // @public -export type LogicAppsListWorkflowsConnectionsResponse = WorkflowEnvelope; - -// @public -export interface LogicAppsListWorkflowsNextOptionalParams extends coreClient.OperationOptions { +export interface LifecycleConfiguration { + cooldownPeriodInSeconds?: number; + lifecycleType?: LifecycleType; + maxAlivePeriodInSeconds?: number; } // @public -export type LogicAppsListWorkflowsNextResponse = WorkflowEnvelopeCollection; +export type LifecycleType = string; -// @public -export interface LogicAppsListWorkflowsOptionalParams extends coreClient.OperationOptions { +// @public (undocumented) +export interface ListUsagesResult { + nextLink?: string; + value?: Usage[]; } // @public -export type LogicAppsListWorkflowsResponse = WorkflowEnvelopeCollection; - -// @public -export type LogicAppsProxyMethod = string; +export interface LogAnalyticsConfiguration { + customerId?: string; + sharedKey?: string; +} // @public export interface Login { @@ -3782,11 +2576,6 @@ export interface LoginScopes { // @public export type LogLevel = string; -// @public -export interface LogsConfiguration { - destinations?: string[]; -} - // @public export interface ManagedCertificate extends TrackedResource { properties?: ManagedCertificateProperties; @@ -3871,7 +2660,6 @@ export type ManagedCertificatesUpdateResponse = ManagedCertificate; // @public export interface ManagedEnvironment extends TrackedResource { - appInsightsConfiguration?: AppInsightsConfiguration; appLogsConfiguration?: AppLogsConfiguration; customDomainConfiguration?: CustomDomainConfiguration; daprAIConnectionString?: string; @@ -3884,12 +2672,9 @@ export interface ManagedEnvironment extends TrackedResource { infrastructureResourceGroup?: string; kedaConfiguration?: KedaConfiguration; kind?: string; - openTelemetryConfiguration?: OpenTelemetryConfiguration; peerAuthentication?: ManagedEnvironmentPropertiesPeerAuthentication; peerTrafficConfiguration?: ManagedEnvironmentPropertiesPeerTrafficConfiguration; - readonly privateEndpointConnections?: PrivateEndpointConnection[]; readonly provisioningState?: EnvironmentProvisioningState; - publicNetworkAccess?: PublicNetworkAccess; readonly staticIp?: string; vnetConfiguration?: VnetConfiguration; workloadProfiles?: WorkloadProfile[]; @@ -3916,80 +2701,6 @@ export interface ManagedEnvironmentDiagnosticsListDetectorsOptionalParams extend // @public export type ManagedEnvironmentDiagnosticsListDetectorsResponse = DiagnosticsCollection; -// @public -export interface ManagedEnvironmentPrivateEndpointConnections { - beginCreateOrUpdate(resourceGroupName: string, environmentName: string, privateEndpointConnectionName: string, privateEndpointConnectionEnvelope: PrivateEndpointConnection, options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams): Promise, ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, environmentName: string, privateEndpointConnectionName: string, privateEndpointConnectionEnvelope: PrivateEndpointConnection, options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, environmentName: string, privateEndpointConnectionName: string, options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams): Promise, ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse>>; - beginDeleteAndWait(resourceGroupName: string, environmentName: string, privateEndpointConnectionName: string, options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams): Promise; - get(resourceGroupName: string, environmentName: string, privateEndpointConnectionName: string, options?: ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams): Promise; - list(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse = PrivateEndpointConnection; - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders { - // (undocumented) - location?: string; -} - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse = ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders; - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ManagedEnvironmentPrivateEndpointConnectionsGetResponse = PrivateEndpointConnection; - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ManagedEnvironmentPrivateEndpointConnectionsListNextResponse = PrivateEndpointConnectionListResult; - -// @public -export interface ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ManagedEnvironmentPrivateEndpointConnectionsListResponse = PrivateEndpointConnectionListResult; - -// @public -export interface ManagedEnvironmentPrivateLinkResources { - list(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface ManagedEnvironmentPrivateLinkResourcesListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ManagedEnvironmentPrivateLinkResourcesListNextResponse = PrivateLinkResourceListResult; - -// @public -export interface ManagedEnvironmentPrivateLinkResourcesListOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ManagedEnvironmentPrivateLinkResourcesListResponse = PrivateLinkResourceListResult; - // @public export interface ManagedEnvironmentPropertiesPeerAuthentication { mtls?: Mtls; @@ -4186,6 +2897,12 @@ export interface ManagedEnvironmentUsagesListOptionalParams extends coreClient.O // @public export type ManagedEnvironmentUsagesListResponse = ListUsagesResult; +// @public +export interface ManagedIdentitySetting { + identity: string; + lifecycle?: IdentitySettingsLifeCycle; +} + // @public export interface ManagedServiceIdentity { readonly principalId?: string; @@ -4199,23 +2916,11 @@ export interface ManagedServiceIdentity { // @public export type ManagedServiceIdentityType = string; -// @public -export interface MetricsConfiguration { - destinations?: string[]; - includeKeda?: boolean; -} - // @public export interface Mtls { enabled?: boolean; } -// @public -export interface NacosComponent extends JavaComponentProperties { - componentType: "Nacos"; - ingress?: JavaComponentIngress; -} - // @public export interface Namespaces { checkNameAvailability(resourceGroupName: string, environmentName: string, checkNameAvailabilityRequest: CheckNameAvailabilityRequest, options?: NamespacesCheckNameAvailabilityOptionalParams): Promise; @@ -4269,14 +2974,6 @@ export interface OpenIdConnectRegistration { openIdConnectConfiguration?: OpenIdConnectConfig; } -// @public -export interface OpenTelemetryConfiguration { - destinationsConfiguration?: DestinationsConfiguration; - logsConfiguration?: LogsConfiguration; - metricsConfiguration?: MetricsConfiguration; - tracesConfiguration?: TracesConfiguration; -} - // @public export interface OperationDetail { display?: OperationDisplay; @@ -4312,133 +3009,13 @@ export interface OperationsListOptionalParams extends coreClient.OperationOption // @public export type OperationsListResponse = AvailableOperations; -// @public -export interface OtlpConfiguration { - endpoint?: string; - headers?: Header[]; - insecure?: boolean; - name?: string; -} - -// @public -export type PatchApplyStatus = string; - -// @public -export interface PatchCollection { - nextLink?: string; - value: ContainerAppsPatchResource[]; -} - -// @public -export interface PatchDetails { - readonly detectionStatus: DetectionStatus; - readonly lastDetectionTime: Date; - readonly newImageName?: string; - readonly newLayer?: PatchDetailsNewLayer; - readonly oldLayer?: PatchDetailsOldLayer; - readonly patchType?: PatchType; - readonly targetContainerName: string; - readonly targetImage: string; -} - -// @public -export interface PatchDetailsNewLayer { - frameworkAndVersion?: string; - name?: string; - osAndVersion?: string; -} - -// @public -export interface PatchDetailsOldLayer { - frameworkAndVersion?: string; - name?: string; - osAndVersion?: string; -} - -// @public -export type PatchingMode = string; - -// @public -export interface PatchProperties { - readonly createdAt?: Date; - readonly lastModifiedAt?: Date; - readonly patchApplyStatus?: PatchApplyStatus; - readonly patchDetails?: PatchDetails[]; - targetContainerAppId?: string; - targetEnvironmentId?: string; - targetRevisionId?: string; -} - -// @public -export interface PatchSkipConfig { - skip?: boolean; -} - -// @public -export type PatchType = string; - // @public export type PoolManagementType = string; -// @public -export interface PreBuildStep { - description?: string; - httpGet?: HttpGet; - scripts?: string[]; -} - -// @public -export interface PrivateEndpoint { - readonly id?: string; -} - -// @public -export interface PrivateEndpointConnection extends Resource { - readonly groupIds?: string[]; - privateEndpoint?: PrivateEndpoint; - privateLinkServiceConnectionState?: PrivateLinkServiceConnectionState; - readonly provisioningState?: PrivateEndpointConnectionProvisioningState; -} - -// @public -export interface PrivateEndpointConnectionListResult { - readonly nextLink?: string; - value?: PrivateEndpointConnection[]; -} - -// @public -export type PrivateEndpointConnectionProvisioningState = string; - -// @public -export type PrivateEndpointServiceConnectionStatus = string; - -// @public -export interface PrivateLinkResource extends Resource { - readonly groupId?: string; - readonly requiredMembers?: string[]; - requiredZoneNames?: string[]; -} - -// @public -export interface PrivateLinkResourceListResult { - readonly nextLink?: string; - value?: PrivateLinkResource[]; -} - -// @public -export interface PrivateLinkServiceConnectionState { - actionsRequired?: string; - description?: string; - status?: PrivateEndpointServiceConnectionStatus; -} - // @public export interface ProxyResource extends Resource { } -// @public -export type PublicNetworkAccess = string; - // @public export interface QueueScaleRule { accountName?: string; @@ -4480,7 +3057,6 @@ export interface ReplicaCollection { // @public export interface ReplicaContainer { containerId?: string; - readonly debugEndpoint?: string; readonly execEndpoint?: string; readonly logStreamEndpoint?: string; name?: string; @@ -4491,12 +3067,6 @@ export interface ReplicaContainer { started?: boolean; } -// @public -export interface ReplicaExecutionStatus { - containers?: ContainerExecutionStatus[]; - name?: string; -} - // @public export interface Resource { readonly id?: string; @@ -4537,30 +3107,12 @@ export type RevisionRunningState = string; // @public export interface Runtime { - dotnet?: RuntimeDotnet; java?: RuntimeJava; } -// @public -export interface RuntimeDotnet { - autoConfigureDataProtection?: boolean; -} - // @public export interface RuntimeJava { enableMetrics?: boolean; - javaAgent?: RuntimeJavaAgent; -} - -// @public -export interface RuntimeJavaAgent { - enabled?: boolean; - logging?: RuntimeJavaAgentLogging; -} - -// @public -export interface RuntimeJavaAgentLogging { - loggerSettings?: LoggerSetting[]; } // @public @@ -4593,15 +3145,6 @@ export interface ScaleRuleAuth { triggerParameter?: string; } -// @public -export interface ScgRoute { - filters?: string[]; - id: string; - order?: number; - predicates?: string[]; - uri: string; -} - // @public export type Scheme = string; @@ -4631,10 +3174,6 @@ export interface Service { // @public export interface ServiceBind { - clientType?: string; - customizedKeys?: { - [propertyName: string]: string; - }; name?: string; serviceId?: string; } @@ -4674,6 +3213,8 @@ export interface SessionPool extends TrackedResource { customContainerTemplate?: CustomContainerTemplate; dynamicPoolConfiguration?: DynamicPoolConfiguration; environmentId?: string; + identity?: ManagedServiceIdentity; + managedIdentitySettings?: ManagedIdentitySetting[]; readonly nodeCount?: number; readonly poolManagementEndpoint?: string; poolManagementType?: PoolManagementType; @@ -4702,9 +3243,13 @@ export interface SessionPoolSecret { export interface SessionPoolUpdatableProperties { customContainerTemplate?: CustomContainerTemplate; dynamicPoolConfiguration?: DynamicPoolConfiguration; + identity?: ManagedServiceIdentity; scaleConfiguration?: ScaleConfiguration; secrets?: SessionPoolSecret[]; sessionNetworkConfiguration?: SessionNetworkConfiguration; + tags?: { + [propertyName: string]: string; + }; } // @public @@ -4715,16 +3260,6 @@ export interface SessionRegistryCredentials { username?: string; } -// @public -export interface SmbStorage { - accessMode?: AccessMode; - domain?: string; - host?: string; - password?: string; - shareName?: string; - username?: string; -} - // @public export interface SourceControl extends ProxyResource { branch?: string; @@ -4759,13 +3294,6 @@ export interface SpringCloudEurekaComponent extends JavaComponentProperties { ingress?: JavaComponentIngress; } -// @public -export interface SpringCloudGatewayComponent extends JavaComponentProperties { - componentType: "SpringCloudGateway"; - ingress?: JavaComponentIngress; - springCloudGatewayRoutes?: ScgRoute[]; -} - // @public export type StorageType = string; @@ -4779,16 +3307,6 @@ export interface SystemData { lastModifiedByType?: CreatedByType; } -// @public -export interface TcpConnectionPool { - maxConnections?: number; -} - -// @public -export interface TcpRetryPolicy { - maxConnectAttempts?: number; -} - // @public export interface TcpScaleRule { auth?: ScaleRuleAuth[]; @@ -4809,12 +3327,6 @@ export interface Template { volumes?: Volume[]; } -// @public -export interface TimeoutPolicy { - connectionTimeoutInSeconds?: number; - responseTimeoutInSeconds?: number; -} - // @public export interface TokenStore { azureBlobStorage?: BlobStorageTokenStore; @@ -4822,12 +3334,6 @@ export interface TokenStore { tokenRefreshExtensionHours?: number; } -// @public -export interface TracesConfiguration { - destinations?: string[]; - includeDapr?: boolean; -} - // @public export interface TrackedResource extends Resource { location: string; @@ -4929,51 +3435,8 @@ export interface VolumeMount { volumeName?: string; } -// @public -export interface WorkflowArtifacts { - appSettings?: Record; - files?: 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?: Record; - flowState?: WorkflowState; - health?: WorkflowHealth; -} - -// @public -export interface WorkflowHealth { - error?: ErrorEntity; - state: WorkflowHealthState; -} - -// @public -export type WorkflowHealthState = "NotSpecified" | "Healthy" | "Unhealthy" | "Unknown"; - -// @public -export type WorkflowState = string; - // @public export interface WorkloadProfile { - enableFips?: boolean; maximumCount?: number; minimumCount?: number; name: string; diff --git a/sdk/appcontainers/arm-appcontainers/sample.env b/sdk/appcontainers/arm-appcontainers/sample.env index 672847a3fea0..508439fc7d62 100644 --- a/sdk/appcontainers/arm-appcontainers/sample.env +++ b/sdk/appcontainers/arm-appcontainers/sample.env @@ -1,4 +1 @@ -# App registration secret for AAD authentication -AZURE_CLIENT_SECRET= -AZURE_CLIENT_ID= -AZURE_TENANT_ID= \ No newline at end of file +# Feel free to add your own environment variables. \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyCreateOrUpdateSample.ts deleted file mode 100644 index 61606ac58a06..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyCreateOrUpdateSample.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { AppResiliency } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update container app resiliency policy. - * - * @summary Create or update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_CreateOrUpdate.json - */ -async function createOrUpdateAppResiliency(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope: AppResiliency = { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 10, - maxEjectionPercent: 50, - }, - httpConnectionPool: { - http1MaxPendingRequests: 1024, - http2MaxRequests: 1024, - }, - httpRetryPolicy: { - errors: ["5xx", "connect-failure", "reset", "retriable-headers", "retriable-status-codes"], - headers: [{ header: "X-Content-Type", prefixMatch: "GOATS" }], - httpStatusCodes: [502, 503], - initialDelayInMilliseconds: 1000, - maxIntervalInMilliseconds: 10000, - maxRetries: 5, - }, - tcpConnectionPool: { maxConnections: 100 }, - tcpRetryPolicy: { maxConnectAttempts: 3 }, - timeoutPolicy: { - connectionTimeoutInSeconds: 5, - responseTimeoutInSeconds: 15, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.createOrUpdate( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyDeleteSample.ts deleted file mode 100644 index 40037ea25453..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete container app resiliency policy. - * - * @summary Delete container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Delete.json - */ -async function deleteAppResiliency(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.delete(resourceGroupName, appName, name); - console.log(result); -} - -async function main(): Promise { - await deleteAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyGetSample.ts deleted file mode 100644 index ddee76b688b0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get container app resiliency policy. - * - * @summary Get container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Get.json - */ -async function getAppResiliency(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.get(resourceGroupName, appName, name); - console.log(result); -} - -async function main(): Promise { - await getAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyListSample.ts deleted file mode 100644 index 5b404ec23935..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List container app resiliency policies. - * - * @summary List container app resiliency policies. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_List.json - */ -async function listAppResiliency(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.appResiliencyOperations.list(resourceGroupName, appName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyUpdateSample.ts deleted file mode 100644 index 2b5624aed85f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/appResiliencyUpdateSample.ts +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { AppResiliency } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update container app resiliency policy. - * - * @summary Update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Patch.json - */ -async function updateAppResiliency(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope: AppResiliency = { - timeoutPolicy: { - connectionTimeoutInSeconds: 40, - responseTimeoutInSeconds: 30, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.update( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await updateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/availableWorkloadProfilesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/availableWorkloadProfilesGetSample.ts deleted file mode 100644 index d88b2d00bfb7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/availableWorkloadProfilesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all available workload profiles for a location. - * - * @summary Get all available workload profiles for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AvailableWorkloadProfiles_Get.json - */ -async function billingMetersGet(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.availableWorkloadProfiles.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/billingMetersGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/billingMetersGetSample.ts deleted file mode 100644 index 852b0a3c27d7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/billingMetersGetSample.ts +++ /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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all billingMeters for a location. - * - * @summary Get all billingMeters for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/BillingMeters_Get.json - */ -async function billingMetersGet(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.billingMeters.get(location); - console.log(result); -} - -async function main(): Promise { - await billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildAuthTokenListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildAuthTokenListSample.ts deleted file mode 100644 index 56231e1c2313..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildAuthTokenListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * - * @summary Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListAuthToken.json - */ -async function getBuildAuthToken(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.buildAuthToken.list(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main(): Promise { - await getBuildAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersCreateOrUpdateSample.ts deleted file mode 100644 index d343eb81d39e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersCreateOrUpdateSample.ts +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { BuilderResource } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a BuilderResource - * - * @summary Create or update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_CreateOrUpdate.json - */ -async function buildersCreateOrUpdate0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope: BuilderResource = { - containerRegistries: [ - { - containerRegistryServer: "test.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - { - containerRegistryServer: "test2.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - ], - environmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/rg/providers/Microsoft.App/managedEnvironments/testEnv", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/rg1/providers/MicrosoftManagedIdentity/userAssignedIdentities/identity1": - {}, - }, - }, - location: "eastus", - tags: { company: "Microsoft" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await buildersCreateOrUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersDeleteSample.ts deleted file mode 100644 index 7b79e3a169dd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a BuilderResource - * - * @summary Delete a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Delete.json - */ -async function buildersDelete0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginDeleteAndWait(resourceGroupName, builderName); - console.log(result); -} - -async function main(): Promise { - await buildersDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersGetSample.ts deleted file mode 100644 index 9af23fbb5398..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a BuilderResource - * - * @summary Get a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Get.json - */ -async function buildersGet0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.get(resourceGroupName, builderName); - console.log(result); -} - -async function main(): Promise { - await buildersGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListByResourceGroupSample.ts deleted file mode 100644 index 2c6ffd6479cf..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuilderResource resources by resource group - * - * @summary List BuilderResource resources by resource group - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListByResourceGroup.json - */ -async function buildersListByResourceGroup0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.builders.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await buildersListByResourceGroup0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListBySubscriptionSample.ts deleted file mode 100644 index cb8552622051..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuilderResource resources by subscription ID - * - * @summary List BuilderResource resources by subscription ID - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListBySubscription.json - */ -async function buildersListBySubscription0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.builders.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await buildersListBySubscription0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildersUpdateSample.ts deleted file mode 100644 index f26009c407e0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildersUpdateSample.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. - */ -import type { BuilderResourceUpdate } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update a BuilderResource - * - * @summary Update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Update.json - */ -async function buildersUpdate0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope: BuilderResourceUpdate = { - tags: { mytag1: "myvalue1" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await buildersUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsByBuilderResourceListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildsByBuilderResourceListSample.ts deleted file mode 100644 index dbf0eaf9ef7a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsByBuilderResourceListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuildResource resources by BuilderResource - * - * @summary List BuildResource resources by BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListByBuilderResource.json - */ -async function buildsListByBuilderResource0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.buildsByBuilderResource.list(resourceGroupName, builderName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await buildsListByBuilderResource0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildsCreateOrUpdateSample.ts deleted file mode 100644 index 0a68c93c4915..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsCreateOrUpdateSample.ts +++ /dev/null @@ -1,100 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { BuildResource } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate_NoConfig.json - */ -async function buildsCreateOrUpdateNoConfig(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const buildEnvelope: BuildResource = {}; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate.json - */ -async function buildsCreateOrUpdateWithConfig(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild-123456789az"; - const buildEnvelope: BuildResource = { - configuration: { - baseOs: "DebianBullseye", - environmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - platform: "dotnetcore", - platformVersion: "7.0", - preBuildSteps: [ - { - description: "First pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo", "bar"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'world'"], - }, - { - description: "Second pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'again'"], - }, - ], - }, - destinationContainerRegistry: { - image: "test.azurecr.io/repo:tag", - server: "test.azurecr.io", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await buildsCreateOrUpdateNoConfig(); - await buildsCreateOrUpdateWithConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildsDeleteSample.ts deleted file mode 100644 index 00c0b3a33105..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a BuildResource - * - * @summary Delete a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Delete.json - */ -async function buildsDelete0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginDeleteAndWait(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main(): Promise { - await buildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/buildsGetSample.ts deleted file mode 100644 index 57a9ed527578..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/buildsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a BuildResource - * - * @summary Get a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Get.json - */ -async function buildsGet0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.get(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main(): Promise { - await buildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesCreateOrUpdateSample.ts deleted file mode 100644 index 7a6b5c97d5de..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { - Certificate, - CertificatesCreateOrUpdateOptionalParams, -} from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - certificateType: "ImagePullTrustedCA", - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate_FromKeyVault.json - */ -async function createOrUpdateCertificateUsingManagedIdentity(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - certificateKeyVaultProperties: { - identity: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/test-rg/providers/microsoft.managedidentity/userassignedidentities/test-user-mi", - keyVaultUrl: "https://xxxxxxxx.vault.azure.net/certificates/certName", - }, - certificateType: "ServerSSLCertificate", - }, - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateCertificate(); - await createOrUpdateCertificateUsingManagedIdentity(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesDeleteSample.ts deleted file mode 100644 index fc8aa3e34518..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete( - resourceGroupName, - environmentName, - certificateName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesGetSample.ts deleted file mode 100644 index bb7fdc81028a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Get.json - */ -async function getCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get(resourceGroupName, environmentName, certificateName); - console.log(result); -} - -async function main(): Promise { - await getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesListSample.ts deleted file mode 100644 index e252d4b5e4fe..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Certificates in a given managed environment. - * - * @summary Get the Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.certificates.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesUpdateSample.ts deleted file mode 100644 index 654040c71344..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/certificatesUpdateSample.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. - */ -import type { CertificatePatch } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_Patch.json - */ -async function patchCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: CertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.update( - resourceGroupName, - environmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts deleted file mode 100644 index 5b1faf7af3d4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { - Certificate, - ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams, -} from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options: ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesDeleteSample.ts deleted file mode 100644 index 47319efac660..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Delete.json - */ -async function deleteCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.delete( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesGetSample.ts deleted file mode 100644 index 79d78c0cd3aa..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Get.json - */ -async function getCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.get( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main(): Promise { - await getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesListSample.ts deleted file mode 100644 index 57113c084d8f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Certificates in a given connected environment. - * - * @summary Get the Certificates in a given connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_ListByConnectedEnvironment.json - */ -async function listCertificatesByConnectedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.connectedEnvironmentsCertificates.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listCertificatesByConnectedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesUpdateSample.ts deleted file mode 100644 index 5d50f85cba4b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCertificatesUpdateSample.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. - */ -import type { CertificatePatch } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_Patch.json - */ -async function patchCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: CertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.update( - resourceGroupName, - connectedEnvironmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCheckNameAvailabilitySample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCheckNameAvailabilitySample.ts deleted file mode 100644 index 5116377648fc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCheckNameAvailabilitySample.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. - */ -import type { CheckNameAvailabilityRequest } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource connectedEnvironmentName is available. - * - * @summary Checks if resource connectedEnvironmentName is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/connectedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.checkNameAvailability( - resourceGroupName, - connectedEnvironmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main(): Promise { - await certificatesCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 9396d519f223..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ConnectedEnvironment } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates an connectedEnvironment. - * - * @summary Creates or updates an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_CreateOrUpdate.json - */ -async function createKubeEnvironments(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const environmentEnvelope: ConnectedEnvironment = { - customDomainConfiguration: { - certificatePassword: "private key password", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - location: "East US", - staticIp: "1.2.3.4", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - connectedEnvironmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createKubeEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 7061de52b882..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.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. - */ -import type { DaprComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a connected environment. - * - * @summary Creates or updates a Dapr Component in a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsDeleteSample.ts deleted file mode 100644 index f930ff308dd6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr Component from a connected environment. - * - * @summary Delete a Dapr Component from a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Delete.json - */ -async function deleteDaprComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.delete( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsGetSample.ts deleted file mode 100644 index 1310aa4223b3..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Get.json - */ -async function getDaprComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.get( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main(): Promise { - await getDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSample.ts deleted file mode 100644 index 971c781c208e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr Components for a connected environment. - * - * @summary Get the Dapr Components for a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_List.json - */ -async function listDaprComponents(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.connectedEnvironmentsDaprComponents.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSecretsSample.ts deleted file mode 100644 index 447212d5b36d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDaprComponentsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.listSecrets( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main(): Promise { - await listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDeleteSample.ts deleted file mode 100644 index ca52ce52f00d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete an connectedEnvironment. - * - * @summary Delete an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Delete.json - */ -async function deleteConnectedEnvironmentByConnectedEnvironmentName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginDeleteAndWait( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsGetSample.ts deleted file mode 100644 index aab0d24678e7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of an connectedEnvironment. - * - * @summary Get the properties of an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Get.json - */ -async function getConnectedEnvironmentByConnectedEnvironmentName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.get( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main(): Promise { - await getConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index 8aa8273dee4e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all connectedEnvironments in a resource group. - * - * @summary Get all connectedEnvironments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.connectedEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index 78f15777fe98..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all connectedEnvironments for a subscription. - * - * @summary Get all connectedEnvironments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListBySubscription.json - */ -async function listConnectedEnvironmentsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.connectedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listConnectedEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 76030263e147..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesCreateOrUpdateSample.ts +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ConnectedEnvironmentStorage } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update storage for a connectedEnvironment. - * - * @summary Create or update storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ConnectedEnvironmentStorage = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateEnvironmentsStorage(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index e73bc2e3c12a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete storage for a connectedEnvironment. - * - * @summary Delete storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.delete( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main(): Promise { - await listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index 4106d6169fa1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get storage for a connectedEnvironment. - * - * @summary Get storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.get( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main(): Promise { - await getAEnvironmentsStoragePropertiesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesListSample.ts deleted file mode 100644 index 5995350e01fa..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsStoragesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all storages for a connectedEnvironment. - * - * @summary Get all storages for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.list( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main(): Promise { - await listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsUpdateSample.ts deleted file mode 100644 index ced975b66487..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/connectedEnvironmentsUpdateSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Managed Environment. Only patching of tags is supported currently - * - * @summary Patches a Managed Environment. Only patching of tags is supported currently - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Patch.json - */ -async function patchManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.update( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main(): Promise { - await patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts deleted file mode 100644 index 22093c318319..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { AuthConfig } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update the AuthConfig for a Container App. - * - * @summary Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const authConfigEnvelope: AuthConfig = { - encryptionSettings: { - containerAppAuthEncryptionSecretName: "testEncryptionSecretName", - containerAppAuthSigningSecretName: "testSigningSecretName", - }, - globalValidation: { unauthenticatedClientAction: "AllowAnonymous" }, - identityProviders: { - facebook: { - registration: { appId: "123", appSecretSettingName: "facebook-secret" }, - }, - }, - platform: { enabled: true }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.createOrUpdate( - resourceGroupName, - containerAppName, - authConfigName, - authConfigEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsDeleteSample.ts deleted file mode 100644 index 9471cb773ed5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App AuthConfig. - * - * @summary Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsGetSample.ts deleted file mode 100644 index 506eab17f4b7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a AuthConfig of a Container App. - * - * @summary Get a AuthConfig of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts deleted file mode 100644 index 8cd819fbaacc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsAuthConfigsListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container App AuthConfigs in a given resource group. - * - * @summary Get the Container App AuthConfigs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsAuthConfigs.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listAuthConfigsByContainerApps(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsByContainerAppListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsByContainerAppListSample.ts deleted file mode 100644 index f2324f31e29f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsByContainerAppListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List Container Apps Build resources by Container App - * - * @summary List Container Apps Build resources by Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_ListByContainerApp.json - */ -async function containerAppsBuildsListByContainerApp0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsBuildsByContainerApp.list( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await containerAppsBuildsListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsDeleteSample.ts deleted file mode 100644 index f48d8cf35112..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container Apps Build resource - * - * @summary Delete a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Delete.json - */ -async function containerAppsBuildsDelete0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.beginDeleteAndWait( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsBuildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsGetSample.ts deleted file mode 100644 index eeba09e9e929..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsBuildsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Container Apps Build resource - * - * @summary Get a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Get.json - */ -async function containerAppsBuildsGet0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.get( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsBuildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsCreateOrUpdateSample.ts deleted file mode 100644 index 882767377c8d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsCreateOrUpdateSample.ts +++ /dev/null @@ -1,723 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ContainerApp } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Kind_CreateOrUpdate.json - */ -async function createOrUpdateAppKind(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppKind"; - const containerAppEnvelope: ContainerApp = { - configuration: { - activeRevisionsMode: "Single", - ingress: { allowInsecure: true, external: true, targetPort: 80 }, - }, - kind: "workflowapp", - location: "East Us", - managedBy: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.Web/sites/testcontainerAppKind", - managedEnvironmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/testmanagedenv3", - template: { - containers: [ - { - name: "logicapps-container", - image: "default/logicapps-base:latest", - resources: { cpu: 1, memory: "2.0Gi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 30, - minReplicas: 1, - pollingInterval: 35, - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateAppOnAConnectedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - { - name: "servicebus", - custom: { - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { - messageCount: "5", - namespace: "mynamespace", - queueName: "myqueue", - }, - }, - }, - { - name: "azure-queue", - azureQueue: { - accountName: "account1", - identity: "system", - queueLength: 1, - queueName: "queue1", - }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ManagedBy_CreateOrUpdate.json - */ -async function createOrUpdateManagedByApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppManagedBy"; - const containerAppEnvelope: ContainerApp = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [{ revisionName: "testcontainerAppManagedBy-ab1234", weight: 100 }], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - managedBy: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.AppPlatform/Spring/springapp", - template: { - containers: [ - { - name: "testcontainerAppManagedBy", - image: "repo/testcontainerAppManagedBy:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_SourceToCloudApp_CreateOrUpdate.json - */ -async function createOrUpdateSourceToCloudApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - patchingConfiguration: { patchingMode: "Automatic" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "", - imageType: "CloudBuild", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_TcpApp_CreateOrUpdate.json - */ -async function createOrUpdateTcpApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppTcp"; - const containerAppEnvelope: ContainerApp = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [{ revisionName: "testcontainerAppTcp-ab1234", weight: 100 }], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppTcp", - image: "repo/testcontainerAppTcp:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateAppKind(); - await createOrUpdateAppOnAConnectedEnvironment(); - await createOrUpdateContainerApp(); - await createOrUpdateManagedByApp(); - await createOrUpdateSourceToCloudApp(); - await createOrUpdateTcpApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDeleteSample.ts deleted file mode 100644 index e37091487aa5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App. - * - * @summary Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await deleteContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetDetectorSample.ts deleted file mode 100644 index 7920d59228b0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a diagnostics result of a Container App. - * - * @summary Get a diagnostics result of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_Get.json - */ -async function getContainerAppDiagnosticsInfo(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const detectorName = "cappcontainerappnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getDetector( - resourceGroupName, - containerAppName, - detectorName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppDiagnosticsInfo(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRevisionSample.ts deleted file mode 100644 index b9f47293ea18..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRootSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRootSample.ts deleted file mode 100644 index 569418c527b4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsGetRootSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRoot(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListDetectorsSample.ts deleted file mode 100644 index f2d92907e653..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a given Container App. - * - * @summary Get the list of diagnostics for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticsForAGivenContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsDiagnostics.listDetectors( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await getTheListOfAvailableDiagnosticsForAGivenContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListRevisionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListRevisionsSample.ts deleted file mode 100644 index 40b4cf2aa730..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsDiagnosticsListRevisionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsDiagnostics.listRevisions( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppRevisions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetAuthTokenSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetAuthTokenSample.ts deleted file mode 100644 index 305ecd2e6c2e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetAuthTokenSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get auth token for a container app - * - * @summary Get auth token for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_GetAuthToken.json - */ -async function getContainerAppAuthToken(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.getAuthToken(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await getContainerAppAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetSample.ts deleted file mode 100644 index 40b238bed17a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListByResourceGroupSample.ts deleted file mode 100644 index ae535d36b9e8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerApps.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListBySubscriptionSample.ts deleted file mode 100644 index 9271e4b879b7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerApps.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts deleted file mode 100644 index 5f406bb98012..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListCustomHostNameAnalysisSample.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. - */ -import type { ContainerAppsListCustomHostNameAnalysisOptionalParams } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Analyzes a custom hostname for a Container App - * - * @summary Analyzes a custom hostname for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const customHostname = "my.name.corp"; - const options: ContainerAppsListCustomHostNameAnalysisOptionalParams = { - customHostname, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listCustomHostNameAnalysis( - resourceGroupName, - containerAppName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await analyzeCustomHostname(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListSecretsSample.ts deleted file mode 100644 index 3a4e4b418666..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesApplySample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesApplySample.ts deleted file mode 100644 index 047aa483f084..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesApplySample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Apply a Container Apps Patch resource with patch name. - * - * @summary Apply a Container Apps Patch resource with patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Apply.json - */ -async function containerAppsPatchesApply0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginApplyAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsPatchesApply0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesDeleteSample.ts deleted file mode 100644 index f34312360d90..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete specific Container Apps Patch by patch name. - * - * @summary Delete specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Delete.json - */ -async function containerAppsPatchesDelete0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginDeleteAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsPatchesDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesGetSample.ts deleted file mode 100644 index dada85f98dc1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get details for specific Container Apps Patch by patch name. - * - * @summary Get details for specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Get.json - */ -async function containerAppsPatchesGet0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.get( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsPatchesGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesListByContainerAppSample.ts deleted file mode 100644 index c70595c1996c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List Container Apps Patch resources by ContainerApp. - * - * @summary List Container Apps Patch resources by ContainerApp. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_ListByContainerApp.json - */ -async function containerAppsPatchesListByContainerApp0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsPatches.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await containerAppsPatchesListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesSkipConfigureSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesSkipConfigureSample.ts deleted file mode 100644 index 431fced3b5c4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsPatchesSkipConfigureSample.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. - */ -import type { PatchSkipConfig } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Configure the Container Apps Patch skip option by patch name. - * - * @summary Configure the Container Apps Patch skip option by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Skip_Configure.json - */ -async function containerAppsPatchesSkipConfigure0(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const patchSkipConfig: PatchSkipConfig = { skip: true }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginSkipConfigureAndWait( - resourceGroupName, - containerAppName, - patchName, - patchSkipConfig, - ); - console.log(result); -} - -async function main(): Promise { - await containerAppsPatchesSkipConfigure0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts deleted file mode 100644 index bf3f449c467b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasGetReplicaSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a replica for a Container App Revision. - * - * @summary Get a replica for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const replicaName = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - replicaName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppRevisionReplica(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts deleted file mode 100644 index 316915671163..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionReplicasListReplicasSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List replicas for a Container App Revision. - * - * @summary List replicas for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.listReplicas( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await listContainerAppReplicas(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsActivateRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsActivateRevisionSample.ts deleted file mode 100644 index b3e7fb0ec393..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsActivateRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await activateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts deleted file mode 100644 index 085a477de01d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsDeactivateRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await deactivateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsGetRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsGetRevisionSample.ts deleted file mode 100644 index 24d4e1c5a56e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsGetRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsListRevisionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsListRevisionsSample.ts deleted file mode 100644 index f914df980b83..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsListRevisionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsRevisions.listRevisions( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppRevisions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsRestartRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsRestartRevisionSample.ts deleted file mode 100644 index 6b387ca0512a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsRevisionsRestartRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testStaticSite0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main(): Promise { - await restartContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsCreateOrUpdateSample.ts deleted file mode 100644 index 523080ed59f4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsCreateOrUpdateSample.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. - */ -import type { SessionPool } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a session pool with the given properties. - * - * @summary Create or update a session pool with the given properties. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_CreateOrUpdate.json - */ -async function createOrUpdateSessionPool(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope: SessionPool = { - containerType: "CustomContainer", - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - poolManagementType: "Dynamic", - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginCreateOrUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsDeleteSample.ts deleted file mode 100644 index 4391fbfa7d7f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete the session pool with the given name. - * - * @summary Delete the session pool with the given name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Delete.json - */ -async function deleteSessionPool(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginDeleteAndWait( - resourceGroupName, - sessionPoolName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsGetSample.ts deleted file mode 100644 index c461a281d683..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a session pool. - * - * @summary Get the properties of a session pool. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Get.json - */ -async function getSessionPool(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.get(resourceGroupName, sessionPoolName); - console.log(result); -} - -async function main(): Promise { - await getSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListByResourceGroupSample.ts deleted file mode 100644 index 1697b3b79486..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the session pools in a given resource group of a subscription. - * - * @summary Get the session pools in a given resource group of a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListByResourceGroup.json - */ -async function listSessionPoolsByResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsSessionPools.listByResourceGroup( - resourceGroupName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listSessionPoolsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListBySubscriptionSample.ts deleted file mode 100644 index 0c0a08b53dc2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the session pools in a given subscription. - * - * @summary Get the session pools in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListBySubscription.json - */ -async function listSessionPoolsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsSessionPools.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listSessionPoolsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsUpdateSample.ts deleted file mode 100644 index 84583b303ed0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSessionPoolsUpdateSample.ts +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { SessionPoolUpdatableProperties } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a session pool using JSON merge patch - * - * @summary Patches a session pool using JSON merge patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Patch.json - */ -async function updateSessionPool(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope: SessionPoolUpdatableProperties = { - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await updateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts deleted file mode 100644 index 62bf188cfaf0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { - SourceControl, - ContainerAppsSourceControlsCreateOrUpdateOptionalParams, -} from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update the SourceControl for a Container App. - * - * @summary Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const sourceControlEnvelope: SourceControl = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - kind: "feaderated", - tenantId: "", - }, - buildEnvironmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - contextPath: "./", - dockerfilePath: "./Dockerfile", - githubPersonalAccessToken: "test", - image: "image/tag", - registryInfo: { - registryPassword: "", - registryUrl: "test-registry.azurecr.io", - registryUserName: "test-registry", - }, - }, - repoUrl: "https://github.com/xwang971/ghatest", - }; - const options: ContainerAppsSourceControlsCreateOrUpdateOptionalParams = { - xMsGithubAuxiliary, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - sourceControlEnvelope, - options, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsDeleteSample.ts deleted file mode 100644 index 1a38b483b4e0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsDeleteSample.ts +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ContainerAppsSourceControlsDeleteOptionalParams } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App SourceControl. - * - * @summary Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const ignoreWorkflowDeletionFailure = false; - const deleteWorkflow = false; - const options: ContainerAppsSourceControlsDeleteOptionalParams = { - xMsGithubAuxiliary, - ignoreWorkflowDeletionFailure, - deleteWorkflow, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await deleteContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsGetSample.ts deleted file mode 100644 index 7ec8bb480a94..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a SourceControl of a Container App. - * - * @summary Get a SourceControl of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - sourceControlName, - ); - console.log(result); -} - -async function main(): Promise { - await getContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts deleted file mode 100644 index 040e2289773f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsSourceControlsListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container App SourceControls in a given resource group. - * - * @summary Get the Container App SourceControls in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.containerAppsSourceControls.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listAppSourceControls(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStartSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStartSample.ts deleted file mode 100644 index c4738a96afb2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStartSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Start a container app - * - * @summary Start a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Start.json - */ -async function startContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStartAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await startContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStopSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStopSample.ts deleted file mode 100644 index 1970857a961d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsStopSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Stop a container app - * - * @summary Stop a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Stop.json - */ -async function stopContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStopAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main(): Promise { - await stopContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsUpdateSample.ts deleted file mode 100644 index 4593be3fa251..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/containerAppsUpdateSample.ts +++ /dev/null @@ -1,155 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ContainerApp } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Container App using JSON Merge Patch - * - * @summary Patches a Container App using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - service: { type: "redis" }, - }, - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "service", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/service", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts deleted file mode 100644 index 85eaf8dece5d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts +++ /dev/null @@ -1,156 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { DaprComponentResiliencyPolicy } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_AllOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithAllOptions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - inboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 4, - timeoutInSeconds: 10, - }, - httpRetryPolicy: { - maxRetries: 15, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 30 }, - }, - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_OutboundOnly.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_SparseOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - inboundPolicy: { - circuitBreakerPolicy: { consecutiveErrors: 3, timeoutInSeconds: 20 }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - }, - outboundPolicy: { timeoutPolicy: { responseTimeoutInSeconds: 12 } }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateDaprComponentResiliencyPolicyWithAllOptions(); - await createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly(); - await createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesDeleteSample.ts deleted file mode 100644 index b1e85f4e837d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a resiliency policy for a Dapr component. - * - * @summary Delete a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Delete.json - */ -async function deleteDaprComponentResiliencyPolicy(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.delete( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main(): Promise { - await deleteDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesGetSample.ts deleted file mode 100644 index dafa9a9964ca..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Dapr component resiliency policy. - * - * @summary Get a Dapr component resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Get.json - */ -async function getDaprComponentResiliencyPolicy(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.get( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main(): Promise { - await getDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesListSample.ts deleted file mode 100644 index 8f04f39e9e87..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentResiliencyPoliciesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the resiliency policies for a Dapr component. - * - * @summary Get the resiliency policies for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_List.json - */ -async function listDaprComponentResiliencyPolicies(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.daprComponentResiliencyPolicies.list( - resourceGroupName, - environmentName, - componentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listDaprComponentResiliencyPolicies(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 65b39fb6543c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,108 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { DaprComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_SecretStoreComponent.json - */ -async function createOrUpdateDaprComponentWithSecretStoreComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secretStoreComponent: "my-secret-store", - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_Secrets.json - */ -async function createOrUpdateDaprComponentWithSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateDaprComponentWithSecretStoreComponent(); - await createOrUpdateDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsDeleteSample.ts deleted file mode 100644 index bbb1c0d4e979..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr Component from a Managed Environment. - * - * @summary Delete a Dapr Component from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsGetSample.ts deleted file mode 100644 index 347b5bb282a2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsGetSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_SecretStoreComponent.json - */ -async function getDaprComponentWithSecretStoreComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get(resourceGroupName, environmentName, componentName); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_Secrets.json - */ -async function getDaprComponentWithSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get(resourceGroupName, environmentName, componentName); - console.log(result); -} - -async function main(): Promise { - await getDaprComponentWithSecretStoreComponent(); - await getDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSample.ts deleted file mode 100644 index a9134ea570ad..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr Components for a managed environment. - * - * @summary Get the Dapr Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.daprComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSecretsSample.ts deleted file mode 100644 index 5dcc35701ada..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprComponentsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.listSecrets( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main(): Promise { - await listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsCreateOrUpdateSample.ts deleted file mode 100644 index 7109da721256..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsCreateOrUpdateSample.ts +++ /dev/null @@ -1,116 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { DaprSubscription } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_BulkSubscribeAndScopes.json - */ -async function createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - bulkSubscribe: { - enabled: true, - maxAwaitDurationMs: 500, - maxMessagesCount: 123, - }, - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - scopes: ["warehouseapp", "customersupportapp"], - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_DefaultRoute.json - */ -async function createOrUpdateDaprSubscriptionWithDefaultRouteOnly(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_RouteRulesAndMetadata.json - */ -async function createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - metadata: { foo: "bar", hello: "world" }, - pubsubName: "mypubsubcomponent", - routes: { - default: "/products", - rules: [ - { path: "/widgets", match: "event.type == 'widget'" }, - { path: "/gadgets", match: "event.type == 'gadget'" }, - ], - }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - await createOrUpdateDaprSubscriptionWithDefaultRouteOnly(); - await createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsDeleteSample.ts deleted file mode 100644 index f4748d916069..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr subscription from a Managed Environment. - * - * @summary Delete a Dapr subscription from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Delete.json - */ -async function deleteDaprSubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.delete(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main(): Promise { - await deleteDaprSubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsGetSample.ts deleted file mode 100644 index 65ae30d90c36..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsGetSample.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_DefaultRoute.json - */ -async function getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_BulkSubscribeAndScopes.json - */ -async function getDaprSubscriptionWithDefaultRouteOnly(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_RouteRulesAndMetadata.json - */ -async function getDaprSubscriptionWithRouteRulesAndMetadata(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main(): Promise { - await getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - await getDaprSubscriptionWithDefaultRouteOnly(); - await getDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsListSample.ts deleted file mode 100644 index 6d049d1bc1a1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/daprSubscriptionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr subscriptions for a managed environment. - * - * @summary Get the Dapr subscriptions for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_List.json - */ -async function listDaprSubscriptions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.daprSubscriptions.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listDaprSubscriptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 8f39f7cd5f29..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { DotNetComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate.json - */ -async function createOrUpdateNetComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateNetComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateNetComponent(); - await createOrUpdateNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsDeleteSample.ts deleted file mode 100644 index 0db18c9d77b2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a .NET Component. - * - * @summary Delete a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Delete.json - */ -async function deleteNetComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main(): Promise { - await deleteNetComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsGetSample.ts deleted file mode 100644 index 4e7d41f0e68b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsGetSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get.json - */ -async function getNetComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get_ServiceBind.json - */ -async function getNetComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main(): Promise { - await getNetComponent(); - await getNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsListSample.ts deleted file mode 100644 index 1a32c9a81acd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsListSample.ts +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List.json - */ -async function listNetComponents(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.dotNetComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List_ServiceBind.json - */ -async function listNetComponentsWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.dotNetComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listNetComponents(); - await listNetComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsUpdateSample.ts deleted file mode 100644 index 65b54070f5a6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/dotNetComponentsUpdateSample.ts +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { DotNetComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch.json - */ -async function patchNetComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch_ServiceBind.json - */ -async function patchNetComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchNetComponent(); - await patchNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/functionsExtensionInvokeFunctionsHostSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/functionsExtensionInvokeFunctionsHostSample.ts deleted file mode 100644 index d6be83f11147..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/functionsExtensionInvokeFunctionsHostSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Proxies a Functions host call to the function app backed by the container app. - * - * @summary Proxies a Functions host call to the function app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/FunctionsExtension_Post.json - */ -async function invokeFunctionsHostUsingFunctionsExtensionApi(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const functionAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.functionsExtension.invokeFunctionsHost( - resourceGroupName, - containerAppName, - revisionName, - functionAppName, - ); - console.log(result); -} - -async function main(): Promise { - await invokeFunctionsHostUsingFunctionsExtensionApi(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/getCustomDomainVerificationIdSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/getCustomDomainVerificationIdSample.ts deleted file mode 100644 index 48b3c83f174a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/getCustomDomainVerificationIdSample.ts +++ /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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the verification id of a subscription used for verifying custom domains - * - * @summary Get the verification id of a subscription used for verifying custom domains - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Subscriptions_GetCustomDomainVerificationId.json - */ -async function listAllOperations(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "d27c3573-f76e-4b26-b871-0ccd2203d08c"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.getCustomDomainVerificationId(); - console.log(result); -} - -async function main(): Promise { - await listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsCreateOrUpdateSample.ts deleted file mode 100644 index b8c074139a0f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { JavaComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate.json - */ -async function createOrUpdateJavaComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateJavaComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateJavaComponent(); - await createOrUpdateJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsDeleteSample.ts deleted file mode 100644 index 05927d45fe6c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Java Component. - * - * @summary Delete a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Delete.json - */ -async function deleteJavaComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main(): Promise { - await deleteJavaComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsGetSample.ts deleted file mode 100644 index 3ceaed19debc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsGetSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get.json - */ -async function getJavaComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get_ServiceBind.json - */ -async function getJavaComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main(): Promise { - await getJavaComponent(); - await getJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsListSample.ts deleted file mode 100644 index 3d393d9dd36e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsListSample.ts +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List.json - */ -async function listJavaComponents(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.javaComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List_ServiceBind.json - */ -async function listJavaComponentsWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.javaComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listJavaComponents(); - await listJavaComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsUpdateSample.ts deleted file mode 100644 index e5bc462beabd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/javaComponentsUpdateSample.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { JavaComponent } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch.json - */ -async function patchJavaComponent(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch_ServiceBind.json - */ -async function patchJavaComponentWithServiceBinds(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchJavaComponent(); - await patchJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobExecutionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobExecutionSample.ts deleted file mode 100644 index f3e429424921..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobExecutionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get details of a single job execution - * - * @summary Get details of a single job execution - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Execution_Get.json - */ -async function getASingleJobExecution(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobExecution(resourceGroupName, jobName, jobExecutionName); - console.log(result); -} - -async function main(): Promise { - await getASingleJobExecution(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsCreateOrUpdateSample.ts deleted file mode 100644 index 2a7c73395d7d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsCreateOrUpdateSample.ts +++ /dev/null @@ -1,245 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { Job } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate.json - */ -async function createOrUpdateContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateContainerAppsJobOnAConnectedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_EventTrigger.json - */ -async function createOrUpdateContainerAppsJobWithEventDrivenTrigger(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - eventTriggerConfig: { - parallelism: 4, - replicaCompletionCount: 1, - scale: { - maxExecutions: 5, - minExecutions: 1, - pollingInterval: 40, - rules: [ - { - name: "servicebuscalingrule", - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { topicName: "my-topic" }, - }, - ], - }, - }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Event", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateContainerAppsJob(); - await createOrUpdateContainerAppsJobOnAConnectedEnvironment(); - await createOrUpdateContainerAppsJobWithEventDrivenTrigger(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsDeleteSample.ts deleted file mode 100644 index 7cbe2ce3a0a9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container Apps Job. - * - * @summary Delete a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Delete.json - */ -async function deleteContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testWorkerContainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginDeleteAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await deleteContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsExecutionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsExecutionsListSample.ts deleted file mode 100644 index c7b1585d77ab..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsExecutionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Container Apps Job's executions - * - * @summary Get a Container Apps Job's executions - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Executions_Get.json - */ -async function getAContainerAppsJobExecutions(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.jobsExecutions.list(resourceGroupName, jobName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await getAContainerAppsJobExecutions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetDetectorSample.ts deleted file mode 100644 index d3eb54600260..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the diagnostics data for a Container App Job. - * - * @summary Get the diagnostics data for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_GetDetector.json - */ -async function getDiagnosticDataForAContainerAppJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const detectorName = "containerappjobnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.getDetector(resourceGroupName, jobName, detectorName); - console.log(result); -} - -async function main(): Promise { - await getDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetSample.ts deleted file mode 100644 index e789426e5307..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Container Apps Job. - * - * @summary Get the properties of a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Get.json - */ -async function getContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.get(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await getContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListByResourceGroupSample.ts deleted file mode 100644 index 2bfb29398c44..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given resource group. - * - * @summary Get the Container Apps Jobs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListByResourceGroup.json - */ -async function listContainerAppsJobsByResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.jobs.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppsJobsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListBySubscriptionSample.ts deleted file mode 100644 index 34be7a03f8a1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given subscription. - * - * @summary Get the Container Apps Jobs in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListBySubscription.json - */ -async function listContainerAppsJobsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.jobs.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listContainerAppsJobsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListDetectorsSample.ts deleted file mode 100644 index 19b72fdc6594..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a Container App Job. - * - * @summary Get the list of diagnostics for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListDetectors.json - */ -async function getTheListOfAvailableDiagnosticDataForAContainerAppJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.jobs.listDetectors(resourceGroupName, jobName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await getTheListOfAvailableDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListSecretsSample.ts deleted file mode 100644 index cb0756914344..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a container apps job - * - * @summary List secrets for a container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListSecrets.json - */ -async function listContainerAppsJobSecrets(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.listSecrets(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await listContainerAppsJobSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsProxyGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsProxyGetSample.ts deleted file mode 100644 index 8a0b2ec6334e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsProxyGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Container App Job. - * - * @summary Get the properties of a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ProxyGet.json - */ -async function getContainerAppJobByName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const apiName = "rootApi"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.proxyGet(resourceGroupName, jobName, apiName); - console.log(result); -} - -async function main(): Promise { - await getContainerAppJobByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsResumeSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsResumeSample.ts deleted file mode 100644 index d6db3348885c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsResumeSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Resumes a suspended job - * - * @summary Resumes a suspended job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Resume.json - */ -async function resumeJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginResumeAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await resumeJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStartSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStartSample.ts deleted file mode 100644 index 422ee33fb6c4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStartSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { JobExecutionTemplate, JobsStartOptionalParams } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Start a Container Apps Job - * - * @summary Start a Container Apps Job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Start.json - */ -async function runAContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const template: JobExecutionTemplate = { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }; - const options: JobsStartOptionalParams = { template }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStartAndWait(resourceGroupName, jobName, options); - console.log(result); -} - -async function main(): Promise { - await runAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopExecutionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopExecutionSample.ts deleted file mode 100644 index fc3aef934773..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopExecutionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Execution.json - */ -async function terminateAContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopExecutionAndWait( - resourceGroupName, - jobName, - jobExecutionName, - ); - console.log(result); -} - -async function main(): Promise { - await terminateAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopMultipleExecutionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopMultipleExecutionsSample.ts deleted file mode 100644 index 60ac76cb9cde..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsStopMultipleExecutionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Multiple.json - */ -async function terminateMultipleContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopMultipleExecutionsAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await terminateMultipleContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsSuspendSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsSuspendSample.ts deleted file mode 100644 index e1987dca1df2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsSuspendSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Suspends a job - * - * @summary Suspends a job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Suspend.json - */ -async function suspendJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginSuspendAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main(): Promise { - await suspendJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/jobsUpdateSample.ts deleted file mode 100644 index 4d10de94a4d9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/jobsUpdateSample.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { JobPatchProperties } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Container Apps Job using JSON Merge Patch - * - * @summary Patches a Container Apps Job using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Patch.json - */ -async function patchContainerAppsJob(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: JobPatchProperties = { - properties: { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginUpdateAndWait(resourceGroupName, jobName, jobEnvelope); - console.log(result); -} - -async function main(): Promise { - await patchContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsCreateOrUpdateSample.ts deleted file mode 100644 index 650b9893fe26..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsCreateOrUpdateSample.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. - */ -import type { LogicApp } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a Logic App extension resource - * - * @summary Create or update a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Create.json - */ -async function createLogicAppExtension(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const resource: LogicApp = { properties: {} }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.createOrUpdate( - resourceGroupName, - containerAppName, - logicAppName, - resource, - ); - console.log(result); -} - -async function main(): Promise { - await createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeleteSample.ts deleted file mode 100644 index c30c3f8ad929..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes a Logic App extension resource - * - * @summary Deletes a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Delete.json - */ -async function createLogicAppExtension(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.delete(resourceGroupName, containerAppName, logicAppName); - console.log(result); -} - -async function main(): Promise { - await createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeployWorkflowArtifactsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeployWorkflowArtifactsSample.ts deleted file mode 100644 index 28da67f36449..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsDeployWorkflowArtifactsSample.ts +++ /dev/null @@ -1,120 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { - WorkflowArtifacts, - LogicAppsDeployWorkflowArtifactsOptionalParams, -} from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_DeleteDeployWorkflowArtifacts.json - */ -async function deleteWorkflowArtifacts(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts: WorkflowArtifacts = { - filesToDelete: ["test/workflow.json", "test/"], - }; - const options: LogicAppsDeployWorkflowArtifactsOptionalParams = { - workflowArtifacts, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_PostDeployWorkflowArtifacts.json - */ -async function deploysWorkflowArtifacts(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts: WorkflowArtifacts = { - appSettings: { - eventHub_connectionString: - "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=", - }, - files: { - "connections.json": { - managedApiConnections: {}, - serviceProviderConnections: { - eventHub: { - displayName: "example1", - parameterValues: { - connectionString: "@appsetting('eventHub_connectionString')", - }, - serviceProvider: { id: "/serviceProviders/eventHub" }, - }, - }, - }, - "test1/workflow.json": { - 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: LogicAppsDeployWorkflowArtifactsOptionalParams = { - workflowArtifacts, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await deleteWorkflowArtifacts(); - await deploysWorkflowArtifacts(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetSample.ts deleted file mode 100644 index f79dcc46c6e0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets a logic app extension resource. - * - * @summary Gets a logic app extension resource. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Get.json - */ -async function getLogicAppExtensionByName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.get(resourceGroupName, containerAppName, logicAppName); - console.log(result); -} - -async function main(): Promise { - await getLogicAppExtensionByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetWorkflowSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetWorkflowSample.ts deleted file mode 100644 index f884ca05ab90..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsGetWorkflowSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get workflow information by its name - * - * @summary Get workflow information by its name - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_GetWorkflow.json - */ -async function getAWorkflow(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const workflowName = "stateful1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.getWorkflow( - resourceGroupName, - containerAppName, - logicAppName, - workflowName, - ); - console.log(result); -} - -async function main(): Promise { - await getAWorkflow(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsInvokeSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsInvokeSample.ts deleted file mode 100644 index d73ca92586df..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsInvokeSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Proxies a the API call to the logic app backed by the container app. - * - * @summary Proxies a the API call to the logic app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListCallbackURL.json - */ -async function getWorkflowListCallBackUrl(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.invoke( - resourceGroupName, - containerAppName, - logicAppName, - "/runtime/webhooks/workflow/api/management/workflows/Stateful1/triggers/When_a_HTTP_request_is_received/listCallbackUrl", - "POST", - ); - console.log(result); -} - -async function main(): Promise { - await getWorkflowListCallBackUrl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsConnectionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsConnectionsSample.ts deleted file mode 100644 index 7e190854318f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsConnectionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets logic app's connections. - * - * @summary Gets logic app's connections. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListConnections.json - */ -async function listTheWorkflowsConfigurationConnections(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.listWorkflowsConnections( - resourceGroupName, - containerAppName, - logicAppName, - ); - console.log(result); -} - -async function main(): Promise { - await listTheWorkflowsConfigurationConnections(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsSample.ts deleted file mode 100644 index ea76cfe91441..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/logicAppsListWorkflowsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List the workflows for a logic app. - * - * @summary List the workflows for a logic app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListWorkflows.json - */ -async function listTheWorkflows(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.logicApps.listWorkflows( - resourceGroupName, - containerAppName, - logicAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listTheWorkflows(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesCreateOrUpdateSample.ts deleted file mode 100644 index 747651321e98..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { - ManagedCertificate, - ManagedCertificatesCreateOrUpdateOptionalParams, -} from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Managed Certificate. - * - * @summary Create or Update a Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope: ManagedCertificate = { - location: "East US", - properties: { - domainControlValidation: "CNAME", - subjectName: "my-subject-name.company.country.net", - }, - }; - const options: ManagedCertificatesCreateOrUpdateOptionalParams = { - managedCertificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - managedCertificateName, - options, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesDeleteSample.ts deleted file mode 100644 index 0f882b43aaad..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Managed Certificate. - * - * @summary Deletes the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Delete.json - */ -async function deleteCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.delete( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesGetSample.ts deleted file mode 100644 index 3ca0ebb07ba7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Managed Certificate. - * - * @summary Get the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Get.json - */ -async function getCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.get( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main(): Promise { - await getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesListSample.ts deleted file mode 100644 index 2fd02c5da45d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Managed Certificates in a given managed environment. - * - * @summary Get the Managed Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_ListByManagedEnvironment.json - */ -async function listManagedCertificatesByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedCertificates.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listManagedCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesUpdateSample.ts deleted file mode 100644 index e5ae268e8038..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedCertificatesUpdateSample.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. - */ -import type { ManagedCertificatePatch } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a managed certificate. Oly patching of tags is supported - * - * @summary Patches a managed certificate. Oly patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_Patch.json - */ -async function patchManagedCertificate(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope: ManagedCertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.update( - resourceGroupName, - environmentName, - managedCertificateName, - managedCertificateEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchManagedCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsGetDetectorSample.ts deleted file mode 100644 index 563ac1a34105..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the diagnostics data for a Managed Environment used to host container apps. - * - * @summary Get the diagnostics data for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_Get.json - */ -async function getDiagnosticDataForAManagedEnvironments(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const detectorName = "ManagedEnvAvailabilityMetrics"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.getDetector( - resourceGroupName, - environmentName, - detectorName, - ); - console.log(result); -} - -async function main(): Promise { - await getDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsListDetectorsSample.ts deleted file mode 100644 index 79beaef7807e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentDiagnosticsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a Managed Environment used to host container apps. - * - * @summary Get the list of diagnostics for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticDataForAManagedEnvironments(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.listDetectors( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main(): Promise { - await getTheListOfAvailableDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts deleted file mode 100644 index 8c094d1c506f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { PrivateEndpointConnection } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update the state of a private endpoint connection for a given managed environment. - * - * @summary Update the state of a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_CreateOrUpdate.json - */ -async function updateAPrivateEndpointConnectionByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const privateEndpointConnectionEnvelope: PrivateEndpointConnection = { - privateLinkServiceConnectionState: { - actionsRequired: "None", - status: "Approved", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.managedEnvironmentPrivateEndpointConnections.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - privateEndpointConnectionEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await updateAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts deleted file mode 100644 index 1cdc466f9d48..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a private endpoint connection for a given managed environment. - * - * @summary Delete a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Delete.json - */ -async function deleteAPrivateEndpointConnectionByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentPrivateEndpointConnections.beginDeleteAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsGetSample.ts deleted file mode 100644 index 8f685b275295..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a private endpoint connection for a given managed environment. - * - * @summary Get a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Get.json - */ -async function getAPrivateEndpointConnectionByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentPrivateEndpointConnections.get( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main(): Promise { - await getAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsListSample.ts deleted file mode 100644 index 2335bde6ef66..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateEndpointConnectionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List private endpoint connections for a given managed environment. - * - * @summary List private endpoint connections for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_List.json - */ -async function listPrivateEndpointConnectionsByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironmentPrivateEndpointConnections.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listPrivateEndpointConnectionsByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateLinkResourcesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateLinkResourcesListSample.ts deleted file mode 100644 index 19d27574d9b7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentPrivateLinkResourcesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List private link resources for a given managed environment. - * - * @summary List private link resources for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateLinkResources_List.json - */ -async function listPrivateLinkResourcesByManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironmentPrivateLinkResources.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listPrivateLinkResourcesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentUsagesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentUsagesListSample.ts deleted file mode 100644 index c33277c44406..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentUsagesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets the current usage information as well as the limits for environment. - * - * @summary Gets the current usage information as well as the limits for environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentUsages_List.json - */ -async function listManagedEnvironmentUsages(): Promise { - const subscriptionId = process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironmentUsages.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listManagedEnvironmentUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 14fbad223c19..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,177 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ManagedEnvironment } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CustomInfrastructureResourceGroup_Create.json - */ -async function createEnvironmentWithCustomInfrastructureResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - infrastructureResourceGroup: "myInfrastructureRgName", - location: "East US", - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appInsightsConfiguration: { - connectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://eastus-8.in.applicationinsights.azure.com/;LiveEndpoint=https://eastus.livediagnostics.monitor.azure.com/", - }, - appLogsConfiguration: { - logAnalyticsConfiguration: { - customerId: "string", - dynamicJsonColumns: true, - sharedKey: "string", - }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - identity: { - type: "SystemAssigned, UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/contosoResources/providers/MicrosoftManagedIdentity/userAssignedIdentities/contosoIdentity": - {}, - }, - }, - location: "East US", - openTelemetryConfiguration: { - destinationsConfiguration: { - dataDogConfiguration: { - key: "000000000000000000000000", - site: "string", - }, - otlpConfigurations: [ - { - name: "dashboard", - endpoint: "dashboard.k8s.region.azurecontainerapps.io:80", - headers: [{ key: "api-key", value: "xxxxxxxxxxx" }], - insecure: true, - }, - ], - }, - logsConfiguration: { destinations: ["appInsights"] }, - metricsConfiguration: { destinations: ["dataDog"], includeKeda: true }, - tracesConfiguration: { destinations: ["appInsights"], includeDapr: true }, - }, - peerAuthentication: { mtls: { enabled: true } }, - peerTrafficConfiguration: { encryption: { enabled: true } }, - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createEnvironmentWithCustomInfrastructureResourceGroup(); - await createEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDeleteSample.ts deleted file mode 100644 index 6031e4bd0f4f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Managed Environment if it does not have any container apps. - * - * @summary Delete a Managed Environment if it does not have any container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main(): Promise { - await deleteEnvironmentByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDiagnosticsGetRootSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDiagnosticsGetRootSample.ts deleted file mode 100644 index bbe6d37b44a4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsDiagnosticsGetRootSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsDiagnostics.getRoot( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main(): Promise { - await getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetAuthTokenSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetAuthTokenSample.ts deleted file mode 100644 index b5076cf8d307..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetAuthTokenSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_GetAuthToken.json - */ -async function getManagedEnvironmentAuthToken(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const environmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.getAuthToken(resourceGroupName, environmentName); - console.log(result); -} - -async function main(): Promise { - await getManagedEnvironmentAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetSample.ts deleted file mode 100644 index d98c0787c03f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get(resourceGroupName, environmentName); - console.log(result); -} - -async function main(): Promise { - await getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index 0474e1b28a73..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all the Managed Environments in a resource group. - * - * @summary Get all the Managed Environments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index 541f15eeb6d4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all Managed Environments for a subscription. - * - * @summary Get all Managed Environments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListWorkloadProfileStatesSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListWorkloadProfileStatesSample.ts deleted file mode 100644 index 6672dc4d7dd0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsListWorkloadProfileStatesSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all workload Profile States for a Managed Environment. - * - * @summary Get all workload Profile States for a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListWorkloadProfileStates.json - */ -async function listEnvironmentsBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.managedEnvironments.listWorkloadProfileStates( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 641fcac817de..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import type { ManagedEnvironmentStorage } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ManagedEnvironmentStorage = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate_NfsAzureFile.json - */ -async function createOrUpdateEnvironmentsStorageForNfsAzureFile(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ManagedEnvironmentStorage = { - properties: { - nfsAzureFile: { - accessMode: "ReadOnly", - server: "server1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await createOrUpdateEnvironmentsStorage(); - await createOrUpdateEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index d1bc7c207659..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete storage for a managedEnvironment. - * - * @summary Delete storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main(): Promise { - await listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index bb237f29115b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesGetSample.ts +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStorage(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get_NfsAzureFile.json - */ -async function getAEnvironmentsStorageForNfsAzureFile(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main(): Promise { - await getAEnvironmentsStorage(); - await getAEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesListSample.ts deleted file mode 100644 index 6744e4421ba6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsStoragesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all storages for a managedEnvironment. - * - * @summary Get all storages for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list(resourceGroupName, environmentName); - console.log(result); -} - -async function main(): Promise { - await listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsUpdateSample.ts deleted file mode 100644 index 0e72d1f85e75..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/managedEnvironmentsUpdateSample.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. - */ -import type { ManagedEnvironment } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Managed Environment using JSON Merge Patch - * - * @summary Patches a Managed Environment using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main(): Promise { - await patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/namespacesCheckNameAvailabilitySample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/namespacesCheckNameAvailabilitySample.ts deleted file mode 100644 index d302ba685ab2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/namespacesCheckNameAvailabilitySample.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. - */ -import type { CheckNameAvailabilityRequest } from "@azure/arm-appcontainers"; -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/managedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CheckNameAvailability.json - */ -async function containerAppsCheckNameAvailability(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcappname", - type: "Microsoft.App/containerApps", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main(): Promise { - await certificatesCheckNameAvailability(); - await containerAppsCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/operationsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/operationsListSample.ts deleted file mode 100644 index 128cc1e9b1b7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/operationsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Lists all of the available RP operations. - * - * @summary Lists all of the available RP operations. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Operations_List.json - */ -async function listAllOperations(): Promise { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.operations.list()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples-dev/usagesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples-dev/usagesListSample.ts deleted file mode 100644 index 6ab79495c443..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples-dev/usagesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * - * @summary Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Usages_List.json - */ -async function listUsages(): Promise { - const subscriptionId = process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const location = "westus"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (const item of client.usages.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main(): Promise { - await listUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/README.md b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/README.md deleted file mode 100644 index 39115b020d03..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/README.md +++ /dev/null @@ -1,384 +0,0 @@ -# client library samples for JavaScript (Beta) - -These sample programs show how to use the JavaScript client libraries for in some common scenarios. - -| **File Name** | **Description** | -| --------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| [appResiliencyCreateOrUpdateSample.js][appresiliencycreateorupdatesample] | Create or update container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_CreateOrUpdate.json | -| [appResiliencyDeleteSample.js][appresiliencydeletesample] | Delete container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Delete.json | -| [appResiliencyGetSample.js][appresiliencygetsample] | Get container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Get.json | -| [appResiliencyListSample.js][appresiliencylistsample] | List container app resiliency policies. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_List.json | -| [appResiliencyUpdateSample.js][appresiliencyupdatesample] | Update container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Patch.json | -| [availableWorkloadProfilesGetSample.js][availableworkloadprofilesgetsample] | Get all available workload profiles for a location. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AvailableWorkloadProfiles_Get.json | -| [billingMetersGetSample.js][billingmetersgetsample] | Get all billingMeters for a location. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/BillingMeters_Get.json | -| [buildAuthTokenListSample.js][buildauthtokenlistsample] | Gets the token used to connect to the endpoint where source code can be uploaded for a build. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListAuthToken.json | -| [buildersCreateOrUpdateSample.js][builderscreateorupdatesample] | Create or update a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_CreateOrUpdate.json | -| [buildersDeleteSample.js][buildersdeletesample] | Delete a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Delete.json | -| [buildersGetSample.js][buildersgetsample] | Get a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Get.json | -| [buildersListByResourceGroupSample.js][builderslistbyresourcegroupsample] | List BuilderResource resources by resource group x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListByResourceGroup.json | -| [buildersListBySubscriptionSample.js][builderslistbysubscriptionsample] | List BuilderResource resources by subscription ID x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListBySubscription.json | -| [buildersUpdateSample.js][buildersupdatesample] | Update a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Update.json | -| [buildsByBuilderResourceListSample.js][buildsbybuilderresourcelistsample] | List BuildResource resources by BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListByBuilderResource.json | -| [buildsCreateOrUpdateSample.js][buildscreateorupdatesample] | Create a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate_NoConfig.json | -| [buildsDeleteSample.js][buildsdeletesample] | Delete a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Delete.json | -| [buildsGetSample.js][buildsgetsample] | Get a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Get.json | -| [certificatesCreateOrUpdateSample.js][certificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate.json | -| [certificatesDeleteSample.js][certificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Delete.json | -| [certificatesGetSample.js][certificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Get.json | -| [certificatesListSample.js][certificateslistsample] | Get the Certificates in a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_ListByManagedEnvironment.json | -| [certificatesUpdateSample.js][certificatesupdatesample] | Patches a certificate. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_Patch.json | -| [connectedEnvironmentsCertificatesCreateOrUpdateSample.js][connectedenvironmentscertificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_CreateOrUpdate.json | -| [connectedEnvironmentsCertificatesDeleteSample.js][connectedenvironmentscertificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Delete.json | -| [connectedEnvironmentsCertificatesGetSample.js][connectedenvironmentscertificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Get.json | -| [connectedEnvironmentsCertificatesListSample.js][connectedenvironmentscertificateslistsample] | Get the Certificates in a given connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_ListByConnectedEnvironment.json | -| [connectedEnvironmentsCertificatesUpdateSample.js][connectedenvironmentscertificatesupdatesample] | Patches a certificate. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_Patch.json | -| [connectedEnvironmentsCheckNameAvailabilitySample.js][connectedenvironmentschecknameavailabilitysample] | Checks if resource connectedEnvironmentName is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_CheckNameAvailability.json | -| [connectedEnvironmentsCreateOrUpdateSample.js][connectedenvironmentscreateorupdatesample] | Creates or updates an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_CreateOrUpdate.json | -| [connectedEnvironmentsDaprComponentsCreateOrUpdateSample.js][connectedenvironmentsdaprcomponentscreateorupdatesample] | Creates or updates a Dapr Component in a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_CreateOrUpdate.json | -| [connectedEnvironmentsDaprComponentsDeleteSample.js][connectedenvironmentsdaprcomponentsdeletesample] | Delete a Dapr Component from a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Delete.json | -| [connectedEnvironmentsDaprComponentsGetSample.js][connectedenvironmentsdaprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Get.json | -| [connectedEnvironmentsDaprComponentsListSample.js][connectedenvironmentsdaprcomponentslistsample] | Get the Dapr Components for a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_List.json | -| [connectedEnvironmentsDaprComponentsListSecretsSample.js][connectedenvironmentsdaprcomponentslistsecretssample] | List secrets for a dapr component x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_ListSecrets.json | -| [connectedEnvironmentsDeleteSample.js][connectedenvironmentsdeletesample] | Delete an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Delete.json | -| [connectedEnvironmentsGetSample.js][connectedenvironmentsgetsample] | Get the properties of an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Get.json | -| [connectedEnvironmentsListByResourceGroupSample.js][connectedenvironmentslistbyresourcegroupsample] | Get all connectedEnvironments in a resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListByResourceGroup.json | -| [connectedEnvironmentsListBySubscriptionSample.js][connectedenvironmentslistbysubscriptionsample] | Get all connectedEnvironments for a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListBySubscription.json | -| [connectedEnvironmentsStoragesCreateOrUpdateSample.js][connectedenvironmentsstoragescreateorupdatesample] | Create or update storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_CreateOrUpdate.json | -| [connectedEnvironmentsStoragesDeleteSample.js][connectedenvironmentsstoragesdeletesample] | Delete storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Delete.json | -| [connectedEnvironmentsStoragesGetSample.js][connectedenvironmentsstoragesgetsample] | Get storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Get.json | -| [connectedEnvironmentsStoragesListSample.js][connectedenvironmentsstorageslistsample] | Get all storages for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_List.json | -| [connectedEnvironmentsUpdateSample.js][connectedenvironmentsupdatesample] | Patches a Managed Environment. Only patching of tags is supported currently x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Patch.json | -| [containerAppsAuthConfigsCreateOrUpdateSample.js][containerappsauthconfigscreateorupdatesample] | Create or update the AuthConfig for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_CreateOrUpdate.json | -| [containerAppsAuthConfigsDeleteSample.js][containerappsauthconfigsdeletesample] | Delete a Container App AuthConfig. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Delete.json | -| [containerAppsAuthConfigsGetSample.js][containerappsauthconfigsgetsample] | Get a AuthConfig of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Get.json | -| [containerAppsAuthConfigsListByContainerAppSample.js][containerappsauthconfigslistbycontainerappsample] | Get the Container App AuthConfigs in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_ListByContainer.json | -| [containerAppsBuildsByContainerAppListSample.js][containerappsbuildsbycontainerapplistsample] | List Container Apps Build resources by Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_ListByContainerApp.json | -| [containerAppsBuildsDeleteSample.js][containerappsbuildsdeletesample] | Delete a Container Apps Build resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Delete.json | -| [containerAppsBuildsGetSample.js][containerappsbuildsgetsample] | Get a Container Apps Build resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Get.json | -| [containerAppsCreateOrUpdateSample.js][containerappscreateorupdatesample] | Create or update a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Kind_CreateOrUpdate.json | -| [containerAppsDeleteSample.js][containerappsdeletesample] | Delete a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Delete.json | -| [containerAppsDiagnosticsGetDetectorSample.js][containerappsdiagnosticsgetdetectorsample] | Get a diagnostics result of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_Get.json | -| [containerAppsDiagnosticsGetRevisionSample.js][containerappsdiagnosticsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json | -| [containerAppsDiagnosticsGetRootSample.js][containerappsdiagnosticsgetrootsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json | -| [containerAppsDiagnosticsListDetectorsSample.js][containerappsdiagnosticslistdetectorssample] | Get the list of diagnostics for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_List.json | -| [containerAppsDiagnosticsListRevisionsSample.js][containerappsdiagnosticslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json | -| [containerAppsGetAuthTokenSample.js][containerappsgetauthtokensample] | Get auth token for a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_GetAuthToken.json | -| [containerAppsGetSample.js][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json | -| [containerAppsListByResourceGroupSample.js][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListByResourceGroup.json | -| [containerAppsListBySubscriptionSample.js][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListBySubscription.json | -| [containerAppsListCustomHostNameAnalysisSample.js][containerappslistcustomhostnameanalysissample] | Analyzes a custom hostname for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json | -| [containerAppsListSecretsSample.js][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListSecrets.json | -| [containerAppsPatchesApplySample.js][containerappspatchesapplysample] | Apply a Container Apps Patch resource with patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Apply.json | -| [containerAppsPatchesDeleteSample.js][containerappspatchesdeletesample] | Delete specific Container Apps Patch by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Delete.json | -| [containerAppsPatchesGetSample.js][containerappspatchesgetsample] | Get details for specific Container Apps Patch by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Get.json | -| [containerAppsPatchesListByContainerAppSample.js][containerappspatcheslistbycontainerappsample] | List Container Apps Patch resources by ContainerApp. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_ListByContainerApp.json | -| [containerAppsPatchesSkipConfigureSample.js][containerappspatchesskipconfiguresample] | Configure the Container Apps Patch skip option by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Skip_Configure.json | -| [containerAppsRevisionReplicasGetReplicaSample.js][containerappsrevisionreplicasgetreplicasample] | Get a replica for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_Get.json | -| [containerAppsRevisionReplicasListReplicasSample.js][containerappsrevisionreplicaslistreplicassample] | List replicas for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_List.json | -| [containerAppsRevisionsActivateRevisionSample.js][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Activate.json | -| [containerAppsRevisionsDeactivateRevisionSample.js][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Deactivate.json | -| [containerAppsRevisionsGetRevisionSample.js][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json | -| [containerAppsRevisionsListRevisionsSample.js][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json | -| [containerAppsRevisionsRestartRevisionSample.js][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Restart.json | -| [containerAppsSessionPoolsCreateOrUpdateSample.js][containerappssessionpoolscreateorupdatesample] | Create or update a session pool with the given properties. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_CreateOrUpdate.json | -| [containerAppsSessionPoolsDeleteSample.js][containerappssessionpoolsdeletesample] | Delete the session pool with the given name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Delete.json | -| [containerAppsSessionPoolsGetSample.js][containerappssessionpoolsgetsample] | Get the properties of a session pool. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Get.json | -| [containerAppsSessionPoolsListByResourceGroupSample.js][containerappssessionpoolslistbyresourcegroupsample] | Get the session pools in a given resource group of a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListByResourceGroup.json | -| [containerAppsSessionPoolsListBySubscriptionSample.js][containerappssessionpoolslistbysubscriptionsample] | Get the session pools in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListBySubscription.json | -| [containerAppsSessionPoolsUpdateSample.js][containerappssessionpoolsupdatesample] | Patches a session pool using JSON merge patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Patch.json | -| [containerAppsSourceControlsCreateOrUpdateSample.js][containerappssourcecontrolscreateorupdatesample] | Create or update the SourceControl for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_CreateOrUpdate.json | -| [containerAppsSourceControlsDeleteSample.js][containerappssourcecontrolsdeletesample] | Delete a Container App SourceControl. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Delete.json | -| [containerAppsSourceControlsGetSample.js][containerappssourcecontrolsgetsample] | Get a SourceControl of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Get.json | -| [containerAppsSourceControlsListByContainerAppSample.js][containerappssourcecontrolslistbycontainerappsample] | Get the Container App SourceControls in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_ListByContainer.json | -| [containerAppsStartSample.js][containerappsstartsample] | Start a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Start.json | -| [containerAppsStopSample.js][containerappsstopsample] | Stop a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Stop.json | -| [containerAppsUpdateSample.js][containerappsupdatesample] | Patches a Container App using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Patch.json | -| [daprComponentResiliencyPoliciesCreateOrUpdateSample.js][daprcomponentresiliencypoliciescreateorupdatesample] | Creates or updates a resiliency policy for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_AllOptions.json | -| [daprComponentResiliencyPoliciesDeleteSample.js][daprcomponentresiliencypoliciesdeletesample] | Delete a resiliency policy for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Delete.json | -| [daprComponentResiliencyPoliciesGetSample.js][daprcomponentresiliencypoliciesgetsample] | Get a Dapr component resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Get.json | -| [daprComponentResiliencyPoliciesListSample.js][daprcomponentresiliencypolicieslistsample] | Get the resiliency policies for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_List.json | -| [daprComponentsCreateOrUpdateSample.js][daprcomponentscreateorupdatesample] | Creates or updates a Dapr Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_SecretStoreComponent.json | -| [daprComponentsDeleteSample.js][daprcomponentsdeletesample] | Delete a Dapr Component from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Delete.json | -| [daprComponentsGetSample.js][daprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_SecretStoreComponent.json | -| [daprComponentsListSample.js][daprcomponentslistsample] | Get the Dapr Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_List.json | -| [daprComponentsListSecretsSample.js][daprcomponentslistsecretssample] | List secrets for a dapr component x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_ListSecrets.json | -| [daprSubscriptionsCreateOrUpdateSample.js][daprsubscriptionscreateorupdatesample] | Creates or updates a Dapr subscription in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_BulkSubscribeAndScopes.json | -| [daprSubscriptionsDeleteSample.js][daprsubscriptionsdeletesample] | Delete a Dapr subscription from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Delete.json | -| [daprSubscriptionsGetSample.js][daprsubscriptionsgetsample] | Get a dapr subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_DefaultRoute.json | -| [daprSubscriptionsListSample.js][daprsubscriptionslistsample] | Get the Dapr subscriptions for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_List.json | -| [dotNetComponentsCreateOrUpdateSample.js][dotnetcomponentscreateorupdatesample] | Creates or updates a .NET Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate.json | -| [dotNetComponentsDeleteSample.js][dotnetcomponentsdeletesample] | Delete a .NET Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Delete.json | -| [dotNetComponentsGetSample.js][dotnetcomponentsgetsample] | Get a .NET Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get.json | -| [dotNetComponentsListSample.js][dotnetcomponentslistsample] | Get the .NET Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List.json | -| [dotNetComponentsUpdateSample.js][dotnetcomponentsupdatesample] | Patches a .NET Component using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch.json | -| [functionsExtensionInvokeFunctionsHostSample.js][functionsextensioninvokefunctionshostsample] | Proxies a Functions host call to the function app backed by the container app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/FunctionsExtension_Post.json | -| [getCustomDomainVerificationIdSample.js][getcustomdomainverificationidsample] | Get the verification id of a subscription used for verifying custom domains x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Subscriptions_GetCustomDomainVerificationId.json | -| [javaComponentsCreateOrUpdateSample.js][javacomponentscreateorupdatesample] | Creates or updates a Java Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate.json | -| [javaComponentsDeleteSample.js][javacomponentsdeletesample] | Delete a Java Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Delete.json | -| [javaComponentsGetSample.js][javacomponentsgetsample] | Get a Java Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get.json | -| [javaComponentsListSample.js][javacomponentslistsample] | Get the Java Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List.json | -| [javaComponentsUpdateSample.js][javacomponentsupdatesample] | Patches a Java Component using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch.json | -| [jobExecutionSample.js][jobexecutionsample] | Get details of a single job execution x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Execution_Get.json | -| [jobsCreateOrUpdateSample.js][jobscreateorupdatesample] | Create or Update a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate.json | -| [jobsDeleteSample.js][jobsdeletesample] | Delete a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Delete.json | -| [jobsExecutionsListSample.js][jobsexecutionslistsample] | Get a Container Apps Job's executions x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Executions_Get.json | -| [jobsGetDetectorSample.js][jobsgetdetectorsample] | Get the diagnostics data for a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_GetDetector.json | -| [jobsGetSample.js][jobsgetsample] | Get the properties of a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Get.json | -| [jobsListByResourceGroupSample.js][jobslistbyresourcegroupsample] | Get the Container Apps Jobs in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListByResourceGroup.json | -| [jobsListBySubscriptionSample.js][jobslistbysubscriptionsample] | Get the Container Apps Jobs in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListBySubscription.json | -| [jobsListDetectorsSample.js][jobslistdetectorssample] | Get the list of diagnostics for a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListDetectors.json | -| [jobsListSecretsSample.js][jobslistsecretssample] | List secrets for a container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListSecrets.json | -| [jobsProxyGetSample.js][jobsproxygetsample] | Get the properties of a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ProxyGet.json | -| [jobsResumeSample.js][jobsresumesample] | Resumes a suspended job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Resume.json | -| [jobsStartSample.js][jobsstartsample] | Start a Container Apps Job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Start.json | -| [jobsStopExecutionSample.js][jobsstopexecutionsample] | Terminates execution of a running container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Execution.json | -| [jobsStopMultipleExecutionsSample.js][jobsstopmultipleexecutionssample] | Terminates execution of a running container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Multiple.json | -| [jobsSuspendSample.js][jobssuspendsample] | Suspends a job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Suspend.json | -| [jobsUpdateSample.js][jobsupdatesample] | Patches a Container Apps Job using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Patch.json | -| [logicAppsCreateOrUpdateSample.js][logicappscreateorupdatesample] | Create or update a Logic App extension resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Create.json | -| [logicAppsDeleteSample.js][logicappsdeletesample] | Deletes a Logic App extension resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Delete.json | -| [logicAppsDeployWorkflowArtifactsSample.js][logicappsdeployworkflowartifactssample] | Creates or updates the artifacts for the logic app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_DeleteDeployWorkflowArtifacts.json | -| [logicAppsGetSample.js][logicappsgetsample] | Gets a logic app extension resource. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Get.json | -| [logicAppsGetWorkflowSample.js][logicappsgetworkflowsample] | Get workflow information by its name x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_GetWorkflow.json | -| [logicAppsInvokeSample.js][logicappsinvokesample] | Proxies a the API call to the logic app backed by the container app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListCallbackURL.json | -| [logicAppsListWorkflowsConnectionsSample.js][logicappslistworkflowsconnectionssample] | Gets logic app's connections. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListConnections.json | -| [logicAppsListWorkflowsSample.js][logicappslistworkflowssample] | List the workflows for a logic app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListWorkflows.json | -| [managedCertificatesCreateOrUpdateSample.js][managedcertificatescreateorupdatesample] | Create or Update a Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_CreateOrUpdate.json | -| [managedCertificatesDeleteSample.js][managedcertificatesdeletesample] | Deletes the specified Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Delete.json | -| [managedCertificatesGetSample.js][managedcertificatesgetsample] | Get the specified Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Get.json | -| [managedCertificatesListSample.js][managedcertificateslistsample] | Get the Managed Certificates in a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_ListByManagedEnvironment.json | -| [managedCertificatesUpdateSample.js][managedcertificatesupdatesample] | Patches a managed certificate. Oly patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_Patch.json | -| [managedEnvironmentDiagnosticsGetDetectorSample.js][managedenvironmentdiagnosticsgetdetectorsample] | Get the diagnostics data for a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_Get.json | -| [managedEnvironmentDiagnosticsListDetectorsSample.js][managedenvironmentdiagnosticslistdetectorssample] | Get the list of diagnostics for a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_List.json | -| [managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js][managedenvironmentprivateendpointconnectionscreateorupdatesample] | Update the state of a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_CreateOrUpdate.json | -| [managedEnvironmentPrivateEndpointConnectionsDeleteSample.js][managedenvironmentprivateendpointconnectionsdeletesample] | Delete a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Delete.json | -| [managedEnvironmentPrivateEndpointConnectionsGetSample.js][managedenvironmentprivateendpointconnectionsgetsample] | Get a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Get.json | -| [managedEnvironmentPrivateEndpointConnectionsListSample.js][managedenvironmentprivateendpointconnectionslistsample] | List private endpoint connections for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_List.json | -| [managedEnvironmentPrivateLinkResourcesListSample.js][managedenvironmentprivatelinkresourceslistsample] | List private link resources for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateLinkResources_List.json | -| [managedEnvironmentUsagesListSample.js][managedenvironmentusageslistsample] | Gets the current usage information as well as the limits for environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentUsages_List.json | -| [managedEnvironmentsCreateOrUpdateSample.js][managedenvironmentscreateorupdatesample] | Creates or updates a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CustomInfrastructureResourceGroup_Create.json | -| [managedEnvironmentsDeleteSample.js][managedenvironmentsdeletesample] | Delete a Managed Environment if it does not have any container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Delete.json | -| [managedEnvironmentsDiagnosticsGetRootSample.js][managedenvironmentsdiagnosticsgetrootsample] | Get the properties of a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json | -| [managedEnvironmentsGetAuthTokenSample.js][managedenvironmentsgetauthtokensample] | Checks if resource name is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_GetAuthToken.json | -| [managedEnvironmentsGetSample.js][managedenvironmentsgetsample] | Get the properties of a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json | -| [managedEnvironmentsListByResourceGroupSample.js][managedenvironmentslistbyresourcegroupsample] | Get all the Managed Environments in a resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListByResourceGroup.json | -| [managedEnvironmentsListBySubscriptionSample.js][managedenvironmentslistbysubscriptionsample] | Get all Managed Environments for a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListBySubscription.json | -| [managedEnvironmentsListWorkloadProfileStatesSample.js][managedenvironmentslistworkloadprofilestatessample] | Get all workload Profile States for a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListWorkloadProfileStates.json | -| [managedEnvironmentsStoragesCreateOrUpdateSample.js][managedenvironmentsstoragescreateorupdatesample] | Create or update storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json | -| [managedEnvironmentsStoragesDeleteSample.js][managedenvironmentsstoragesdeletesample] | Delete storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Delete.json | -| [managedEnvironmentsStoragesGetSample.js][managedenvironmentsstoragesgetsample] | Get storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get.json | -| [managedEnvironmentsStoragesListSample.js][managedenvironmentsstorageslistsample] | Get all storages for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_List.json | -| [managedEnvironmentsUpdateSample.js][managedenvironmentsupdatesample] | Patches a Managed Environment using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Patch.json | -| [namespacesCheckNameAvailabilitySample.js][namespaceschecknameavailabilitysample] | Checks if resource name is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_CheckNameAvailability.json | -| [operationsListSample.js][operationslistsample] | Lists all of the available RP operations. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Operations_List.json | -| [usagesListSample.js][usageslistsample] | Gets, for the specified location, the current resource usage information as well as the limits under the subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Usages_List.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 appResiliencyCreateOrUpdateSample.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 dev-tool run vendored cross-env APPCONTAINERS_SUBSCRIPTION_ID="" APPCONTAINERS_RESOURCE_GROUP="" node appResiliencyCreateOrUpdateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[appresiliencycreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyCreateOrUpdateSample.js -[appresiliencydeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyDeleteSample.js -[appresiliencygetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyGetSample.js -[appresiliencylistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyListSample.js -[appresiliencyupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyUpdateSample.js -[availableworkloadprofilesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/availableWorkloadProfilesGetSample.js -[billingmetersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/billingMetersGetSample.js -[buildauthtokenlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildAuthTokenListSample.js -[builderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersCreateOrUpdateSample.js -[buildersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersDeleteSample.js -[buildersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersGetSample.js -[builderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListByResourceGroupSample.js -[builderslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListBySubscriptionSample.js -[buildersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersUpdateSample.js -[buildsbybuilderresourcelistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsByBuilderResourceListSample.js -[buildscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsCreateOrUpdateSample.js -[buildsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsDeleteSample.js -[buildsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsGetSample.js -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesCreateOrUpdateSample.js -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesDeleteSample.js -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesGetSample.js -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesListSample.js -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesUpdateSample.js -[connectedenvironmentscertificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesCreateOrUpdateSample.js -[connectedenvironmentscertificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesDeleteSample.js -[connectedenvironmentscertificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesGetSample.js -[connectedenvironmentscertificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesListSample.js -[connectedenvironmentscertificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesUpdateSample.js -[connectedenvironmentschecknameavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCheckNameAvailabilitySample.js -[connectedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCreateOrUpdateSample.js -[connectedenvironmentsdaprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.js -[connectedenvironmentsdaprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsDeleteSample.js -[connectedenvironmentsdaprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsGetSample.js -[connectedenvironmentsdaprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSample.js -[connectedenvironmentsdaprcomponentslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSecretsSample.js -[connectedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDeleteSample.js -[connectedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsGetSample.js -[connectedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListByResourceGroupSample.js -[connectedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListBySubscriptionSample.js -[connectedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesCreateOrUpdateSample.js -[connectedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesDeleteSample.js -[connectedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesGetSample.js -[connectedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesListSample.js -[connectedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsUpdateSample.js -[containerappsauthconfigscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js -[containerappsauthconfigsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsDeleteSample.js -[containerappsauthconfigsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsGetSample.js -[containerappsauthconfigslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js -[containerappsbuildsbycontainerapplistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsByContainerAppListSample.js -[containerappsbuildsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsDeleteSample.js -[containerappsbuildsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsGetSample.js -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsCreateOrUpdateSample.js -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDeleteSample.js -[containerappsdiagnosticsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetDetectorSample.js -[containerappsdiagnosticsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRevisionSample.js -[containerappsdiagnosticsgetrootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRootSample.js -[containerappsdiagnosticslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListDetectorsSample.js -[containerappsdiagnosticslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListRevisionsSample.js -[containerappsgetauthtokensample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetAuthTokenSample.js -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetSample.js -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListByResourceGroupSample.js -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListBySubscriptionSample.js -[containerappslistcustomhostnameanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListSecretsSample.js -[containerappspatchesapplysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesApplySample.js -[containerappspatchesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesDeleteSample.js -[containerappspatchesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesGetSample.js -[containerappspatcheslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesListByContainerAppSample.js -[containerappspatchesskipconfiguresample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesSkipConfigureSample.js -[containerappsrevisionreplicasgetreplicasample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js -[containerappsrevisionreplicaslistreplicassample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsActivateRevisionSample.js -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsGetRevisionSample.js -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsListRevisionsSample.js -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsRestartRevisionSample.js -[containerappssessionpoolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsCreateOrUpdateSample.js -[containerappssessionpoolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsDeleteSample.js -[containerappssessionpoolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsGetSample.js -[containerappssessionpoolslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListByResourceGroupSample.js -[containerappssessionpoolslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListBySubscriptionSample.js -[containerappssessionpoolsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsUpdateSample.js -[containerappssourcecontrolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js -[containerappssourcecontrolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsDeleteSample.js -[containerappssourcecontrolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsGetSample.js -[containerappssourcecontrolslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js -[containerappsstartsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStartSample.js -[containerappsstopsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStopSample.js -[containerappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsUpdateSample.js -[daprcomponentresiliencypoliciescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesCreateOrUpdateSample.js -[daprcomponentresiliencypoliciesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesDeleteSample.js -[daprcomponentresiliencypoliciesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesGetSample.js -[daprcomponentresiliencypolicieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesListSample.js -[daprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsCreateOrUpdateSample.js -[daprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsDeleteSample.js -[daprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsGetSample.js -[daprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSample.js -[daprcomponentslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSecretsSample.js -[daprsubscriptionscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsCreateOrUpdateSample.js -[daprsubscriptionsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsDeleteSample.js -[daprsubscriptionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsGetSample.js -[daprsubscriptionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsListSample.js -[dotnetcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsCreateOrUpdateSample.js -[dotnetcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsDeleteSample.js -[dotnetcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsGetSample.js -[dotnetcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsListSample.js -[dotnetcomponentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsUpdateSample.js -[functionsextensioninvokefunctionshostsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/functionsExtensionInvokeFunctionsHostSample.js -[getcustomdomainverificationidsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/getCustomDomainVerificationIdSample.js -[javacomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsCreateOrUpdateSample.js -[javacomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsDeleteSample.js -[javacomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsGetSample.js -[javacomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsListSample.js -[javacomponentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsUpdateSample.js -[jobexecutionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobExecutionSample.js -[jobscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsCreateOrUpdateSample.js -[jobsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsDeleteSample.js -[jobsexecutionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsExecutionsListSample.js -[jobsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetDetectorSample.js -[jobsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetSample.js -[jobslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListByResourceGroupSample.js -[jobslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListBySubscriptionSample.js -[jobslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListDetectorsSample.js -[jobslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListSecretsSample.js -[jobsproxygetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsProxyGetSample.js -[jobsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsResumeSample.js -[jobsstartsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStartSample.js -[jobsstopexecutionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopExecutionSample.js -[jobsstopmultipleexecutionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopMultipleExecutionsSample.js -[jobssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsSuspendSample.js -[jobsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsUpdateSample.js -[logicappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsCreateOrUpdateSample.js -[logicappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeleteSample.js -[logicappsdeployworkflowartifactssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeployWorkflowArtifactsSample.js -[logicappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetSample.js -[logicappsgetworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetWorkflowSample.js -[logicappsinvokesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsInvokeSample.js -[logicappslistworkflowsconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsConnectionsSample.js -[logicappslistworkflowssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsSample.js -[managedcertificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesCreateOrUpdateSample.js -[managedcertificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesDeleteSample.js -[managedcertificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesGetSample.js -[managedcertificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesListSample.js -[managedcertificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesUpdateSample.js -[managedenvironmentdiagnosticsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsGetDetectorSample.js -[managedenvironmentdiagnosticslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsListDetectorsSample.js -[managedenvironmentprivateendpointconnectionscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js -[managedenvironmentprivateendpointconnectionsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsDeleteSample.js -[managedenvironmentprivateendpointconnectionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsGetSample.js -[managedenvironmentprivateendpointconnectionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsListSample.js -[managedenvironmentprivatelinkresourceslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateLinkResourcesListSample.js -[managedenvironmentusageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentUsagesListSample.js -[managedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js -[managedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDeleteSample.js -[managedenvironmentsdiagnosticsgetrootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDiagnosticsGetRootSample.js -[managedenvironmentsgetauthtokensample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetAuthTokenSample.js -[managedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetSample.js -[managedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListByResourceGroupSample.js -[managedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListBySubscriptionSample.js -[managedenvironmentslistworkloadprofilestatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListWorkloadProfileStatesSample.js -[managedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js -[managedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesDeleteSample.js -[managedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesGetSample.js -[managedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesListSample.js -[managedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsUpdateSample.js -[namespaceschecknameavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/namespacesCheckNameAvailabilitySample.js -[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/operationsListSample.js -[usageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/usagesListSample.js -[apiref]: https://learn.microsoft.com/javascript/api/@azure/arm-appcontainers?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers/README.md diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyCreateOrUpdateSample.js deleted file mode 100644 index 1d59495a2400..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyCreateOrUpdateSample.js +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update container app resiliency policy. - * - * @summary Create or update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_CreateOrUpdate.json - */ -async function createOrUpdateAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope = { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 10, - maxEjectionPercent: 50, - }, - httpConnectionPool: { - http1MaxPendingRequests: 1024, - http2MaxRequests: 1024, - }, - httpRetryPolicy: { - errors: ["5xx", "connect-failure", "reset", "retriable-headers", "retriable-status-codes"], - headers: [{ header: "X-Content-Type", prefixMatch: "GOATS" }], - httpStatusCodes: [502, 503], - initialDelayInMilliseconds: 1000, - maxIntervalInMilliseconds: 10000, - maxRetries: 5, - }, - tcpConnectionPool: { maxConnections: 100 }, - tcpRetryPolicy: { maxConnectAttempts: 3 }, - timeoutPolicy: { - connectionTimeoutInSeconds: 5, - responseTimeoutInSeconds: 15, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.createOrUpdate( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyDeleteSample.js deleted file mode 100644 index 23a962e8c420..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete container app resiliency policy. - * - * @summary Delete container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Delete.json - */ -async function deleteAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.delete(resourceGroupName, appName, name); - console.log(result); -} - -async function main() { - deleteAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyGetSample.js deleted file mode 100644 index 2ef4537b51ad..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get container app resiliency policy. - * - * @summary Get container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Get.json - */ -async function getAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.get(resourceGroupName, appName, name); - console.log(result); -} - -async function main() { - getAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyListSample.js deleted file mode 100644 index 30de8511d6a0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List container app resiliency policies. - * - * @summary List container app resiliency policies. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_List.json - */ -async function listAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appResiliencyOperations.list(resourceGroupName, appName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyUpdateSample.js deleted file mode 100644 index 77ad6cfe06f6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/appResiliencyUpdateSample.js +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Update container app resiliency policy. - * - * @summary Update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Patch.json - */ -async function updateAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope = { - timeoutPolicy: { - connectionTimeoutInSeconds: 40, - responseTimeoutInSeconds: 30, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.update( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main() { - updateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/availableWorkloadProfilesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/availableWorkloadProfilesGetSample.js deleted file mode 100644 index ab7750a9cd5d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/availableWorkloadProfilesGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all available workload profiles for a location. - * - * @summary Get all available workload profiles for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AvailableWorkloadProfiles_Get.json - */ -async function billingMetersGet() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.availableWorkloadProfiles.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/billingMetersGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/billingMetersGetSample.js deleted file mode 100644 index 8020362f7b9e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/billingMetersGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all billingMeters for a location. - * - * @summary Get all billingMeters for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/BillingMeters_Get.json - */ -async function billingMetersGet() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.billingMeters.get(location); - console.log(result); -} - -async function main() { - billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildAuthTokenListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildAuthTokenListSample.js deleted file mode 100644 index 9e56fe73c30a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildAuthTokenListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * - * @summary Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListAuthToken.json - */ -async function getBuildAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.buildAuthToken.list(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main() { - getBuildAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersCreateOrUpdateSample.js deleted file mode 100644 index 06dc69b6e980..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersCreateOrUpdateSample.js +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update a BuilderResource - * - * @summary Create or update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_CreateOrUpdate.json - */ -async function buildersCreateOrUpdate0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope = { - containerRegistries: [ - { - containerRegistryServer: "test.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - { - containerRegistryServer: "test2.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - ], - environmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/rg/providers/Microsoft.App/managedEnvironments/testEnv", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/rg1/providers/MicrosoftManagedIdentity/userAssignedIdentities/identity1": - {}, - }, - }, - location: "eastus", - tags: { company: "Microsoft" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main() { - buildersCreateOrUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersDeleteSample.js deleted file mode 100644 index a0072f493947..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a BuilderResource - * - * @summary Delete a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Delete.json - */ -async function buildersDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginDeleteAndWait(resourceGroupName, builderName); - console.log(result); -} - -async function main() { - buildersDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersGetSample.js deleted file mode 100644 index 8f8c261e4d96..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a BuilderResource - * - * @summary Get a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Get.json - */ -async function buildersGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.get(resourceGroupName, builderName); - console.log(result); -} - -async function main() { - buildersGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListByResourceGroupSample.js deleted file mode 100644 index 83b72390f00e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List BuilderResource resources by resource group - * - * @summary List BuilderResource resources by resource group - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListByResourceGroup.json - */ -async function buildersListByResourceGroup0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.builders.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildersListByResourceGroup0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListBySubscriptionSample.js deleted file mode 100644 index a03ce4e84d28..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List BuilderResource resources by subscription ID - * - * @summary List BuilderResource resources by subscription ID - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListBySubscription.json - */ -async function buildersListBySubscription0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.builders.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildersListBySubscription0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersUpdateSample.js deleted file mode 100644 index 9974d91398c5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildersUpdateSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Update a BuilderResource - * - * @summary Update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Update.json - */ -async function buildersUpdate0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope = { - tags: { mytag1: "myvalue1" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main() { - buildersUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsByBuilderResourceListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsByBuilderResourceListSample.js deleted file mode 100644 index cb85dfbb8be7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsByBuilderResourceListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List BuildResource resources by BuilderResource - * - * @summary List BuildResource resources by BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListByBuilderResource.json - */ -async function buildsListByBuilderResource0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.buildsByBuilderResource.list(resourceGroupName, builderName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildsListByBuilderResource0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsCreateOrUpdateSample.js deleted file mode 100644 index 8bf12a3be3fb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsCreateOrUpdateSample.js +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate_NoConfig.json - */ -async function buildsCreateOrUpdateNoConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const buildEnvelope = {}; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate.json - */ -async function buildsCreateOrUpdateWithConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild-123456789az"; - const buildEnvelope = { - configuration: { - baseOs: "DebianBullseye", - environmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - platform: "dotnetcore", - platformVersion: "7.0", - preBuildSteps: [ - { - description: "First pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo", "bar"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'world'"], - }, - { - description: "Second pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'again'"], - }, - ], - }, - destinationContainerRegistry: { - image: "test.azurecr.io/repo:tag", - server: "test.azurecr.io", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -async function main() { - buildsCreateOrUpdateNoConfig(); - buildsCreateOrUpdateWithConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsDeleteSample.js deleted file mode 100644 index 2e20e9e8e6a8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a BuildResource - * - * @summary Delete a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Delete.json - */ -async function buildsDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginDeleteAndWait(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main() { - buildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsGetSample.js deleted file mode 100644 index 162a788b8826..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/buildsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a BuildResource - * - * @summary Get a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Get.json - */ -async function buildsGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.get(resourceGroupName, builderName, buildName); - console.log(result); -} - -async function main() { - buildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesCreateOrUpdateSample.js deleted file mode 100644 index 417ee620468c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesCreateOrUpdateSample.js +++ /dev/null @@ -1,91 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope = { - location: "East US", - properties: { - certificateType: "ImagePullTrustedCA", - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate_FromKeyVault.json - */ -async function createOrUpdateCertificateUsingManagedIdentity() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope = { - location: "East US", - properties: { - certificateKeyVaultProperties: { - identity: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/test-rg/providers/microsoft.managedidentity/userassignedidentities/test-user-mi", - keyVaultUrl: "https://xxxxxxxx.vault.azure.net/certificates/certName", - }, - certificateType: "ServerSSLCertificate", - }, - }; - const options = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); - createOrUpdateCertificateUsingManagedIdentity(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesDeleteSample.js deleted file mode 100644 index 4a21d311ee5f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete( - resourceGroupName, - environmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesGetSample.js deleted file mode 100644 index f293b6161bc4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get(resourceGroupName, environmentName, certificateName); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesListSample.js deleted file mode 100644 index 169d1808e4b4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Certificates in a given managed environment. - * - * @summary Get the Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesUpdateSample.js deleted file mode 100644 index 4cb76861ace0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/certificatesUpdateSample.js +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.update( - resourceGroupName, - environmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesCreateOrUpdateSample.js deleted file mode 100644 index a51d04c9c634..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesCreateOrUpdateSample.js +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope = { - location: "East US", - properties: { - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options = { certificateEnvelope }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesDeleteSample.js deleted file mode 100644 index d54eeb1b77ce..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.delete( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesGetSample.js deleted file mode 100644 index c2b27242a4bd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.get( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesListSample.js deleted file mode 100644 index c16f42f57648..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesListSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Certificates in a given connected environment. - * - * @summary Get the Certificates in a given connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_ListByConnectedEnvironment.json - */ -async function listCertificatesByConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironmentsCertificates.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listCertificatesByConnectedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesUpdateSample.js deleted file mode 100644 index dfb5b73ee5f1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCertificatesUpdateSample.js +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.update( - resourceGroupName, - connectedEnvironmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCheckNameAvailabilitySample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCheckNameAvailabilitySample.js deleted file mode 100644 index 8693469fc51e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCheckNameAvailabilitySample.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Checks if resource connectedEnvironmentName is available. - * - * @summary Checks if resource connectedEnvironmentName is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const checkNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/connectedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.checkNameAvailability( - resourceGroupName, - connectedEnvironmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main() { - certificatesCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCreateOrUpdateSample.js deleted file mode 100644 index 9083463a0986..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsCreateOrUpdateSample.js +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates an connectedEnvironment. - * - * @summary Creates or updates an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_CreateOrUpdate.json - */ -async function createKubeEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const environmentEnvelope = { - customDomainConfiguration: { - certificatePassword: "private key password", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - location: "East US", - staticIp: "1.2.3.4", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - connectedEnvironmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - createKubeEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.js deleted file mode 100644 index 70528e0a2efe..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a connected environment. - * - * @summary Creates or updates a Dapr Component in a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsDeleteSample.js deleted file mode 100644 index f587c3a5f539..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Dapr Component from a connected environment. - * - * @summary Delete a Dapr Component from a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.delete( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsGetSample.js deleted file mode 100644 index e3814b55b7d8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Get.json - */ -async function getDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.get( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - getDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSample.js deleted file mode 100644 index b399a7b5179c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Dapr Components for a connected environment. - * - * @summary Get the Dapr Components for a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironmentsDaprComponents.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSecretsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSecretsSample.js deleted file mode 100644 index b05f5139f8f0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDaprComponentsListSecretsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.listSecrets( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDeleteSample.js deleted file mode 100644 index 013d67ec9236..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete an connectedEnvironment. - * - * @summary Delete an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Delete.json - */ -async function deleteConnectedEnvironmentByConnectedEnvironmentName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginDeleteAndWait( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - deleteConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsGetSample.js deleted file mode 100644 index d25e5f3e066e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of an connectedEnvironment. - * - * @summary Get the properties of an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Get.json - */ -async function getConnectedEnvironmentByConnectedEnvironmentName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.get( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - getConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListByResourceGroupSample.js deleted file mode 100644 index 2a40ba9c1280..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all connectedEnvironments in a resource group. - * - * @summary Get all connectedEnvironments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListBySubscriptionSample.js deleted file mode 100644 index 8b42123d748c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all connectedEnvironments for a subscription. - * - * @summary Get all connectedEnvironments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListBySubscription.json - */ -async function listConnectedEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listConnectedEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesCreateOrUpdateSample.js deleted file mode 100644 index 0157ea1b3e27..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesCreateOrUpdateSample.js +++ /dev/null @@ -1,52 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update storage for a connectedEnvironment. - * - * @summary Create or update storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const storageEnvelope = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateEnvironmentsStorage(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesDeleteSample.js deleted file mode 100644 index 2e2f9c46c0a7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete storage for a connectedEnvironment. - * - * @summary Delete storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.delete( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesGetSample.js deleted file mode 100644 index 3a1f2e042231..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get storage for a connectedEnvironment. - * - * @summary Get storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.get( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main() { - getAEnvironmentsStoragePropertiesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesListSample.js deleted file mode 100644 index 93dd955fd871..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsStoragesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all storages for a connectedEnvironment. - * - * @summary Get all storages for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.list( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsUpdateSample.js deleted file mode 100644 index a9dfe4789f5c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/connectedEnvironmentsUpdateSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a Managed Environment. Only patching of tags is supported currently - * - * @summary Patches a Managed Environment. Only patching of tags is supported currently - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.update( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js deleted file mode 100644 index 228d47eb7552..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update the AuthConfig for a Container App. - * - * @summary Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const authConfigEnvelope = { - encryptionSettings: { - containerAppAuthEncryptionSecretName: "testEncryptionSecretName", - containerAppAuthSigningSecretName: "testSigningSecretName", - }, - globalValidation: { unauthenticatedClientAction: "AllowAnonymous" }, - identityProviders: { - facebook: { - registration: { appId: "123", appSecretSettingName: "facebook-secret" }, - }, - }, - platform: { enabled: true }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.createOrUpdate( - resourceGroupName, - containerAppName, - authConfigName, - authConfigEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsDeleteSample.js deleted file mode 100644 index f3b0807f78fe..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Container App AuthConfig. - * - * @summary Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main() { - deleteContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsGetSample.js deleted file mode 100644 index 2c5908de355f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a AuthConfig of a Container App. - * - * @summary Get a AuthConfig of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main() { - getContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js deleted file mode 100644 index fa46f2cf14f2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Container App AuthConfigs in a given resource group. - * - * @summary Get the Container App AuthConfigs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsAuthConfigs.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAuthConfigsByContainerApps(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsByContainerAppListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsByContainerAppListSample.js deleted file mode 100644 index 5f91b0a4a614..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsByContainerAppListSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List Container Apps Build resources by Container App - * - * @summary List Container Apps Build resources by Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_ListByContainerApp.json - */ -async function containerAppsBuildsListByContainerApp0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsBuildsByContainerApp.list( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - containerAppsBuildsListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsDeleteSample.js deleted file mode 100644 index cc3bfa7cecb2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Container Apps Build resource - * - * @summary Delete a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Delete.json - */ -async function containerAppsBuildsDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.beginDeleteAndWait( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main() { - containerAppsBuildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsGetSample.js deleted file mode 100644 index 77b0b207777b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsBuildsGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a Container Apps Build resource - * - * @summary Get a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Get.json - */ -async function containerAppsBuildsGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.get( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main() { - containerAppsBuildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsCreateOrUpdateSample.js deleted file mode 100644 index e6b607e92a3f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsCreateOrUpdateSample.js +++ /dev/null @@ -1,725 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Kind_CreateOrUpdate.json - */ -async function createOrUpdateAppKind() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppKind"; - const containerAppEnvelope = { - configuration: { - activeRevisionsMode: "Single", - ingress: { allowInsecure: true, external: true, targetPort: 80 }, - }, - kind: "workflowapp", - location: "East Us", - managedBy: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.Web/sites/testcontainerAppKind", - managedEnvironmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/testmanagedenv3", - template: { - containers: [ - { - name: "logicapps-container", - image: "default/logicapps-base:latest", - resources: { cpu: 1, memory: "2.0Gi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 30, - minReplicas: 1, - pollingInterval: 35, - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateAppOnAConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - { - name: "servicebus", - custom: { - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { - messageCount: "5", - namespace: "mynamespace", - queueName: "myqueue", - }, - }, - }, - { - name: "azure-queue", - azureQueue: { - accountName: "account1", - identity: "system", - queueLength: 1, - queueName: "queue1", - }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ManagedBy_CreateOrUpdate.json - */ -async function createOrUpdateManagedByApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppManagedBy"; - const containerAppEnvelope = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [{ revisionName: "testcontainerAppManagedBy-ab1234", weight: 100 }], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - managedBy: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.AppPlatform/Spring/springapp", - template: { - containers: [ - { - name: "testcontainerAppManagedBy", - image: "repo/testcontainerAppManagedBy:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_SourceToCloudApp_CreateOrUpdate.json - */ -async function createOrUpdateSourceToCloudApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - patchingConfiguration: { patchingMode: "Automatic" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "", - imageType: "CloudBuild", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_TcpApp_CreateOrUpdate.json - */ -async function createOrUpdateTcpApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppTcp"; - const containerAppEnvelope = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [{ revisionName: "testcontainerAppTcp-ab1234", weight: 100 }], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppTcp", - image: "repo/testcontainerAppTcp:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateAppKind(); - createOrUpdateAppOnAConnectedEnvironment(); - createOrUpdateContainerApp(); - createOrUpdateManagedByApp(); - createOrUpdateSourceToCloudApp(); - createOrUpdateTcpApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDeleteSample.js deleted file mode 100644 index 279c06634730..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Container App. - * - * @summary Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - deleteContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetDetectorSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetDetectorSample.js deleted file mode 100644 index 89e6720e9d7d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetDetectorSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a diagnostics result of a Container App. - * - * @summary Get a diagnostics result of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_Get.json - */ -async function getContainerAppDiagnosticsInfo() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const detectorName = "cappcontainerappnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getDetector( - resourceGroupName, - containerAppName, - detectorName, - ); - console.log(result); -} - -async function main() { - getContainerAppDiagnosticsInfo(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRevisionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRevisionSample.js deleted file mode 100644 index 49967266f0fb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRevisionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRootSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRootSample.js deleted file mode 100644 index 9947cfe405ae..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsGetRootSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRoot(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListDetectorsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListDetectorsSample.js deleted file mode 100644 index 94b850d65b8f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListDetectorsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the list of diagnostics for a given Container App. - * - * @summary Get the list of diagnostics for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticsForAGivenContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsDiagnostics.listDetectors( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getTheListOfAvailableDiagnosticsForAGivenContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListRevisionsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListRevisionsSample.js deleted file mode 100644 index 2c2effe53c3b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsDiagnosticsListRevisionsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsDiagnostics.listRevisions( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppRevisions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetAuthTokenSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetAuthTokenSample.js deleted file mode 100644 index 2a6972f94bf8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetAuthTokenSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get auth token for a container app - * - * @summary Get auth token for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_GetAuthToken.json - */ -async function getContainerAppAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.getAuthToken(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - getContainerAppAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetSample.js deleted file mode 100644 index d811553cca21..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListByResourceGroupSample.js deleted file mode 100644 index 965699a7ab27..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(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/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListBySubscriptionSample.js deleted file mode 100644 index 79a8489fd8ef..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerApps.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js deleted file mode 100644 index 6ce562ec79c4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Analyzes a custom hostname for a Container App - * - * @summary Analyzes a custom hostname for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const customHostname = "my.name.corp"; - const options = { - customHostname, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listCustomHostNameAnalysis( - resourceGroupName, - containerAppName, - options, - ); - console.log(result); -} - -async function main() { - analyzeCustomHostname(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListSecretsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListSecretsSample.js deleted file mode 100644 index d35623021ef6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsListSecretsSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesApplySample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesApplySample.js deleted file mode 100644 index bda8c6022734..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesApplySample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Apply a Container Apps Patch resource with patch name. - * - * @summary Apply a Container Apps Patch resource with patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Apply.json - */ -async function containerAppsPatchesApply0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginApplyAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesApply0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesDeleteSample.js deleted file mode 100644 index 9b07344bef43..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete specific Container Apps Patch by patch name. - * - * @summary Delete specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Delete.json - */ -async function containerAppsPatchesDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginDeleteAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesGetSample.js deleted file mode 100644 index 9300a33f4895..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get details for specific Container Apps Patch by patch name. - * - * @summary Get details for specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Get.json - */ -async function containerAppsPatchesGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.get( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesListByContainerAppSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesListByContainerAppSample.js deleted file mode 100644 index 218dd9fb25b1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesListByContainerAppSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List Container Apps Patch resources by ContainerApp. - * - * @summary List Container Apps Patch resources by ContainerApp. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_ListByContainerApp.json - */ -async function containerAppsPatchesListByContainerApp0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsPatches.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - containerAppsPatchesListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesSkipConfigureSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesSkipConfigureSample.js deleted file mode 100644 index 22e04c2ed14e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsPatchesSkipConfigureSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Configure the Container Apps Patch skip option by patch name. - * - * @summary Configure the Container Apps Patch skip option by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Skip_Configure.json - */ -async function containerAppsPatchesSkipConfigure0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const patchSkipConfig = { skip: true }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginSkipConfigureAndWait( - resourceGroupName, - containerAppName, - patchName, - patchSkipConfig, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesSkipConfigure0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js deleted file mode 100644 index 956ff9753f82..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a replica for a Container App Revision. - * - * @summary Get a replica for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const replicaName = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - replicaName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevisionReplica(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js deleted file mode 100644 index 80c66398a5ea..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List replicas for a Container App Revision. - * - * @summary List replicas for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.listReplicas( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - listContainerAppReplicas(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsActivateRevisionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsActivateRevisionSample.js deleted file mode 100644 index b99d465b5fbf..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsActivateRevisionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - activateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js deleted file mode 100644 index ec64bf3a7f27..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - deactivateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsGetRevisionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsGetRevisionSample.js deleted file mode 100644 index 6dd4837a06ec..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsGetRevisionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsListRevisionsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsListRevisionsSample.js deleted file mode 100644 index bbc7197fedd9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsListRevisionsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(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/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsRestartRevisionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsRestartRevisionSample.js deleted file mode 100644 index dfee94973bf1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsRevisionsRestartRevisionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testStaticSite0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - restartContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsCreateOrUpdateSample.js deleted file mode 100644 index f4a4059dd573..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsCreateOrUpdateSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update a session pool with the given properties. - * - * @summary Create or update a session pool with the given properties. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_CreateOrUpdate.json - */ -async function createOrUpdateSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope = { - containerType: "CustomContainer", - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - poolManagementType: "Dynamic", - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginCreateOrUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsDeleteSample.js deleted file mode 100644 index ec143d294a12..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete the session pool with the given name. - * - * @summary Delete the session pool with the given name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Delete.json - */ -async function deleteSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginDeleteAndWait( - resourceGroupName, - sessionPoolName, - ); - console.log(result); -} - -async function main() { - deleteSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsGetSample.js deleted file mode 100644 index a83488428a79..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of a session pool. - * - * @summary Get the properties of a session pool. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Get.json - */ -async function getSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.get(resourceGroupName, sessionPoolName); - console.log(result); -} - -async function main() { - getSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListByResourceGroupSample.js deleted file mode 100644 index 6c72edd06069..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the session pools in a given resource group of a subscription. - * - * @summary Get the session pools in a given resource group of a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListByResourceGroup.json - */ -async function listSessionPoolsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSessionPools.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listSessionPoolsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListBySubscriptionSample.js deleted file mode 100644 index 067d103a7cc9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the session pools in a given subscription. - * - * @summary Get the session pools in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListBySubscription.json - */ -async function listSessionPoolsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSessionPools.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listSessionPoolsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsUpdateSample.js deleted file mode 100644 index 7f99c51b059c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSessionPoolsUpdateSample.js +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a session pool using JSON merge patch - * - * @summary Patches a session pool using JSON merge patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Patch.json - */ -async function updateSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope = { - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main() { - updateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js deleted file mode 100644 index 1cd533d35d88..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update the SourceControl for a Container App. - * - * @summary Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const sourceControlEnvelope = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - kind: "feaderated", - tenantId: "", - }, - buildEnvironmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - contextPath: "./", - dockerfilePath: "./Dockerfile", - githubPersonalAccessToken: "test", - image: "image/tag", - registryInfo: { - registryPassword: "", - registryUrl: "test-registry.azurecr.io", - registryUserName: "test-registry", - }, - }, - repoUrl: "https://github.com/xwang971/ghatest", - }; - const options = { - xMsGithubAuxiliary, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - sourceControlEnvelope, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsDeleteSample.js deleted file mode 100644 index 67c06af4b70e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsDeleteSample.js +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Container App SourceControl. - * - * @summary Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const ignoreWorkflowDeletionFailure = false; - const deleteWorkflow = false; - const options = { - xMsGithubAuxiliary, - ignoreWorkflowDeletionFailure, - deleteWorkflow, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - options, - ); - console.log(result); -} - -async function main() { - deleteContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsGetSample.js deleted file mode 100644 index e712a3186d91..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a SourceControl of a Container App. - * - * @summary Get a SourceControl of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - sourceControlName, - ); - console.log(result); -} - -async function main() { - getContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js deleted file mode 100644 index ea5d2c357709..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Container App SourceControls in a given resource group. - * - * @summary Get the Container App SourceControls in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSourceControls.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAppSourceControls(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStartSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStartSample.js deleted file mode 100644 index 46cf08acf15e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStartSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Start a container app - * - * @summary Start a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Start.json - */ -async function startContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStartAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - startContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStopSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStopSample.js deleted file mode 100644 index c28d607bc9b8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsStopSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Stop a container app - * - * @summary Stop a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Stop.json - */ -async function stopContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStopAndWait(resourceGroupName, containerAppName); - console.log(result); -} - -async function main() { - stopContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsUpdateSample.js deleted file mode 100644 index 43be86a0f829..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/containerAppsUpdateSample.js +++ /dev/null @@ -1,157 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a Container App using JSON Merge Patch - * - * @summary Patches a Container App using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [{ level: "debug", logger: "org.springframework.boot" }], - }, - }, - }, - }, - service: { type: "redis" }, - }, - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "service", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/service", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main() { - patchContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesCreateOrUpdateSample.js deleted file mode 100644 index c22c2e73e073..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesCreateOrUpdateSample.js +++ /dev/null @@ -1,158 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_AllOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithAllOptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope = { - inboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 4, - timeoutInSeconds: 10, - }, - httpRetryPolicy: { - maxRetries: 15, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 30 }, - }, - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_OutboundOnly.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope = { - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_SparseOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope = { - inboundPolicy: { - circuitBreakerPolicy: { consecutiveErrors: 3, timeoutInSeconds: 20 }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - }, - outboundPolicy: { timeoutPolicy: { responseTimeoutInSeconds: 12 } }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponentResiliencyPolicyWithAllOptions(); - createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly(); - createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesDeleteSample.js deleted file mode 100644 index 60431b5daf4e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a resiliency policy for a Dapr component. - * - * @summary Delete a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Delete.json - */ -async function deleteDaprComponentResiliencyPolicy() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.delete( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main() { - deleteDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesGetSample.js deleted file mode 100644 index 9ccdc384c5dc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a Dapr component resiliency policy. - * - * @summary Get a Dapr component resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Get.json - */ -async function getDaprComponentResiliencyPolicy() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.get( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main() { - getDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesListSample.js deleted file mode 100644 index a0c2fae80882..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentResiliencyPoliciesListSample.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the resiliency policies for a Dapr component. - * - * @summary Get the resiliency policies for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_List.json - */ -async function listDaprComponentResiliencyPolicies() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprComponentResiliencyPolicies.list( - resourceGroupName, - environmentName, - componentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponentResiliencyPolicies(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsCreateOrUpdateSample.js deleted file mode 100644 index 761aaff910aa..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsCreateOrUpdateSample.js +++ /dev/null @@ -1,110 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_SecretStoreComponent.json - */ -async function createOrUpdateDaprComponentWithSecretStoreComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secretStoreComponent: "my-secret-store", - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_Secrets.json - */ -async function createOrUpdateDaprComponentWithSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponentWithSecretStoreComponent(); - createOrUpdateDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsDeleteSample.js deleted file mode 100644 index 40d99c8708d1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Dapr Component from a Managed Environment. - * - * @summary Delete a Dapr Component from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main() { - deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsGetSample.js deleted file mode 100644 index f8fbb42f0d79..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsGetSample.js +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_SecretStoreComponent.json - */ -async function getDaprComponentWithSecretStoreComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get(resourceGroupName, environmentName, componentName); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_Secrets.json - */ -async function getDaprComponentWithSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get(resourceGroupName, environmentName, componentName); - console.log(result); -} - -async function main() { - getDaprComponentWithSecretStoreComponent(); - getDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSample.js deleted file mode 100644 index fb87c730b9c1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Dapr Components for a managed environment. - * - * @summary Get the Dapr Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSecretsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSecretsSample.js deleted file mode 100644 index dd231ccf2c22..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprComponentsListSecretsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.listSecrets( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsCreateOrUpdateSample.js deleted file mode 100644 index 9e26ea918ebe..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsCreateOrUpdateSample.js +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_BulkSubscribeAndScopes.json - */ -async function createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope = { - bulkSubscribe: { - enabled: true, - maxAwaitDurationMs: 500, - maxMessagesCount: 123, - }, - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - scopes: ["warehouseapp", "customersupportapp"], - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_DefaultRoute.json - */ -async function createOrUpdateDaprSubscriptionWithDefaultRouteOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope = { - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_RouteRulesAndMetadata.json - */ -async function createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope = { - metadata: { foo: "bar", hello: "world" }, - pubsubName: "mypubsubcomponent", - routes: { - default: "/products", - rules: [ - { path: "/widgets", match: "event.type == 'widget'" }, - { path: "/gadgets", match: "event.type == 'gadget'" }, - ], - }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - createOrUpdateDaprSubscriptionWithDefaultRouteOnly(); - createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsDeleteSample.js deleted file mode 100644 index e2e9a93439ba..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Dapr subscription from a Managed Environment. - * - * @summary Delete a Dapr subscription from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Delete.json - */ -async function deleteDaprSubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.delete(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main() { - deleteDaprSubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsGetSample.js deleted file mode 100644 index 2760dd691e37..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsGetSample.js +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_DefaultRoute.json - */ -async function getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_BulkSubscribeAndScopes.json - */ -async function getDaprSubscriptionWithDefaultRouteOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_RouteRulesAndMetadata.json - */ -async function getDaprSubscriptionWithRouteRulesAndMetadata() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main() { - getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - getDaprSubscriptionWithDefaultRouteOnly(); - getDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsListSample.js deleted file mode 100644 index 49476a8decb9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/daprSubscriptionsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Dapr subscriptions for a managed environment. - * - * @summary Get the Dapr subscriptions for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_List.json - */ -async function listDaprSubscriptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprSubscriptions.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprSubscriptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsCreateOrUpdateSample.js deleted file mode 100644 index 119711308946..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsCreateOrUpdateSample.js +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate.json - */ -async function createOrUpdateNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateNetComponent(); - createOrUpdateNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsDeleteSample.js deleted file mode 100644 index 996a8cf89004..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a .NET Component. - * - * @summary Delete a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Delete.json - */ -async function deleteNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - deleteNetComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsGetSample.js deleted file mode 100644 index c5d362b974ba..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsGetSample.js +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get.json - */ -async function getNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get_ServiceBind.json - */ -async function getNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main() { - getNetComponent(); - getNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsListSample.js deleted file mode 100644 index 22bea215b977..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List.json - */ -async function listNetComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.dotNetComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List_ServiceBind.json - */ -async function listNetComponentsWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.dotNetComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listNetComponents(); - listNetComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsUpdateSample.js deleted file mode 100644 index a066799a84e4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/dotNetComponentsUpdateSample.js +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch.json - */ -async function patchNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch_ServiceBind.json - */ -async function patchNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main() { - patchNetComponent(); - patchNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/functionsExtensionInvokeFunctionsHostSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/functionsExtensionInvokeFunctionsHostSample.js deleted file mode 100644 index 62b548f9ad67..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/functionsExtensionInvokeFunctionsHostSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Proxies a Functions host call to the function app backed by the container app. - * - * @summary Proxies a Functions host call to the function app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/FunctionsExtension_Post.json - */ -async function invokeFunctionsHostUsingFunctionsExtensionApi() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const functionAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.functionsExtension.invokeFunctionsHost( - resourceGroupName, - containerAppName, - revisionName, - functionAppName, - ); - console.log(result); -} - -async function main() { - invokeFunctionsHostUsingFunctionsExtensionApi(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/getCustomDomainVerificationIdSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/getCustomDomainVerificationIdSample.js deleted file mode 100644 index 09a71e439d8e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/getCustomDomainVerificationIdSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the verification id of a subscription used for verifying custom domains - * - * @summary Get the verification id of a subscription used for verifying custom domains - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Subscriptions_GetCustomDomainVerificationId.json - */ -async function listAllOperations() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "d27c3573-f76e-4b26-b871-0ccd2203d08c"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.getCustomDomainVerificationId(); - console.log(result); -} - -async function main() { - listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsCreateOrUpdateSample.js deleted file mode 100644 index 58efd8614f0a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsCreateOrUpdateSample.js +++ /dev/null @@ -1,99 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate.json - */ -async function createOrUpdateJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateJavaComponent(); - createOrUpdateJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsDeleteSample.js deleted file mode 100644 index 80e23b716c51..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Java Component. - * - * @summary Delete a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Delete.json - */ -async function deleteJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - deleteJavaComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsGetSample.js deleted file mode 100644 index fd200da46164..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsGetSample.js +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get.json - */ -async function getJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get_ServiceBind.json - */ -async function getJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -async function main() { - getJavaComponent(); - getJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsListSample.js deleted file mode 100644 index 76e8b779eb32..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List.json - */ -async function listJavaComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.javaComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List_ServiceBind.json - */ -async function listJavaComponentsWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.javaComponents.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listJavaComponents(); - listJavaComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsUpdateSample.js deleted file mode 100644 index f0493356d067..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/javaComponentsUpdateSample.js +++ /dev/null @@ -1,99 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch.json - */ -async function patchJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch_ServiceBind.json - */ -async function patchJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main() { - patchJavaComponent(); - patchJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobExecutionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobExecutionSample.js deleted file mode 100644 index 79db411632cf..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobExecutionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get details of a single job execution - * - * @summary Get details of a single job execution - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Execution_Get.json - */ -async function getASingleJobExecution() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobExecution(resourceGroupName, jobName, jobExecutionName); - console.log(result); -} - -async function main() { - getASingleJobExecution(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsCreateOrUpdateSample.js deleted file mode 100644 index 47ef6091272d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsCreateOrUpdateSample.js +++ /dev/null @@ -1,247 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate.json - */ -async function createOrUpdateContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope = { - configuration: { - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateContainerAppsJobOnAConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope = { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_EventTrigger.json - */ -async function createOrUpdateContainerAppsJobWithEventDrivenTrigger() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope = { - configuration: { - eventTriggerConfig: { - parallelism: 4, - replicaCompletionCount: 1, - scale: { - maxExecutions: 5, - minExecutions: 1, - pollingInterval: 40, - rules: [ - { - name: "servicebuscalingrule", - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { topicName: "my-topic" }, - }, - ], - }, - }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Event", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppsJob(); - createOrUpdateContainerAppsJobOnAConnectedEnvironment(); - createOrUpdateContainerAppsJobWithEventDrivenTrigger(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsDeleteSample.js deleted file mode 100644 index 9d36381a57d3..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Container Apps Job. - * - * @summary Delete a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Delete.json - */ -async function deleteContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testWorkerContainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginDeleteAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - deleteContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsExecutionsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsExecutionsListSample.js deleted file mode 100644 index f6aee704724d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsExecutionsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a Container Apps Job's executions - * - * @summary Get a Container Apps Job's executions - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Executions_Get.json - */ -async function getAContainerAppsJobExecutions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobsExecutions.list(resourceGroupName, jobName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getAContainerAppsJobExecutions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetDetectorSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetDetectorSample.js deleted file mode 100644 index 182490896f05..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetDetectorSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the diagnostics data for a Container App Job. - * - * @summary Get the diagnostics data for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_GetDetector.json - */ -async function getDiagnosticDataForAContainerAppJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const detectorName = "containerappjobnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.getDetector(resourceGroupName, jobName, detectorName); - console.log(result); -} - -async function main() { - getDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetSample.js deleted file mode 100644 index a7617f98305e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of a Container Apps Job. - * - * @summary Get the properties of a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Get.json - */ -async function getContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.get(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - getContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListByResourceGroupSample.js deleted file mode 100644 index 47e72baf75dd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given resource group. - * - * @summary Get the Container Apps Jobs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListByResourceGroup.json - */ -async function listContainerAppsJobsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsJobsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListBySubscriptionSample.js deleted file mode 100644 index d714a72cc76d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given subscription. - * - * @summary Get the Container Apps Jobs in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListBySubscription.json - */ -async function listContainerAppsJobsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsJobsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListDetectorsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListDetectorsSample.js deleted file mode 100644 index 083a60853f91..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListDetectorsSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the list of diagnostics for a Container App Job. - * - * @summary Get the list of diagnostics for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListDetectors.json - */ -async function getTheListOfAvailableDiagnosticDataForAContainerAppJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listDetectors(resourceGroupName, jobName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getTheListOfAvailableDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListSecretsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListSecretsSample.js deleted file mode 100644 index 33bd03c3ca52..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsListSecretsSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List secrets for a container apps job - * - * @summary List secrets for a container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListSecrets.json - */ -async function listContainerAppsJobSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.listSecrets(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - listContainerAppsJobSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsProxyGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsProxyGetSample.js deleted file mode 100644 index 1b281572b135..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsProxyGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of a Container App Job. - * - * @summary Get the properties of a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ProxyGet.json - */ -async function getContainerAppJobByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const apiName = "rootApi"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.proxyGet(resourceGroupName, jobName, apiName); - console.log(result); -} - -async function main() { - getContainerAppJobByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsResumeSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsResumeSample.js deleted file mode 100644 index 3a4fe1427475..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsResumeSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Resumes a suspended job - * - * @summary Resumes a suspended job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Resume.json - */ -async function resumeJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginResumeAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - resumeJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStartSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStartSample.js deleted file mode 100644 index 8ddb55215c37..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStartSample.js +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Start a Container Apps Job - * - * @summary Start a Container Apps Job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Start.json - */ -async function runAContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const template = { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }; - const options = { template }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStartAndWait(resourceGroupName, jobName, options); - console.log(result); -} - -async function main() { - runAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopExecutionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopExecutionSample.js deleted file mode 100644 index 1762c043f32b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopExecutionSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Execution.json - */ -async function terminateAContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopExecutionAndWait( - resourceGroupName, - jobName, - jobExecutionName, - ); - console.log(result); -} - -async function main() { - terminateAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopMultipleExecutionsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopMultipleExecutionsSample.js deleted file mode 100644 index fbda3fa7ebee..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsStopMultipleExecutionsSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Multiple.json - */ -async function terminateMultipleContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopMultipleExecutionsAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - terminateMultipleContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsSuspendSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsSuspendSample.js deleted file mode 100644 index 83c9021697de..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsSuspendSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Suspends a job - * - * @summary Suspends a job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Suspend.json - */ -async function suspendJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginSuspendAndWait(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - suspendJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsUpdateSample.js deleted file mode 100644 index 73e4d19e46fa..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/jobsUpdateSample.js +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a Container Apps Job using JSON Merge Patch - * - * @summary Patches a Container Apps Job using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Patch.json - */ -async function patchContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope = { - properties: { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginUpdateAndWait(resourceGroupName, jobName, jobEnvelope); - console.log(result); -} - -async function main() { - patchContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsCreateOrUpdateSample.js deleted file mode 100644 index 26ad5ab43200..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsCreateOrUpdateSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update a Logic App extension resource - * - * @summary Create or update a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Create.json - */ -async function createLogicAppExtension() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const resource = { properties: {} }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.createOrUpdate( - resourceGroupName, - containerAppName, - logicAppName, - resource, - ); - console.log(result); -} - -async function main() { - createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeleteSample.js deleted file mode 100644 index f4f180c47c49..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Deletes a Logic App extension resource - * - * @summary Deletes a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Delete.json - */ -async function createLogicAppExtension() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.delete(resourceGroupName, containerAppName, logicAppName); - console.log(result); -} - -async function main() { - createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeployWorkflowArtifactsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeployWorkflowArtifactsSample.js deleted file mode 100644 index 52c91d47b841..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsDeployWorkflowArtifactsSample.js +++ /dev/null @@ -1,119 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_DeleteDeployWorkflowArtifacts.json - */ -async function deleteWorkflowArtifacts() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts = { - filesToDelete: ["test/workflow.json", "test/"], - }; - const options = { - workflowArtifacts, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_PostDeployWorkflowArtifacts.json - */ -async function deploysWorkflowArtifacts() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts = { - appSettings: { - eventHub_connectionString: - "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=", - }, - files: { - "connections.json": { - managedApiConnections: {}, - serviceProviderConnections: { - eventHub: { - displayName: "example1", - parameterValues: { - connectionString: "@appsetting('eventHub_connectionString')", - }, - serviceProvider: { id: "/serviceProviders/eventHub" }, - }, - }, - }, - "test1/workflow.json": { - 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 ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -async function main() { - deleteWorkflowArtifacts(); - deploysWorkflowArtifacts(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetSample.js deleted file mode 100644 index b1f4fd36056a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Gets a logic app extension resource. - * - * @summary Gets a logic app extension resource. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Get.json - */ -async function getLogicAppExtensionByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.get(resourceGroupName, containerAppName, logicAppName); - console.log(result); -} - -async function main() { - getLogicAppExtensionByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetWorkflowSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetWorkflowSample.js deleted file mode 100644 index b30c31128e2f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsGetWorkflowSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get workflow information by its name - * - * @summary Get workflow information by its name - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_GetWorkflow.json - */ -async function getAWorkflow() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const workflowName = "stateful1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.getWorkflow( - resourceGroupName, - containerAppName, - logicAppName, - workflowName, - ); - console.log(result); -} - -async function main() { - getAWorkflow(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsInvokeSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsInvokeSample.js deleted file mode 100644 index 5234513e8dbb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsInvokeSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Proxies a the API call to the logic app backed by the container app. - * - * @summary Proxies a the API call to the logic app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListCallbackURL.json - */ -async function getWorkflowListCallBackUrl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.invoke( - resourceGroupName, - containerAppName, - logicAppName, - "/runtime/webhooks/workflow/api/management/workflows/Stateful1/triggers/When_a_HTTP_request_is_received/listCallbackUrl", - "POST", - ); - console.log(result); -} - -async function main() { - getWorkflowListCallBackUrl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsConnectionsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsConnectionsSample.js deleted file mode 100644 index af1744662339..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsConnectionsSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Gets logic app's connections. - * - * @summary Gets logic app's connections. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListConnections.json - */ -async function listTheWorkflowsConfigurationConnections() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.listWorkflowsConnections( - resourceGroupName, - containerAppName, - logicAppName, - ); - console.log(result); -} - -async function main() { - listTheWorkflowsConfigurationConnections(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsSample.js deleted file mode 100644 index 2d2e64a2c332..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/logicAppsListWorkflowsSample.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List the workflows for a logic app. - * - * @summary List the workflows for a logic app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListWorkflows.json - */ -async function listTheWorkflows() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.logicApps.listWorkflows( - resourceGroupName, - containerAppName, - logicAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listTheWorkflows(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesCreateOrUpdateSample.js deleted file mode 100644 index a6dd4a718708..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesCreateOrUpdateSample.js +++ /dev/null @@ -1,52 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or Update a Managed Certificate. - * - * @summary Create or Update a Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope = { - location: "East US", - properties: { - domainControlValidation: "CNAME", - subjectName: "my-subject-name.company.country.net", - }, - }; - const options = { - managedCertificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - managedCertificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesDeleteSample.js deleted file mode 100644 index 9411821915dc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Deletes the specified Managed Certificate. - * - * @summary Deletes the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.delete( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesGetSample.js deleted file mode 100644 index ccd1e7697b19..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the specified Managed Certificate. - * - * @summary Get the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.get( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesListSample.js deleted file mode 100644 index a67c82a9e6d7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the Managed Certificates in a given managed environment. - * - * @summary Get the Managed Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_ListByManagedEnvironment.json - */ -async function listManagedCertificatesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedCertificates.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listManagedCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesUpdateSample.js deleted file mode 100644 index a4a52ec83716..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedCertificatesUpdateSample.js +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a managed certificate. Oly patching of tags is supported - * - * @summary Patches a managed certificate. Oly patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_Patch.json - */ -async function patchManagedCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.update( - resourceGroupName, - environmentName, - managedCertificateName, - managedCertificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchManagedCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsGetDetectorSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsGetDetectorSample.js deleted file mode 100644 index 8290586dbb75..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsGetDetectorSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the diagnostics data for a Managed Environment used to host container apps. - * - * @summary Get the diagnostics data for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_Get.json - */ -async function getDiagnosticDataForAManagedEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const detectorName = "ManagedEnvAvailabilityMetrics"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.getDetector( - resourceGroupName, - environmentName, - detectorName, - ); - console.log(result); -} - -async function main() { - getDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsListDetectorsSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsListDetectorsSample.js deleted file mode 100644 index 43de5e58d629..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentDiagnosticsListDetectorsSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the list of diagnostics for a Managed Environment used to host container apps. - * - * @summary Get the list of diagnostics for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticDataForAManagedEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.listDetectors( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getTheListOfAvailableDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js deleted file mode 100644 index 1e5f0a98c8dd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.js +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Update the state of a private endpoint connection for a given managed environment. - * - * @summary Update the state of a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_CreateOrUpdate.json - */ -async function updateAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const privateEndpointConnectionEnvelope = { - privateLinkServiceConnectionState: { - actionsRequired: "None", - status: "Approved", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.managedEnvironmentPrivateEndpointConnections.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - privateEndpointConnectionEnvelope, - ); - console.log(result); -} - -async function main() { - updateAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsDeleteSample.js deleted file mode 100644 index 3ba9d3ebd9d4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a private endpoint connection for a given managed environment. - * - * @summary Delete a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Delete.json - */ -async function deleteAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentPrivateEndpointConnections.beginDeleteAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main() { - deleteAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsGetSample.js deleted file mode 100644 index e921a5bf75b9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsGetSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get a private endpoint connection for a given managed environment. - * - * @summary Get a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Get.json - */ -async function getAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentPrivateEndpointConnections.get( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main() { - getAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsListSample.js deleted file mode 100644 index 8a6f861662a4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateEndpointConnectionsListSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List private endpoint connections for a given managed environment. - * - * @summary List private endpoint connections for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_List.json - */ -async function listPrivateEndpointConnectionsByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentPrivateEndpointConnections.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listPrivateEndpointConnectionsByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateLinkResourcesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateLinkResourcesListSample.js deleted file mode 100644 index d231b154078c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentPrivateLinkResourcesListSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to List private link resources for a given managed environment. - * - * @summary List private link resources for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateLinkResources_List.json - */ -async function listPrivateLinkResourcesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentPrivateLinkResources.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listPrivateLinkResourcesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentUsagesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentUsagesListSample.js deleted file mode 100644 index 296e6b96abcb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentUsagesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Gets the current usage information as well as the limits for environment. - * - * @summary Gets the current usage information as well as the limits for environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentUsages_List.json - */ -async function listManagedEnvironmentUsages() { - const subscriptionId = process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentUsages.list(resourceGroupName, environmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listManagedEnvironmentUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js deleted file mode 100644 index dc968578f270..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js +++ /dev/null @@ -1,179 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CustomInfrastructureResourceGroup_Create.json - */ -async function createEnvironmentWithCustomInfrastructureResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - infrastructureResourceGroup: "myInfrastructureRgName", - location: "East US", - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope = { - appInsightsConfiguration: { - connectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://eastus-8.in.applicationinsights.azure.com/;LiveEndpoint=https://eastus.livediagnostics.monitor.azure.com/", - }, - appLogsConfiguration: { - logAnalyticsConfiguration: { - customerId: "string", - dynamicJsonColumns: true, - sharedKey: "string", - }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - identity: { - type: "SystemAssigned, UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/contosoResources/providers/MicrosoftManagedIdentity/userAssignedIdentities/contosoIdentity": - {}, - }, - }, - location: "East US", - openTelemetryConfiguration: { - destinationsConfiguration: { - dataDogConfiguration: { - key: "000000000000000000000000", - site: "string", - }, - otlpConfigurations: [ - { - name: "dashboard", - endpoint: "dashboard.k8s.region.azurecontainerapps.io:80", - headers: [{ key: "api-key", value: "xxxxxxxxxxx" }], - insecure: true, - }, - ], - }, - logsConfiguration: { destinations: ["appInsights"] }, - metricsConfiguration: { destinations: ["dataDog"], includeKeda: true }, - tracesConfiguration: { destinations: ["appInsights"], includeDapr: true }, - }, - peerAuthentication: { mtls: { enabled: true } }, - peerTrafficConfiguration: { encryption: { enabled: true } }, - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - createEnvironmentWithCustomInfrastructureResourceGroup(); - createEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDeleteSample.js deleted file mode 100644 index 4f6b3f6ca7f9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDeleteSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete a Managed Environment if it does not have any container apps. - * - * @summary Delete a Managed Environment if it does not have any container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - deleteEnvironmentByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDiagnosticsGetRootSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDiagnosticsGetRootSample.js deleted file mode 100644 index 96bb412637f2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsDiagnosticsGetRootSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsDiagnostics.getRoot( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetAuthTokenSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetAuthTokenSample.js deleted file mode 100644 index c84f7f2e9a44..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetAuthTokenSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_GetAuthToken.json - */ -async function getManagedEnvironmentAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const environmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.getAuthToken(resourceGroupName, environmentName); - console.log(result); -} - -async function main() { - getManagedEnvironmentAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetSample.js deleted file mode 100644 index c73dd0b14661..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get(resourceGroupName, environmentName); - console.log(result); -} - -async function main() { - getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListByResourceGroupSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListByResourceGroupSample.js deleted file mode 100644 index 178045a04c70..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListByResourceGroupSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all the Managed Environments in a resource group. - * - * @summary Get all the Managed Environments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListBySubscriptionSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListBySubscriptionSample.js deleted file mode 100644 index d520704f0591..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListBySubscriptionSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all Managed Environments for a subscription. - * - * @summary Get all Managed Environments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListWorkloadProfileStatesSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListWorkloadProfileStatesSample.js deleted file mode 100644 index 35d431014415..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsListWorkloadProfileStatesSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all workload Profile States for a Managed Environment. - * - * @summary Get all workload Profile States for a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListWorkloadProfileStates.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listWorkloadProfileStates( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js deleted file mode 100644 index 8e3d064daa2f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js +++ /dev/null @@ -1,85 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate_NfsAzureFile.json - */ -async function createOrUpdateEnvironmentsStorageForNfsAzureFile() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope = { - properties: { - nfsAzureFile: { - accessMode: "ReadOnly", - server: "server1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateEnvironmentsStorage(); - createOrUpdateEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesDeleteSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesDeleteSample.js deleted file mode 100644 index cc185d2cff56..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesDeleteSample.js +++ /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. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Delete storage for a managedEnvironment. - * - * @summary Delete storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesGetSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesGetSample.js deleted file mode 100644 index 41c5da9f4eb1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesGetSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get_NfsAzureFile.json - */ -async function getAEnvironmentsStorageForNfsAzureFile() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main() { - getAEnvironmentsStorage(); - getAEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesListSample.js deleted file mode 100644 index ec7422287ce5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsStoragesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Get all storages for a managedEnvironment. - * - * @summary Get all storages for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list(resourceGroupName, environmentName); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsUpdateSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsUpdateSample.js deleted file mode 100644 index 6369f15f1a0d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/managedEnvironmentsUpdateSample.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Patches a Managed Environment using JSON Merge Patch - * - * @summary Patches a Managed Environment using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope = { - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/namespacesCheckNameAvailabilitySample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/namespacesCheckNameAvailabilitySample.js deleted file mode 100644 index 0b9044e90e98..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/namespacesCheckNameAvailabilitySample.js +++ /dev/null @@ -1,70 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/managedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CheckNameAvailability.json - */ -async function containerAppsCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest = { - name: "testcappname", - type: "Microsoft.App/containerApps", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main() { - certificatesCheckNameAvailability(); - containerAppsCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/operationsListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/operationsListSample.js deleted file mode 100644 index 9ae5be71521d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/operationsListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Lists all of the available RP operations. - * - * @summary Lists all of the available RP operations. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Operations_List.json - */ -async function listAllOperations() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.operations.list()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/package.json b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/package.json deleted file mode 100644 index 1855abeb3632..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/package.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "name": "@azure-samples/arm-appcontainers-js-beta", - "private": true, - "version": "1.0.0", - "description": " client library samples for JavaScript (Beta)", - "engines": { - "node": ">=18.0.0" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/Azure/azure-sdk-for-js.git", - "directory": "sdk/appcontainers/arm-appcontainers" - }, - "keywords": [ - "node", - "azure", - "typescript", - "browser", - "isomorphic" - ], - "author": "Microsoft Corporation", - "license": "MIT", - "bugs": { - "url": "https://github.com/Azure/azure-sdk-for-js/issues" - }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers", - "dependencies": { - "@azure/arm-appcontainers": "next", - "dotenv": "latest", - "@azure/identity": "^4.2.1" - } -} diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/sample.env b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/sample.env deleted file mode 100644 index 672847a3fea0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/sample.env +++ /dev/null @@ -1,4 +0,0 @@ -# App registration secret for AAD authentication -AZURE_CLIENT_SECRET= -AZURE_CLIENT_ID= -AZURE_TENANT_ID= \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/usagesListSample.js b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/usagesListSample.js deleted file mode 100644 index 8b1ff7ff2ddb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/javascript/usagesListSample.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 { ContainerAppsAPIClient } = require("@azure/arm-appcontainers"); -const { DefaultAzureCredential } = require("@azure/identity"); -require("dotenv").config(); - -/** - * This sample demonstrates how to Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * - * @summary Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Usages_List.json - */ -async function listUsages() { - const subscriptionId = process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const location = "westus"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.usages.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/README.md b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/README.md deleted file mode 100644 index a0719c892472..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/README.md +++ /dev/null @@ -1,397 +0,0 @@ -# client library samples for TypeScript (Beta) - -These sample programs show how to use the TypeScript client libraries for in some common scenarios. - -| **File Name** | **Description** | -| --------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| [appResiliencyCreateOrUpdateSample.ts][appresiliencycreateorupdatesample] | Create or update container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_CreateOrUpdate.json | -| [appResiliencyDeleteSample.ts][appresiliencydeletesample] | Delete container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Delete.json | -| [appResiliencyGetSample.ts][appresiliencygetsample] | Get container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Get.json | -| [appResiliencyListSample.ts][appresiliencylistsample] | List container app resiliency policies. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_List.json | -| [appResiliencyUpdateSample.ts][appresiliencyupdatesample] | Update container app resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Patch.json | -| [availableWorkloadProfilesGetSample.ts][availableworkloadprofilesgetsample] | Get all available workload profiles for a location. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AvailableWorkloadProfiles_Get.json | -| [billingMetersGetSample.ts][billingmetersgetsample] | Get all billingMeters for a location. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/BillingMeters_Get.json | -| [buildAuthTokenListSample.ts][buildauthtokenlistsample] | Gets the token used to connect to the endpoint where source code can be uploaded for a build. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListAuthToken.json | -| [buildersCreateOrUpdateSample.ts][builderscreateorupdatesample] | Create or update a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_CreateOrUpdate.json | -| [buildersDeleteSample.ts][buildersdeletesample] | Delete a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Delete.json | -| [buildersGetSample.ts][buildersgetsample] | Get a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Get.json | -| [buildersListByResourceGroupSample.ts][builderslistbyresourcegroupsample] | List BuilderResource resources by resource group x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListByResourceGroup.json | -| [buildersListBySubscriptionSample.ts][builderslistbysubscriptionsample] | List BuilderResource resources by subscription ID x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListBySubscription.json | -| [buildersUpdateSample.ts][buildersupdatesample] | Update a BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Update.json | -| [buildsByBuilderResourceListSample.ts][buildsbybuilderresourcelistsample] | List BuildResource resources by BuilderResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListByBuilderResource.json | -| [buildsCreateOrUpdateSample.ts][buildscreateorupdatesample] | Create a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate_NoConfig.json | -| [buildsDeleteSample.ts][buildsdeletesample] | Delete a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Delete.json | -| [buildsGetSample.ts][buildsgetsample] | Get a BuildResource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Get.json | -| [certificatesCreateOrUpdateSample.ts][certificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate.json | -| [certificatesDeleteSample.ts][certificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Delete.json | -| [certificatesGetSample.ts][certificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Get.json | -| [certificatesListSample.ts][certificateslistsample] | Get the Certificates in a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_ListByManagedEnvironment.json | -| [certificatesUpdateSample.ts][certificatesupdatesample] | Patches a certificate. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_Patch.json | -| [connectedEnvironmentsCertificatesCreateOrUpdateSample.ts][connectedenvironmentscertificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_CreateOrUpdate.json | -| [connectedEnvironmentsCertificatesDeleteSample.ts][connectedenvironmentscertificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Delete.json | -| [connectedEnvironmentsCertificatesGetSample.ts][connectedenvironmentscertificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Get.json | -| [connectedEnvironmentsCertificatesListSample.ts][connectedenvironmentscertificateslistsample] | Get the Certificates in a given connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_ListByConnectedEnvironment.json | -| [connectedEnvironmentsCertificatesUpdateSample.ts][connectedenvironmentscertificatesupdatesample] | Patches a certificate. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_Patch.json | -| [connectedEnvironmentsCheckNameAvailabilitySample.ts][connectedenvironmentschecknameavailabilitysample] | Checks if resource connectedEnvironmentName is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_CheckNameAvailability.json | -| [connectedEnvironmentsCreateOrUpdateSample.ts][connectedenvironmentscreateorupdatesample] | Creates or updates an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_CreateOrUpdate.json | -| [connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts][connectedenvironmentsdaprcomponentscreateorupdatesample] | Creates or updates a Dapr Component in a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_CreateOrUpdate.json | -| [connectedEnvironmentsDaprComponentsDeleteSample.ts][connectedenvironmentsdaprcomponentsdeletesample] | Delete a Dapr Component from a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Delete.json | -| [connectedEnvironmentsDaprComponentsGetSample.ts][connectedenvironmentsdaprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Get.json | -| [connectedEnvironmentsDaprComponentsListSample.ts][connectedenvironmentsdaprcomponentslistsample] | Get the Dapr Components for a connected environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_List.json | -| [connectedEnvironmentsDaprComponentsListSecretsSample.ts][connectedenvironmentsdaprcomponentslistsecretssample] | List secrets for a dapr component x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_ListSecrets.json | -| [connectedEnvironmentsDeleteSample.ts][connectedenvironmentsdeletesample] | Delete an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Delete.json | -| [connectedEnvironmentsGetSample.ts][connectedenvironmentsgetsample] | Get the properties of an connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Get.json | -| [connectedEnvironmentsListByResourceGroupSample.ts][connectedenvironmentslistbyresourcegroupsample] | Get all connectedEnvironments in a resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListByResourceGroup.json | -| [connectedEnvironmentsListBySubscriptionSample.ts][connectedenvironmentslistbysubscriptionsample] | Get all connectedEnvironments for a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListBySubscription.json | -| [connectedEnvironmentsStoragesCreateOrUpdateSample.ts][connectedenvironmentsstoragescreateorupdatesample] | Create or update storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_CreateOrUpdate.json | -| [connectedEnvironmentsStoragesDeleteSample.ts][connectedenvironmentsstoragesdeletesample] | Delete storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Delete.json | -| [connectedEnvironmentsStoragesGetSample.ts][connectedenvironmentsstoragesgetsample] | Get storage for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Get.json | -| [connectedEnvironmentsStoragesListSample.ts][connectedenvironmentsstorageslistsample] | Get all storages for a connectedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_List.json | -| [connectedEnvironmentsUpdateSample.ts][connectedenvironmentsupdatesample] | Patches a Managed Environment. Only patching of tags is supported currently x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Patch.json | -| [containerAppsAuthConfigsCreateOrUpdateSample.ts][containerappsauthconfigscreateorupdatesample] | Create or update the AuthConfig for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_CreateOrUpdate.json | -| [containerAppsAuthConfigsDeleteSample.ts][containerappsauthconfigsdeletesample] | Delete a Container App AuthConfig. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Delete.json | -| [containerAppsAuthConfigsGetSample.ts][containerappsauthconfigsgetsample] | Get a AuthConfig of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Get.json | -| [containerAppsAuthConfigsListByContainerAppSample.ts][containerappsauthconfigslistbycontainerappsample] | Get the Container App AuthConfigs in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_ListByContainer.json | -| [containerAppsBuildsByContainerAppListSample.ts][containerappsbuildsbycontainerapplistsample] | List Container Apps Build resources by Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_ListByContainerApp.json | -| [containerAppsBuildsDeleteSample.ts][containerappsbuildsdeletesample] | Delete a Container Apps Build resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Delete.json | -| [containerAppsBuildsGetSample.ts][containerappsbuildsgetsample] | Get a Container Apps Build resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Get.json | -| [containerAppsCreateOrUpdateSample.ts][containerappscreateorupdatesample] | Create or update a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Kind_CreateOrUpdate.json | -| [containerAppsDeleteSample.ts][containerappsdeletesample] | Delete a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Delete.json | -| [containerAppsDiagnosticsGetDetectorSample.ts][containerappsdiagnosticsgetdetectorsample] | Get a diagnostics result of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_Get.json | -| [containerAppsDiagnosticsGetRevisionSample.ts][containerappsdiagnosticsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json | -| [containerAppsDiagnosticsGetRootSample.ts][containerappsdiagnosticsgetrootsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json | -| [containerAppsDiagnosticsListDetectorsSample.ts][containerappsdiagnosticslistdetectorssample] | Get the list of diagnostics for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_List.json | -| [containerAppsDiagnosticsListRevisionsSample.ts][containerappsdiagnosticslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json | -| [containerAppsGetAuthTokenSample.ts][containerappsgetauthtokensample] | Get auth token for a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_GetAuthToken.json | -| [containerAppsGetSample.ts][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json | -| [containerAppsListByResourceGroupSample.ts][containerappslistbyresourcegroupsample] | Get the Container Apps in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListByResourceGroup.json | -| [containerAppsListBySubscriptionSample.ts][containerappslistbysubscriptionsample] | Get the Container Apps in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListBySubscription.json | -| [containerAppsListCustomHostNameAnalysisSample.ts][containerappslistcustomhostnameanalysissample] | Analyzes a custom hostname for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json | -| [containerAppsListSecretsSample.ts][containerappslistsecretssample] | List secrets for a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListSecrets.json | -| [containerAppsPatchesApplySample.ts][containerappspatchesapplysample] | Apply a Container Apps Patch resource with patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Apply.json | -| [containerAppsPatchesDeleteSample.ts][containerappspatchesdeletesample] | Delete specific Container Apps Patch by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Delete.json | -| [containerAppsPatchesGetSample.ts][containerappspatchesgetsample] | Get details for specific Container Apps Patch by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Get.json | -| [containerAppsPatchesListByContainerAppSample.ts][containerappspatcheslistbycontainerappsample] | List Container Apps Patch resources by ContainerApp. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_ListByContainerApp.json | -| [containerAppsPatchesSkipConfigureSample.ts][containerappspatchesskipconfiguresample] | Configure the Container Apps Patch skip option by patch name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Skip_Configure.json | -| [containerAppsRevisionReplicasGetReplicaSample.ts][containerappsrevisionreplicasgetreplicasample] | Get a replica for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_Get.json | -| [containerAppsRevisionReplicasListReplicasSample.ts][containerappsrevisionreplicaslistreplicassample] | List replicas for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_List.json | -| [containerAppsRevisionsActivateRevisionSample.ts][containerappsrevisionsactivaterevisionsample] | Activates a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Activate.json | -| [containerAppsRevisionsDeactivateRevisionSample.ts][containerappsrevisionsdeactivaterevisionsample] | Deactivates a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Deactivate.json | -| [containerAppsRevisionsGetRevisionSample.ts][containerappsrevisionsgetrevisionsample] | Get a revision of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json | -| [containerAppsRevisionsListRevisionsSample.ts][containerappsrevisionslistrevisionssample] | Get the Revisions for a given Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json | -| [containerAppsRevisionsRestartRevisionSample.ts][containerappsrevisionsrestartrevisionsample] | Restarts a revision for a Container App x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Restart.json | -| [containerAppsSessionPoolsCreateOrUpdateSample.ts][containerappssessionpoolscreateorupdatesample] | Create or update a session pool with the given properties. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_CreateOrUpdate.json | -| [containerAppsSessionPoolsDeleteSample.ts][containerappssessionpoolsdeletesample] | Delete the session pool with the given name. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Delete.json | -| [containerAppsSessionPoolsGetSample.ts][containerappssessionpoolsgetsample] | Get the properties of a session pool. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Get.json | -| [containerAppsSessionPoolsListByResourceGroupSample.ts][containerappssessionpoolslistbyresourcegroupsample] | Get the session pools in a given resource group of a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListByResourceGroup.json | -| [containerAppsSessionPoolsListBySubscriptionSample.ts][containerappssessionpoolslistbysubscriptionsample] | Get the session pools in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListBySubscription.json | -| [containerAppsSessionPoolsUpdateSample.ts][containerappssessionpoolsupdatesample] | Patches a session pool using JSON merge patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Patch.json | -| [containerAppsSourceControlsCreateOrUpdateSample.ts][containerappssourcecontrolscreateorupdatesample] | Create or update the SourceControl for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_CreateOrUpdate.json | -| [containerAppsSourceControlsDeleteSample.ts][containerappssourcecontrolsdeletesample] | Delete a Container App SourceControl. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Delete.json | -| [containerAppsSourceControlsGetSample.ts][containerappssourcecontrolsgetsample] | Get a SourceControl of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Get.json | -| [containerAppsSourceControlsListByContainerAppSample.ts][containerappssourcecontrolslistbycontainerappsample] | Get the Container App SourceControls in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_ListByContainer.json | -| [containerAppsStartSample.ts][containerappsstartsample] | Start a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Start.json | -| [containerAppsStopSample.ts][containerappsstopsample] | Stop a container app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Stop.json | -| [containerAppsUpdateSample.ts][containerappsupdatesample] | Patches a Container App using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Patch.json | -| [daprComponentResiliencyPoliciesCreateOrUpdateSample.ts][daprcomponentresiliencypoliciescreateorupdatesample] | Creates or updates a resiliency policy for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_AllOptions.json | -| [daprComponentResiliencyPoliciesDeleteSample.ts][daprcomponentresiliencypoliciesdeletesample] | Delete a resiliency policy for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Delete.json | -| [daprComponentResiliencyPoliciesGetSample.ts][daprcomponentresiliencypoliciesgetsample] | Get a Dapr component resiliency policy. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Get.json | -| [daprComponentResiliencyPoliciesListSample.ts][daprcomponentresiliencypolicieslistsample] | Get the resiliency policies for a Dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_List.json | -| [daprComponentsCreateOrUpdateSample.ts][daprcomponentscreateorupdatesample] | Creates or updates a Dapr Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_SecretStoreComponent.json | -| [daprComponentsDeleteSample.ts][daprcomponentsdeletesample] | Delete a Dapr Component from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Delete.json | -| [daprComponentsGetSample.ts][daprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_SecretStoreComponent.json | -| [daprComponentsListSample.ts][daprcomponentslistsample] | Get the Dapr Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_List.json | -| [daprComponentsListSecretsSample.ts][daprcomponentslistsecretssample] | List secrets for a dapr component x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_ListSecrets.json | -| [daprSubscriptionsCreateOrUpdateSample.ts][daprsubscriptionscreateorupdatesample] | Creates or updates a Dapr subscription in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_BulkSubscribeAndScopes.json | -| [daprSubscriptionsDeleteSample.ts][daprsubscriptionsdeletesample] | Delete a Dapr subscription from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Delete.json | -| [daprSubscriptionsGetSample.ts][daprsubscriptionsgetsample] | Get a dapr subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_DefaultRoute.json | -| [daprSubscriptionsListSample.ts][daprsubscriptionslistsample] | Get the Dapr subscriptions for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_List.json | -| [dotNetComponentsCreateOrUpdateSample.ts][dotnetcomponentscreateorupdatesample] | Creates or updates a .NET Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate.json | -| [dotNetComponentsDeleteSample.ts][dotnetcomponentsdeletesample] | Delete a .NET Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Delete.json | -| [dotNetComponentsGetSample.ts][dotnetcomponentsgetsample] | Get a .NET Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get.json | -| [dotNetComponentsListSample.ts][dotnetcomponentslistsample] | Get the .NET Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List.json | -| [dotNetComponentsUpdateSample.ts][dotnetcomponentsupdatesample] | Patches a .NET Component using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch.json | -| [functionsExtensionInvokeFunctionsHostSample.ts][functionsextensioninvokefunctionshostsample] | Proxies a Functions host call to the function app backed by the container app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/FunctionsExtension_Post.json | -| [getCustomDomainVerificationIdSample.ts][getcustomdomainverificationidsample] | Get the verification id of a subscription used for verifying custom domains x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Subscriptions_GetCustomDomainVerificationId.json | -| [javaComponentsCreateOrUpdateSample.ts][javacomponentscreateorupdatesample] | Creates or updates a Java Component in a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate.json | -| [javaComponentsDeleteSample.ts][javacomponentsdeletesample] | Delete a Java Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Delete.json | -| [javaComponentsGetSample.ts][javacomponentsgetsample] | Get a Java Component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get.json | -| [javaComponentsListSample.ts][javacomponentslistsample] | Get the Java Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List.json | -| [javaComponentsUpdateSample.ts][javacomponentsupdatesample] | Patches a Java Component using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch.json | -| [jobExecutionSample.ts][jobexecutionsample] | Get details of a single job execution x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Execution_Get.json | -| [jobsCreateOrUpdateSample.ts][jobscreateorupdatesample] | Create or Update a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate.json | -| [jobsDeleteSample.ts][jobsdeletesample] | Delete a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Delete.json | -| [jobsExecutionsListSample.ts][jobsexecutionslistsample] | Get a Container Apps Job's executions x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Executions_Get.json | -| [jobsGetDetectorSample.ts][jobsgetdetectorsample] | Get the diagnostics data for a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_GetDetector.json | -| [jobsGetSample.ts][jobsgetsample] | Get the properties of a Container Apps Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Get.json | -| [jobsListByResourceGroupSample.ts][jobslistbyresourcegroupsample] | Get the Container Apps Jobs in a given resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListByResourceGroup.json | -| [jobsListBySubscriptionSample.ts][jobslistbysubscriptionsample] | Get the Container Apps Jobs in a given subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListBySubscription.json | -| [jobsListDetectorsSample.ts][jobslistdetectorssample] | Get the list of diagnostics for a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListDetectors.json | -| [jobsListSecretsSample.ts][jobslistsecretssample] | List secrets for a container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListSecrets.json | -| [jobsProxyGetSample.ts][jobsproxygetsample] | Get the properties of a Container App Job. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ProxyGet.json | -| [jobsResumeSample.ts][jobsresumesample] | Resumes a suspended job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Resume.json | -| [jobsStartSample.ts][jobsstartsample] | Start a Container Apps Job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Start.json | -| [jobsStopExecutionSample.ts][jobsstopexecutionsample] | Terminates execution of a running container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Execution.json | -| [jobsStopMultipleExecutionsSample.ts][jobsstopmultipleexecutionssample] | Terminates execution of a running container apps job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Multiple.json | -| [jobsSuspendSample.ts][jobssuspendsample] | Suspends a job x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Suspend.json | -| [jobsUpdateSample.ts][jobsupdatesample] | Patches a Container Apps Job using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Patch.json | -| [logicAppsCreateOrUpdateSample.ts][logicappscreateorupdatesample] | Create or update a Logic App extension resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Create.json | -| [logicAppsDeleteSample.ts][logicappsdeletesample] | Deletes a Logic App extension resource x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Delete.json | -| [logicAppsDeployWorkflowArtifactsSample.ts][logicappsdeployworkflowartifactssample] | Creates or updates the artifacts for the logic app x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_DeleteDeployWorkflowArtifacts.json | -| [logicAppsGetSample.ts][logicappsgetsample] | Gets a logic app extension resource. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Get.json | -| [logicAppsGetWorkflowSample.ts][logicappsgetworkflowsample] | Get workflow information by its name x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_GetWorkflow.json | -| [logicAppsInvokeSample.ts][logicappsinvokesample] | Proxies a the API call to the logic app backed by the container app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListCallbackURL.json | -| [logicAppsListWorkflowsConnectionsSample.ts][logicappslistworkflowsconnectionssample] | Gets logic app's connections. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListConnections.json | -| [logicAppsListWorkflowsSample.ts][logicappslistworkflowssample] | List the workflows for a logic app. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListWorkflows.json | -| [managedCertificatesCreateOrUpdateSample.ts][managedcertificatescreateorupdatesample] | Create or Update a Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_CreateOrUpdate.json | -| [managedCertificatesDeleteSample.ts][managedcertificatesdeletesample] | Deletes the specified Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Delete.json | -| [managedCertificatesGetSample.ts][managedcertificatesgetsample] | Get the specified Managed Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Get.json | -| [managedCertificatesListSample.ts][managedcertificateslistsample] | Get the Managed Certificates in a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_ListByManagedEnvironment.json | -| [managedCertificatesUpdateSample.ts][managedcertificatesupdatesample] | Patches a managed certificate. Oly patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_Patch.json | -| [managedEnvironmentDiagnosticsGetDetectorSample.ts][managedenvironmentdiagnosticsgetdetectorsample] | Get the diagnostics data for a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_Get.json | -| [managedEnvironmentDiagnosticsListDetectorsSample.ts][managedenvironmentdiagnosticslistdetectorssample] | Get the list of diagnostics for a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_List.json | -| [managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts][managedenvironmentprivateendpointconnectionscreateorupdatesample] | Update the state of a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_CreateOrUpdate.json | -| [managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts][managedenvironmentprivateendpointconnectionsdeletesample] | Delete a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Delete.json | -| [managedEnvironmentPrivateEndpointConnectionsGetSample.ts][managedenvironmentprivateendpointconnectionsgetsample] | Get a private endpoint connection for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Get.json | -| [managedEnvironmentPrivateEndpointConnectionsListSample.ts][managedenvironmentprivateendpointconnectionslistsample] | List private endpoint connections for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_List.json | -| [managedEnvironmentPrivateLinkResourcesListSample.ts][managedenvironmentprivatelinkresourceslistsample] | List private link resources for a given managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateLinkResources_List.json | -| [managedEnvironmentUsagesListSample.ts][managedenvironmentusageslistsample] | Gets the current usage information as well as the limits for environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentUsages_List.json | -| [managedEnvironmentsCreateOrUpdateSample.ts][managedenvironmentscreateorupdatesample] | Creates or updates a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CustomInfrastructureResourceGroup_Create.json | -| [managedEnvironmentsDeleteSample.ts][managedenvironmentsdeletesample] | Delete a Managed Environment if it does not have any container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Delete.json | -| [managedEnvironmentsDiagnosticsGetRootSample.ts][managedenvironmentsdiagnosticsgetrootsample] | Get the properties of a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json | -| [managedEnvironmentsGetAuthTokenSample.ts][managedenvironmentsgetauthtokensample] | Checks if resource name is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_GetAuthToken.json | -| [managedEnvironmentsGetSample.ts][managedenvironmentsgetsample] | Get the properties of a Managed Environment used to host container apps. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json | -| [managedEnvironmentsListByResourceGroupSample.ts][managedenvironmentslistbyresourcegroupsample] | Get all the Managed Environments in a resource group. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListByResourceGroup.json | -| [managedEnvironmentsListBySubscriptionSample.ts][managedenvironmentslistbysubscriptionsample] | Get all Managed Environments for a subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListBySubscription.json | -| [managedEnvironmentsListWorkloadProfileStatesSample.ts][managedenvironmentslistworkloadprofilestatessample] | Get all workload Profile States for a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListWorkloadProfileStates.json | -| [managedEnvironmentsStoragesCreateOrUpdateSample.ts][managedenvironmentsstoragescreateorupdatesample] | Create or update storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json | -| [managedEnvironmentsStoragesDeleteSample.ts][managedenvironmentsstoragesdeletesample] | Delete storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Delete.json | -| [managedEnvironmentsStoragesGetSample.ts][managedenvironmentsstoragesgetsample] | Get storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get.json | -| [managedEnvironmentsStoragesListSample.ts][managedenvironmentsstorageslistsample] | Get all storages for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_List.json | -| [managedEnvironmentsUpdateSample.ts][managedenvironmentsupdatesample] | Patches a Managed Environment using JSON Merge Patch x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Patch.json | -| [namespacesCheckNameAvailabilitySample.ts][namespaceschecknameavailabilitysample] | Checks if resource name is available. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_CheckNameAvailability.json | -| [operationsListSample.ts][operationslistsample] | Lists all of the available RP operations. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Operations_List.json | -| [usagesListSample.ts][usageslistsample] | Gets, for the specified location, the current resource usage information as well as the limits under the subscription. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Usages_List.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/appResiliencyCreateOrUpdateSample.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 dev-tool run vendored cross-env APPCONTAINERS_SUBSCRIPTION_ID="" APPCONTAINERS_RESOURCE_GROUP="" node dist/appResiliencyCreateOrUpdateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[appresiliencycreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyCreateOrUpdateSample.ts -[appresiliencydeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyDeleteSample.ts -[appresiliencygetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyGetSample.ts -[appresiliencylistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyListSample.ts -[appresiliencyupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyUpdateSample.ts -[availableworkloadprofilesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/availableWorkloadProfilesGetSample.ts -[billingmetersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/billingMetersGetSample.ts -[buildauthtokenlistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildAuthTokenListSample.ts -[builderscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersCreateOrUpdateSample.ts -[buildersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersDeleteSample.ts -[buildersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersGetSample.ts -[builderslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListByResourceGroupSample.ts -[builderslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListBySubscriptionSample.ts -[buildersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersUpdateSample.ts -[buildsbybuilderresourcelistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsByBuilderResourceListSample.ts -[buildscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsCreateOrUpdateSample.ts -[buildsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsDeleteSample.ts -[buildsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsGetSample.ts -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesCreateOrUpdateSample.ts -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesDeleteSample.ts -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesGetSample.ts -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesListSample.ts -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesUpdateSample.ts -[connectedenvironmentscertificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts -[connectedenvironmentscertificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesDeleteSample.ts -[connectedenvironmentscertificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesGetSample.ts -[connectedenvironmentscertificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesListSample.ts -[connectedenvironmentscertificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesUpdateSample.ts -[connectedenvironmentschecknameavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCheckNameAvailabilitySample.ts -[connectedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCreateOrUpdateSample.ts -[connectedenvironmentsdaprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts -[connectedenvironmentsdaprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsDeleteSample.ts -[connectedenvironmentsdaprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsGetSample.ts -[connectedenvironmentsdaprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSample.ts -[connectedenvironmentsdaprcomponentslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSecretsSample.ts -[connectedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDeleteSample.ts -[connectedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsGetSample.ts -[connectedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListByResourceGroupSample.ts -[connectedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListBySubscriptionSample.ts -[connectedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesCreateOrUpdateSample.ts -[connectedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesDeleteSample.ts -[connectedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesGetSample.ts -[connectedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesListSample.ts -[connectedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsUpdateSample.ts -[containerappsauthconfigscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts -[containerappsauthconfigsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts -[containerappsauthconfigsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsGetSample.ts -[containerappsauthconfigslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts -[containerappsbuildsbycontainerapplistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsByContainerAppListSample.ts -[containerappsbuildsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsDeleteSample.ts -[containerappsbuildsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsGetSample.ts -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsCreateOrUpdateSample.ts -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDeleteSample.ts -[containerappsdiagnosticsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetDetectorSample.ts -[containerappsdiagnosticsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRevisionSample.ts -[containerappsdiagnosticsgetrootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRootSample.ts -[containerappsdiagnosticslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListDetectorsSample.ts -[containerappsdiagnosticslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListRevisionsSample.ts -[containerappsgetauthtokensample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetAuthTokenSample.ts -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetSample.ts -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListByResourceGroupSample.ts -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListBySubscriptionSample.ts -[containerappslistcustomhostnameanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListSecretsSample.ts -[containerappspatchesapplysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesApplySample.ts -[containerappspatchesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesDeleteSample.ts -[containerappspatchesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesGetSample.ts -[containerappspatcheslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesListByContainerAppSample.ts -[containerappspatchesskipconfiguresample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesSkipConfigureSample.ts -[containerappsrevisionreplicasgetreplicasample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts -[containerappsrevisionreplicaslistreplicassample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts -[containerappssessionpoolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsCreateOrUpdateSample.ts -[containerappssessionpoolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsDeleteSample.ts -[containerappssessionpoolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsGetSample.ts -[containerappssessionpoolslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListByResourceGroupSample.ts -[containerappssessionpoolslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListBySubscriptionSample.ts -[containerappssessionpoolsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsUpdateSample.ts -[containerappssourcecontrolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts -[containerappssourcecontrolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts -[containerappssourcecontrolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsGetSample.ts -[containerappssourcecontrolslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts -[containerappsstartsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStartSample.ts -[containerappsstopsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStopSample.ts -[containerappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsUpdateSample.ts -[daprcomponentresiliencypoliciescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts -[daprcomponentresiliencypoliciesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesDeleteSample.ts -[daprcomponentresiliencypoliciesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesGetSample.ts -[daprcomponentresiliencypolicieslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesListSample.ts -[daprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts -[daprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsDeleteSample.ts -[daprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsGetSample.ts -[daprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSample.ts -[daprcomponentslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSecretsSample.ts -[daprsubscriptionscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsCreateOrUpdateSample.ts -[daprsubscriptionsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsDeleteSample.ts -[daprsubscriptionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsGetSample.ts -[daprsubscriptionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsListSample.ts -[dotnetcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsCreateOrUpdateSample.ts -[dotnetcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsDeleteSample.ts -[dotnetcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsGetSample.ts -[dotnetcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsListSample.ts -[dotnetcomponentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsUpdateSample.ts -[functionsextensioninvokefunctionshostsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/functionsExtensionInvokeFunctionsHostSample.ts -[getcustomdomainverificationidsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/getCustomDomainVerificationIdSample.ts -[javacomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsCreateOrUpdateSample.ts -[javacomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsDeleteSample.ts -[javacomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsGetSample.ts -[javacomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsListSample.ts -[javacomponentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsUpdateSample.ts -[jobexecutionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobExecutionSample.ts -[jobscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsCreateOrUpdateSample.ts -[jobsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsDeleteSample.ts -[jobsexecutionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsExecutionsListSample.ts -[jobsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetDetectorSample.ts -[jobsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetSample.ts -[jobslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListByResourceGroupSample.ts -[jobslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListBySubscriptionSample.ts -[jobslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListDetectorsSample.ts -[jobslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListSecretsSample.ts -[jobsproxygetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsProxyGetSample.ts -[jobsresumesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsResumeSample.ts -[jobsstartsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStartSample.ts -[jobsstopexecutionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopExecutionSample.ts -[jobsstopmultipleexecutionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopMultipleExecutionsSample.ts -[jobssuspendsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsSuspendSample.ts -[jobsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsUpdateSample.ts -[logicappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsCreateOrUpdateSample.ts -[logicappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeleteSample.ts -[logicappsdeployworkflowartifactssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeployWorkflowArtifactsSample.ts -[logicappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetSample.ts -[logicappsgetworkflowsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetWorkflowSample.ts -[logicappsinvokesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsInvokeSample.ts -[logicappslistworkflowsconnectionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsConnectionsSample.ts -[logicappslistworkflowssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsSample.ts -[managedcertificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesCreateOrUpdateSample.ts -[managedcertificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesDeleteSample.ts -[managedcertificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesGetSample.ts -[managedcertificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesListSample.ts -[managedcertificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesUpdateSample.ts -[managedenvironmentdiagnosticsgetdetectorsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsGetDetectorSample.ts -[managedenvironmentdiagnosticslistdetectorssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsListDetectorsSample.ts -[managedenvironmentprivateendpointconnectionscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts -[managedenvironmentprivateendpointconnectionsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts -[managedenvironmentprivateendpointconnectionsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsGetSample.ts -[managedenvironmentprivateendpointconnectionslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsListSample.ts -[managedenvironmentprivatelinkresourceslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateLinkResourcesListSample.ts -[managedenvironmentusageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentUsagesListSample.ts -[managedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts -[managedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDeleteSample.ts -[managedenvironmentsdiagnosticsgetrootsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDiagnosticsGetRootSample.ts -[managedenvironmentsgetauthtokensample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetAuthTokenSample.ts -[managedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetSample.ts -[managedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts -[managedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts -[managedenvironmentslistworkloadprofilestatessample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListWorkloadProfileStatesSample.ts -[managedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts -[managedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts -[managedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts -[managedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesListSample.ts -[managedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsUpdateSample.ts -[namespaceschecknameavailabilitysample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/namespacesCheckNameAvailabilitySample.ts -[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/operationsListSample.ts -[usageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/usagesListSample.ts -[apiref]: https://learn.microsoft.com/javascript/api/@azure/arm-appcontainers?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers/README.md -[typescript]: https://www.typescriptlang.org/docs/home.html diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/package.json b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/package.json deleted file mode 100644 index f5a6c50599f6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@azure-samples/arm-appcontainers-ts-beta", - "private": true, - "version": "1.0.0", - "description": " client library samples for TypeScript (Beta)", - "engines": { - "node": ">=18.0.0" - }, - "scripts": { - "build": "tsc", - "prebuild": "rimraf dist/" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/Azure/azure-sdk-for-js.git", - "directory": "sdk/appcontainers/arm-appcontainers" - }, - "keywords": [ - "node", - "azure", - "typescript", - "browser", - "isomorphic" - ], - "author": "Microsoft Corporation", - "license": "MIT", - "bugs": { - "url": "https://github.com/Azure/azure-sdk-for-js/issues" - }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appcontainers/arm-appcontainers", - "dependencies": { - "@azure/arm-appcontainers": "next", - "dotenv": "latest", - "@azure/identity": "^4.2.1" - }, - "devDependencies": { - "@types/node": "^18.0.0", - "typescript": "~5.7.2", - "rimraf": "latest" - } -} diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/sample.env b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/sample.env deleted file mode 100644 index 672847a3fea0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/sample.env +++ /dev/null @@ -1,4 +0,0 @@ -# App registration secret for AAD authentication -AZURE_CLIENT_SECRET= -AZURE_CLIENT_ID= -AZURE_TENANT_ID= \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyCreateOrUpdateSample.ts deleted file mode 100644 index b08de413b39f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyCreateOrUpdateSample.ts +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - AppResiliency, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update container app resiliency policy. - * - * @summary Create or update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_CreateOrUpdate.json - */ -async function createOrUpdateAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope: AppResiliency = { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 10, - maxEjectionPercent: 50, - }, - httpConnectionPool: { - http1MaxPendingRequests: 1024, - http2MaxRequests: 1024, - }, - httpRetryPolicy: { - errors: [ - "5xx", - "connect-failure", - "reset", - "retriable-headers", - "retriable-status-codes", - ], - headers: [{ header: "X-Content-Type", prefixMatch: "GOATS" }], - httpStatusCodes: [502, 503], - initialDelayInMilliseconds: 1000, - maxIntervalInMilliseconds: 10000, - maxRetries: 5, - }, - tcpConnectionPool: { maxConnections: 100 }, - tcpRetryPolicy: { maxConnectAttempts: 3 }, - timeoutPolicy: { - connectionTimeoutInSeconds: 5, - responseTimeoutInSeconds: 15, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.createOrUpdate( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyDeleteSample.ts deleted file mode 100644 index c7d51d11e382..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete container app resiliency policy. - * - * @summary Delete container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Delete.json - */ -async function deleteAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.delete( - resourceGroupName, - appName, - name, - ); - console.log(result); -} - -async function main() { - deleteAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyGetSample.ts deleted file mode 100644 index 06b446ce705c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get container app resiliency policy. - * - * @summary Get container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Get.json - */ -async function getAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.get( - resourceGroupName, - appName, - name, - ); - console.log(result); -} - -async function main() { - getAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyListSample.ts deleted file mode 100644 index 1a36b650a4e1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List container app resiliency policies. - * - * @summary List container app resiliency policies. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_List.json - */ -async function listAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.appResiliencyOperations.list( - resourceGroupName, - appName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyUpdateSample.ts deleted file mode 100644 index cd37e1465a02..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/appResiliencyUpdateSample.ts +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - AppResiliency, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update container app resiliency policy. - * - * @summary Update container app resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AppResiliency_Patch.json - */ -async function updateAppResiliency() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const appName = "testcontainerApp0"; - const name = "resiliency-policy-1"; - const resiliencyEnvelope: AppResiliency = { - timeoutPolicy: { - connectionTimeoutInSeconds: 40, - responseTimeoutInSeconds: 30, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.appResiliencyOperations.update( - resourceGroupName, - appName, - name, - resiliencyEnvelope, - ); - console.log(result); -} - -async function main() { - updateAppResiliency(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/availableWorkloadProfilesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/availableWorkloadProfilesGetSample.ts deleted file mode 100644 index 219030808b48..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/availableWorkloadProfilesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all available workload profiles for a location. - * - * @summary Get all available workload profiles for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AvailableWorkloadProfiles_Get.json - */ -async function billingMetersGet() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.availableWorkloadProfiles.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/billingMetersGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/billingMetersGetSample.ts deleted file mode 100644 index 9c15272dc84d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/billingMetersGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all billingMeters for a location. - * - * @summary Get all billingMeters for a location. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/BillingMeters_Get.json - */ -async function billingMetersGet() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const location = "East US"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.billingMeters.get(location); - console.log(result); -} - -async function main() { - billingMetersGet(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildAuthTokenListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildAuthTokenListSample.ts deleted file mode 100644 index 684c2b82b370..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildAuthTokenListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * - * @summary Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListAuthToken.json - */ -async function getBuildAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.buildAuthToken.list( - resourceGroupName, - builderName, - buildName, - ); - console.log(result); -} - -async function main() { - getBuildAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersCreateOrUpdateSample.ts deleted file mode 100644 index 883d6143f0f9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersCreateOrUpdateSample.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. - */ -import { - BuilderResource, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a BuilderResource - * - * @summary Create or update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_CreateOrUpdate.json - */ -async function buildersCreateOrUpdate0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope: BuilderResource = { - containerRegistries: [ - { - containerRegistryServer: "test.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - { - containerRegistryServer: "test2.azurecr.io", - identityResourceId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1", - }, - ], - environmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/rg/providers/Microsoft.App/managedEnvironments/testEnv", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/rg1/providers/MicrosoftManagedIdentity/userAssignedIdentities/identity1": - {}, - }, - }, - location: "eastus", - tags: { company: "Microsoft" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main() { - buildersCreateOrUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersDeleteSample.ts deleted file mode 100644 index ecefc62d6cc8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a BuilderResource - * - * @summary Delete a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Delete.json - */ -async function buildersDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginDeleteAndWait( - resourceGroupName, - builderName, - ); - console.log(result); -} - -async function main() { - buildersDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersGetSample.ts deleted file mode 100644 index 76aae6b651f8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a BuilderResource - * - * @summary Get a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Get.json - */ -async function buildersGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.get(resourceGroupName, builderName); - console.log(result); -} - -async function main() { - buildersGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListByResourceGroupSample.ts deleted file mode 100644 index fdd3689ccda4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuilderResource resources by resource group - * - * @summary List BuilderResource resources by resource group - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListByResourceGroup.json - */ -async function buildersListByResourceGroup0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.builders.listByResourceGroup( - resourceGroupName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildersListByResourceGroup0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListBySubscriptionSample.ts deleted file mode 100644 index 2b7c50af5f76..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuilderResource resources by subscription ID - * - * @summary List BuilderResource resources by subscription ID - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_ListBySubscription.json - */ -async function buildersListBySubscription0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.builders.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildersListBySubscription0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersUpdateSample.ts deleted file mode 100644 index a0e14fb2397b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildersUpdateSample.ts +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - BuilderResourceUpdate, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update a BuilderResource - * - * @summary Update a BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builders_Update.json - */ -async function buildersUpdate0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const builderEnvelope: BuilderResourceUpdate = { - tags: { mytag1: "myvalue1" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builders.beginUpdateAndWait( - resourceGroupName, - builderName, - builderEnvelope, - ); - console.log(result); -} - -async function main() { - buildersUpdate0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsByBuilderResourceListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsByBuilderResourceListSample.ts deleted file mode 100644 index 31826afaac37..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsByBuilderResourceListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List BuildResource resources by BuilderResource - * - * @summary List BuildResource resources by BuilderResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_ListByBuilderResource.json - */ -async function buildsListByBuilderResource0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.buildsByBuilderResource.list( - resourceGroupName, - builderName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - buildsListByBuilderResource0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsCreateOrUpdateSample.ts deleted file mode 100644 index 2eef79b40e08..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsCreateOrUpdateSample.ts +++ /dev/null @@ -1,104 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - BuildResource, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate_NoConfig.json - */ -async function buildsCreateOrUpdateNoConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const buildEnvelope: BuildResource = {}; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create a BuildResource - * - * @summary Create a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_CreateOrUpdate.json - */ -async function buildsCreateOrUpdateWithConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild-123456789az"; - const buildEnvelope: BuildResource = { - configuration: { - baseOs: "DebianBullseye", - environmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - platform: "dotnetcore", - platformVersion: "7.0", - preBuildSteps: [ - { - description: "First pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo", "bar"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'world'"], - }, - { - description: "Second pre build step.", - httpGet: { - fileName: "output.txt", - headers: ["foo"], - url: "https://microsoft.com", - }, - scripts: ["echo 'hello'", "echo 'again'"], - }, - ], - }, - destinationContainerRegistry: { - image: "test.azurecr.io/repo:tag", - server: "test.azurecr.io", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginCreateOrUpdateAndWait( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - ); - console.log(result); -} - -async function main() { - buildsCreateOrUpdateNoConfig(); - buildsCreateOrUpdateWithConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsDeleteSample.ts deleted file mode 100644 index b13b6bb6710f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a BuildResource - * - * @summary Delete a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Delete.json - */ -async function buildsDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.beginDeleteAndWait( - resourceGroupName, - builderName, - buildName, - ); - console.log(result); -} - -async function main() { - buildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsGetSample.ts deleted file mode 100644 index 753e0799b6bb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/buildsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a BuildResource - * - * @summary Get a BuildResource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Builds_Get.json - */ -async function buildsGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const builderName = "testBuilder"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.builds.get( - resourceGroupName, - builderName, - buildName, - ); - console.log(result); -} - -async function main() { - buildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesCreateOrUpdateSample.ts deleted file mode 100644 index f53bf237c747..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,96 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - Certificate, - CertificatesCreateOrUpdateOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - certificateType: "ImagePullTrustedCA", - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_CreateOrUpdate_FromKeyVault.json - */ -async function createOrUpdateCertificateUsingManagedIdentity() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - certificateKeyVaultProperties: { - identity: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/test-rg/providers/microsoft.managedidentity/userassignedidentities/test-user-mi", - keyVaultUrl: "https://xxxxxxxx.vault.azure.net/certificates/certName", - }, - certificateType: "ServerSSLCertificate", - }, - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - environmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); - createOrUpdateCertificateUsingManagedIdentity(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesDeleteSample.ts deleted file mode 100644 index d509d6839305..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete( - resourceGroupName, - environmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesGetSample.ts deleted file mode 100644 index e976a1304ecd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get( - resourceGroupName, - environmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesListSample.ts deleted file mode 100644 index 8e73a6272ee6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Certificates in a given managed environment. - * - * @summary Get the Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesUpdateSample.ts deleted file mode 100644 index 6c078bb04ad6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/certificatesUpdateSample.ts +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - CertificatePatch, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: CertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.update( - resourceGroupName, - environmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts deleted file mode 100644 index e1e04e622b00..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - Certificate, - ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Certificate. - * - * @summary Create or Update a Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - password: "private key password", - value: Buffer.from("Y2VydA=="), - }, - }; - const options: ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams = - { certificateEnvelope }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - certificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesDeleteSample.ts deleted file mode 100644 index c9bbea2c92f5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Certificate. - * - * @summary Deletes the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.delete( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesGetSample.ts deleted file mode 100644 index 5a5165f081d8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Certificate. - * - * @summary Get the specified Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.get( - resourceGroupName, - connectedEnvironmentName, - certificateName, - ); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesListSample.ts deleted file mode 100644 index d7fbe7c3f27e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Certificates in a given connected environment. - * - * @summary Get the Certificates in a given connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_ListByConnectedEnvironment.json - */ -async function listCertificatesByConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironmentsCertificates.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listCertificatesByConnectedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesUpdateSample.ts deleted file mode 100644 index bd5d9aa3411e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCertificatesUpdateSample.ts +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - CertificatePatch, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a certificate. Currently only patching of tags is supported - * - * @summary Patches a certificate. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const certificateName = "certificate-firendly-name"; - const certificateEnvelope: CertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsCertificates.update( - resourceGroupName, - connectedEnvironmentName, - certificateName, - certificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCheckNameAvailabilitySample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCheckNameAvailabilitySample.ts deleted file mode 100644 index 7cd7ce75e364..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCheckNameAvailabilitySample.ts +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - CheckNameAvailabilityRequest, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource connectedEnvironmentName is available. - * - * @summary Checks if resource connectedEnvironmentName is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsCertificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/connectedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.checkNameAvailability( - resourceGroupName, - connectedEnvironmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main() { - certificatesCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 2d088e3617eb..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ConnectedEnvironment, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates an connectedEnvironment. - * - * @summary Creates or updates an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_CreateOrUpdate.json - */ -async function createKubeEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const environmentEnvelope: ConnectedEnvironment = { - customDomainConfiguration: { - certificatePassword: "private key password", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - location: "East US", - staticIp: "1.2.3.4", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - connectedEnvironmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - createKubeEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 8e5804a4fe3c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DaprComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a connected environment. - * - * @summary Creates or updates a Dapr Component in a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.connectedEnvironmentsDaprComponents.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsDeleteSample.ts deleted file mode 100644 index 83f93945851d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr Component from a connected environment. - * - * @summary Delete a Dapr Component from a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.delete( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsGetSample.ts deleted file mode 100644 index f54858c8a66f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_Get.json - */ -async function getDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.get( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - getDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSample.ts deleted file mode 100644 index 423ef08d0d36..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr Components for a connected environment. - * - * @summary Get the Dapr Components for a connected environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironmentsDaprComponents.list( - resourceGroupName, - connectedEnvironmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSecretsSample.ts deleted file mode 100644 index ef2f6005cd2c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDaprComponentsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsDaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsDaprComponents.listSecrets( - resourceGroupName, - connectedEnvironmentName, - componentName, - ); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDeleteSample.ts deleted file mode 100644 index 83e854ffbf10..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete an connectedEnvironment. - * - * @summary Delete an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Delete.json - */ -async function deleteConnectedEnvironmentByConnectedEnvironmentName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.beginDeleteAndWait( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - deleteConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsGetSample.ts deleted file mode 100644 index 978ae93a2ed3..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of an connectedEnvironment. - * - * @summary Get the properties of an connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Get.json - */ -async function getConnectedEnvironmentByConnectedEnvironmentName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.get( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - getConnectedEnvironmentByConnectedEnvironmentName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index 70065ec1e340..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all connectedEnvironments in a resource group. - * - * @summary Get all connectedEnvironments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironments.listByResourceGroup( - resourceGroupName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index d38ff0c9d7ff..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all connectedEnvironments for a subscription. - * - * @summary Get all connectedEnvironments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_ListBySubscription.json - */ -async function listConnectedEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.connectedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listConnectedEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 1e1ddb50fbff..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesCreateOrUpdateSample.ts +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ConnectedEnvironmentStorage, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update storage for a connectedEnvironment. - * - * @summary Create or update storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ConnectedEnvironmentStorage = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - connectedEnvironmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateEnvironmentsStorage(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index aa8bfbb01982..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete storage for a connectedEnvironment. - * - * @summary Delete storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.delete( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index 8f700ace5b34..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get storage for a connectedEnvironment. - * - * @summary Get storage for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "env"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.get( - resourceGroupName, - connectedEnvironmentName, - storageName, - ); - console.log(result); -} - -async function main() { - getAEnvironmentsStoragePropertiesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesListSample.ts deleted file mode 100644 index 477c3fea800a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsStoragesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all storages for a connectedEnvironment. - * - * @summary Get all storages for a connectedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironmentsStorages.list( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsUpdateSample.ts deleted file mode 100644 index d802db98ffec..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/connectedEnvironmentsUpdateSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Managed Environment. Only patching of tags is supported currently - * - * @summary Patches a Managed Environment. Only patching of tags is supported currently - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ConnectedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const connectedEnvironmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.connectedEnvironments.update( - resourceGroupName, - connectedEnvironmentName, - ); - console.log(result); -} - -async function main() { - patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts deleted file mode 100644 index 1c150eddb400..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { AuthConfig, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update the AuthConfig for a Container App. - * - * @summary Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const authConfigEnvelope: AuthConfig = { - encryptionSettings: { - containerAppAuthEncryptionSecretName: "testEncryptionSecretName", - containerAppAuthSigningSecretName: "testSigningSecretName", - }, - globalValidation: { unauthenticatedClientAction: "AllowAnonymous" }, - identityProviders: { - facebook: { - registration: { appId: "123", appSecretSettingName: "facebook-secret" }, - }, - }, - platform: { enabled: true }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.createOrUpdate( - resourceGroupName, - containerAppName, - authConfigName, - authConfigEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts deleted file mode 100644 index fb19a902e1db..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App AuthConfig. - * - * @summary Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main() { - deleteContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsGetSample.ts deleted file mode 100644 index 906f62d67d31..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a AuthConfig of a Container App. - * - * @summary Get a AuthConfig of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const authConfigName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - authConfigName, - ); - console.log(result); -} - -async function main() { - getContainerAppAuthConfig(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts deleted file mode 100644 index e79ac69ac8c0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container App AuthConfigs in a given resource group. - * - * @summary Get the Container App AuthConfigs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsAuthConfigs.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAuthConfigsByContainerApps(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsByContainerAppListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsByContainerAppListSample.ts deleted file mode 100644 index c306193fa027..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsByContainerAppListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List Container Apps Build resources by Container App - * - * @summary List Container Apps Build resources by Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_ListByContainerApp.json - */ -async function containerAppsBuildsListByContainerApp0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsBuildsByContainerApp.list( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - containerAppsBuildsListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsDeleteSample.ts deleted file mode 100644 index 7c89d430f814..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container Apps Build resource - * - * @summary Delete a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Delete.json - */ -async function containerAppsBuildsDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.beginDeleteAndWait( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main() { - containerAppsBuildsDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsGetSample.ts deleted file mode 100644 index 413a119a228d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsBuildsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Container Apps Build resource - * - * @summary Get a Container Apps Build resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsBuilds_Get.json - */ -async function containerAppsBuildsGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testCapp"; - const buildName = "testBuild"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsBuilds.get( - resourceGroupName, - containerAppName, - buildName, - ); - console.log(result); -} - -async function main() { - containerAppsBuildsGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsCreateOrUpdateSample.ts deleted file mode 100644 index 9eed8112cfd7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsCreateOrUpdateSample.ts +++ /dev/null @@ -1,740 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerApp, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Kind_CreateOrUpdate.json - */ -async function createOrUpdateAppKind() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppKind"; - const containerAppEnvelope: ContainerApp = { - configuration: { - activeRevisionsMode: "Single", - ingress: { allowInsecure: true, external: true, targetPort: 80 }, - }, - kind: "workflowapp", - location: "East Us", - managedBy: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.Web/sites/testcontainerAppKind", - managedEnvironmentId: - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/testmanagedenv3", - template: { - containers: [ - { - name: "logicapps-container", - image: "default/logicapps-base:latest", - resources: { cpu: 1, memory: "2.0Gi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 30, - minReplicas: 1, - pollingInterval: 35, - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateAppOnAConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [ - { level: "debug", logger: "org.springframework.boot" }, - ], - }, - }, - }, - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [ - { level: "debug", logger: "org.springframework.boot" }, - ], - }, - }, - }, - }, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - { - name: "servicebus", - custom: { - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { - messageCount: "5", - namespace: "mynamespace", - queueName: "myqueue", - }, - }, - }, - { - name: "azure-queue", - azureQueue: { - accountName: "account1", - identity: "system", - queueLength: 1, - queueName: "queue1", - }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ManagedBy_CreateOrUpdate.json - */ -async function createOrUpdateManagedByApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppManagedBy"; - const containerAppEnvelope: ContainerApp = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [ - { revisionName: "testcontainerAppManagedBy-ab1234", weight: 100 }, - ], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - managedBy: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.AppPlatform/Spring/springapp", - template: { - containers: [ - { - name: "testcontainerAppManagedBy", - image: "repo/testcontainerAppManagedBy:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_SourceToCloudApp_CreateOrUpdate.json - */ -async function createOrUpdateSourceToCloudApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - additionalPortMappings: [ - { external: true, targetPort: 1234 }, - { exposedPort: 3456, external: false, targetPort: 2345 }, - ], - clientCertificateMode: "accept", - corsPolicy: { - allowCredentials: true, - allowedHeaders: ["HEADER1", "HEADER2"], - allowedMethods: ["GET", "POST"], - allowedOrigins: ["https://a.test.com", "https://b.test.com"], - exposeHeaders: ["HEADER3", "HEADER4"], - maxAge: 1234, - }, - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - service: { type: "redis" }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - patchingConfiguration: { patchingMode: "Automatic" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "", - imageType: "CloudBuild", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "redisService", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/redisService", - }, - ], - volumes: [ - { name: "azurefile", storageName: "storage", storageType: "AzureFile" }, - { - name: "nfsazurefile", - storageName: "nfsStorage", - storageType: "NfsAzureFile", - }, - ], - }, - workloadProfileName: "My-GP-01", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update a Container App. - * - * @summary Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_TcpApp_CreateOrUpdate.json - */ -async function createOrUpdateTcpApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerAppTcp"; - const containerAppEnvelope: ContainerApp = { - configuration: { - ingress: { - exposedPort: 4000, - external: true, - targetPort: 3000, - traffic: [{ revisionName: "testcontainerAppTcp-ab1234", weight: 100 }], - transport: "tcp", - }, - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppTcp", - image: "repo/testcontainerAppTcp:v1", - probes: [ - { - type: "Liveness", - initialDelaySeconds: 3, - periodSeconds: 3, - tcpSocket: { port: 8080 }, - }, - ], - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "tcpscalingrule", - tcp: { metadata: { concurrentConnections: "50" } }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateAppKind(); - createOrUpdateAppOnAConnectedEnvironment(); - createOrUpdateContainerApp(); - createOrUpdateManagedByApp(); - createOrUpdateSourceToCloudApp(); - createOrUpdateTcpApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDeleteSample.ts deleted file mode 100644 index 6c5518dd762e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App. - * - * @summary Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - deleteContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetDetectorSample.ts deleted file mode 100644 index 9357fa88317b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a diagnostics result of a Container App. - * - * @summary Get a diagnostics result of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_Get.json - */ -async function getContainerAppDiagnosticsInfo() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const detectorName = "cappcontainerappnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getDetector( - resourceGroupName, - containerAppName, - detectorName, - ); - console.log(result); -} - -async function main() { - getContainerAppDiagnosticsInfo(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRevisionSample.ts deleted file mode 100644 index f2a1643c1cb4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRootSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRootSample.ts deleted file mode 100644 index a21a43e13b1a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsGetRootSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsDiagnostics.getRoot( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListDetectorsSample.ts deleted file mode 100644 index 3e36993980e5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a given Container App. - * - * @summary Get the list of diagnostics for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticsForAGivenContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const containerAppName = "mikono-capp-stage1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsDiagnostics.listDetectors( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getTheListOfAvailableDiagnosticsForAGivenContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListRevisionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListRevisionsSample.ts deleted file mode 100644 index ff70ec97d17f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsDiagnosticsListRevisionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsDiagnostics.listRevisions( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppRevisions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetAuthTokenSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetAuthTokenSample.ts deleted file mode 100644 index 1112c0680545..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetAuthTokenSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get auth token for a container app - * - * @summary Get auth token for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_GetAuthToken.json - */ -async function getContainerAppAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.getAuthToken( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - getContainerAppAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetSample.ts deleted file mode 100644 index e1d21f482a55..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - getContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListByResourceGroupSample.ts deleted file mode 100644 index 023f6ccff3ee..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(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/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListBySubscriptionSample.ts deleted file mode 100644 index 2fc69deee171..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerApps.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts deleted file mode 100644 index 3c9dd20716f2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ContainerAppsListCustomHostNameAnalysisOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Analyzes a custom hostname for a Container App - * - * @summary Analyzes a custom hostname for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const customHostname = "my.name.corp"; - const options: ContainerAppsListCustomHostNameAnalysisOptionalParams = { - customHostname, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listCustomHostNameAnalysis( - resourceGroupName, - containerAppName, - options, - ); - console.log(result); -} - -async function main() { - analyzeCustomHostname(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListSecretsSample.ts deleted file mode 100644 index 79255e5dba2e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesApplySample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesApplySample.ts deleted file mode 100644 index 71472b73b645..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesApplySample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Apply a Container Apps Patch resource with patch name. - * - * @summary Apply a Container Apps Patch resource with patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Apply.json - */ -async function containerAppsPatchesApply0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginApplyAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesApply0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesDeleteSample.ts deleted file mode 100644 index b3a6d3bb2ddf..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete specific Container Apps Patch by patch name. - * - * @summary Delete specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Delete.json - */ -async function containerAppsPatchesDelete0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginDeleteAndWait( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesDelete0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesGetSample.ts deleted file mode 100644 index 1c6e8bb26f31..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get details for specific Container Apps Patch by patch name. - * - * @summary Get details for specific Container Apps Patch by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Get.json - */ -async function containerAppsPatchesGet0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.get( - resourceGroupName, - containerAppName, - patchName, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesGet0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesListByContainerAppSample.ts deleted file mode 100644 index df3c41257ca0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List Container Apps Patch resources by ContainerApp. - * - * @summary List Container Apps Patch resources by ContainerApp. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_ListByContainerApp.json - */ -async function containerAppsPatchesListByContainerApp0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsPatches.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - containerAppsPatchesListByContainerApp0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesSkipConfigureSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesSkipConfigureSample.ts deleted file mode 100644 index b970c3af52d8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsPatchesSkipConfigureSample.ts +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - PatchSkipConfig, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Configure the Container Apps Patch skip option by patch name. - * - * @summary Configure the Container Apps Patch skip option by patch name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerAppsPatches_Skip_Configure.json - */ -async function containerAppsPatchesSkipConfigure0() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "test-app"; - const patchName = "testPatch-25fe4b"; - const patchSkipConfig: PatchSkipConfig = { skip: true }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsPatches.beginSkipConfigureAndWait( - resourceGroupName, - containerAppName, - patchName, - patchSkipConfig, - ); - console.log(result); -} - -async function main() { - containerAppsPatchesSkipConfigure0(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts deleted file mode 100644 index fa4813633145..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a replica for a Container App Revision. - * - * @summary Get a replica for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const replicaName = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - replicaName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevisionReplica(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts deleted file mode 100644 index dc211f37012c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List replicas for a Container App Revision. - * - * @summary List replicas for a Container App Revision. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.listReplicas( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - listContainerAppReplicas(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts deleted file mode 100644 index a3e9149362c0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - activateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts deleted file mode 100644 index d7db860a8c63..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - deactivateContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts deleted file mode 100644 index b9476b5f7734..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsGetRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - getContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts deleted file mode 100644 index 512334170bed..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsListRevisionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(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/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts deleted file mode 100644 index 1f2361acba82..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "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/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testStaticSite0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - revisionName, - ); - console.log(result); -} - -async function main() { - restartContainerAppRevision(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsCreateOrUpdateSample.ts deleted file mode 100644 index 8ec819a68716..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsCreateOrUpdateSample.ts +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { SessionPool, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a session pool with the given properties. - * - * @summary Create or update a session pool with the given properties. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_CreateOrUpdate.json - */ -async function createOrUpdateSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope: SessionPool = { - containerType: "CustomContainer", - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - location: "East US", - poolManagementType: "Dynamic", - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.containerAppsSessionPools.beginCreateOrUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsDeleteSample.ts deleted file mode 100644 index b2479ff80b0f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete the session pool with the given name. - * - * @summary Delete the session pool with the given name. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Delete.json - */ -async function deleteSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginDeleteAndWait( - resourceGroupName, - sessionPoolName, - ); - console.log(result); -} - -async function main() { - deleteSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsGetSample.ts deleted file mode 100644 index b8772e3f7fd8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a session pool. - * - * @summary Get the properties of a session pool. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Get.json - */ -async function getSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.get( - resourceGroupName, - sessionPoolName, - ); - console.log(result); -} - -async function main() { - getSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListByResourceGroupSample.ts deleted file mode 100644 index 8141a20b7c1c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the session pools in a given resource group of a subscription. - * - * @summary Get the session pools in a given resource group of a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListByResourceGroup.json - */ -async function listSessionPoolsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSessionPools.listByResourceGroup( - resourceGroupName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listSessionPoolsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListBySubscriptionSample.ts deleted file mode 100644 index d5314ff0dff4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the session pools in a given subscription. - * - * @summary Get the session pools in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_ListBySubscription.json - */ -async function listSessionPoolsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSessionPools.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listSessionPoolsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsUpdateSample.ts deleted file mode 100644 index e2b358b9384f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSessionPoolsUpdateSample.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. - */ -import { - SessionPoolUpdatableProperties, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a session pool using JSON merge patch - * - * @summary Patches a session pool using JSON merge patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SessionPools_Patch.json - */ -async function updateSessionPool() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const sessionPoolName = "testsessionpool"; - const sessionPoolEnvelope: SessionPoolUpdatableProperties = { - customContainerTemplate: { - containers: [ - { - name: "testinitcontainer", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainer:v4", - resources: { cpu: 0.25, memory: "0.5Gi" }, - }, - ], - ingress: { targetPort: 80 }, - }, - dynamicPoolConfiguration: { - cooldownPeriodInSeconds: 600, - executionType: "Timed", - }, - scaleConfiguration: { - maxConcurrentSessions: 500, - readySessionInstances: 100, - }, - sessionNetworkConfiguration: { status: "EgressEnabled" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSessionPools.beginUpdateAndWait( - resourceGroupName, - sessionPoolName, - sessionPoolEnvelope, - ); - console.log(result); -} - -async function main() { - updateSessionPool(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts deleted file mode 100644 index ed2dda121c06..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - SourceControl, - ContainerAppsSourceControlsCreateOrUpdateOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update the SourceControl for a Container App. - * - * @summary Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const sourceControlEnvelope: SourceControl = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - kind: "feaderated", - tenantId: "", - }, - buildEnvironmentVariables: [ - { name: "foo1", value: "bar1" }, - { name: "foo2", value: "bar2" }, - ], - contextPath: "./", - dockerfilePath: "./Dockerfile", - githubPersonalAccessToken: "test", - image: "image/tag", - registryInfo: { - registryPassword: "", - registryUrl: "test-registry.azurecr.io", - registryUserName: "test-registry", - }, - }, - repoUrl: "https://github.com/xwang971/ghatest", - }; - const options: ContainerAppsSourceControlsCreateOrUpdateOptionalParams = { - xMsGithubAuxiliary, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - sourceControlEnvelope, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts deleted file mode 100644 index 5489b37b2d44..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts +++ /dev/null @@ -1,52 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ContainerAppsSourceControlsDeleteOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container App SourceControl. - * - * @summary Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const xMsGithubAuxiliary = "githubaccesstoken"; - const ignoreWorkflowDeletionFailure = false; - const deleteWorkflow = false; - const options: ContainerAppsSourceControlsDeleteOptionalParams = { - xMsGithubAuxiliary, - ignoreWorkflowDeletionFailure, - deleteWorkflow, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - sourceControlName, - options, - ); - console.log(result); -} - -async function main() { - deleteContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsGetSample.ts deleted file mode 100644 index 3d4a4e2672cc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a SourceControl of a Container App. - * - * @summary Get a SourceControl of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const sourceControlName = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - sourceControlName, - ); - console.log(result); -} - -async function main() { - getContainerAppSourceControl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts deleted file mode 100644 index 585f1d6d3d4f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container App SourceControls in a given resource group. - * - * @summary Get the Container App SourceControls in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.containerAppsSourceControls.listByContainerApp( - resourceGroupName, - containerAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAppSourceControls(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStartSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStartSample.ts deleted file mode 100644 index 2de730a0aa71..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStartSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Start a container app - * - * @summary Start a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Start.json - */ -async function startContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStartAndWait( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - startContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStopSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStopSample.ts deleted file mode 100644 index 1a1e41561232..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsStopSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Stop a container app - * - * @summary Stop a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Stop.json - */ -async function stopContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginStopAndWait( - resourceGroupName, - containerAppName, - ); - console.log(result); -} - -async function main() { - stopContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsUpdateSample.ts deleted file mode 100644 index 659deb240550..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/containerAppsUpdateSample.ts +++ /dev/null @@ -1,159 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerApp, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Container App using JSON Merge Patch - * - * @summary Patches a Container App using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { - appPort: 3000, - appProtocol: "http", - enableApiLogging: true, - enabled: true, - httpMaxRequestSize: 10, - httpReadBufferSize: 30, - logLevel: "debug", - }, - ingress: { - customDomains: [ - { - name: "www.my-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-name-dot-com", - }, - { - name: "www.my-other-name.com", - bindingType: "SniEnabled", - certificateId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube/certificates/my-certificate-for-my-other-name-dot-com", - }, - ], - external: true, - ipSecurityRestrictions: [ - { - name: "Allow work IP A subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/32", - }, - { - name: "Allow work IP B subnet", - description: - "Allowing all IP's within the subnet below to access containerapp", - action: "Allow", - ipAddressRange: "192.168.1.1/8", - }, - ], - stickySessions: { affinity: "sticky" }, - targetPort: 3000, - traffic: [ - { - label: "production", - revisionName: "testcontainerApp0-ab1234", - weight: 100, - }, - ], - }, - maxInactiveRevisions: 10, - runtime: { - dotnet: { autoConfigureDataProtection: true }, - java: { - enableMetrics: true, - javaAgent: { - enabled: true, - logging: { - loggerSettings: [ - { level: "debug", logger: "org.springframework.boot" }, - ], - }, - }, - }, - }, - service: { type: "redis" }, - }, - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - template: { - containers: [ - { - name: "testcontainerApp0", - image: "repo/testcontainerApp0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerApp0", - image: "repo/testcontainerApp0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - scale: { - cooldownPeriod: 350, - maxReplicas: 5, - minReplicas: 1, - pollingInterval: 35, - rules: [ - { - name: "httpscalingrule", - custom: { type: "http", metadata: { concurrentRequests: "50" } }, - }, - ], - }, - serviceBinds: [ - { - name: "service", - clientType: "dotnet", - customizedKeys: { desiredKey: "defaultKey" }, - serviceId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/containerApps/service", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginUpdateAndWait( - resourceGroupName, - containerAppName, - containerAppEnvelope, - ); - console.log(result); -} - -async function main() { - patchContainerApp(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts deleted file mode 100644 index ad86f3b5e16a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesCreateOrUpdateSample.ts +++ /dev/null @@ -1,164 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DaprComponentResiliencyPolicy, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_AllOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithAllOptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - inboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 5, - intervalInSeconds: 4, - timeoutInSeconds: 10, - }, - httpRetryPolicy: { - maxRetries: 15, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 30 }, - }, - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_OutboundOnly.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - outboundPolicy: { - circuitBreakerPolicy: { - consecutiveErrors: 3, - intervalInSeconds: 60, - timeoutInSeconds: 20, - }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 100, - maxIntervalInMilliseconds: 30000, - }, - }, - timeoutPolicy: { responseTimeoutInSeconds: 12 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a resiliency policy for a Dapr component. - * - * @summary Creates or updates a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicy_CreateOrUpdate_SparseOptions.json - */ -async function createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy = { - inboundPolicy: { - circuitBreakerPolicy: { consecutiveErrors: 3, timeoutInSeconds: 20 }, - httpRetryPolicy: { - maxRetries: 5, - retryBackOff: { - initialDelayInMilliseconds: 2000, - maxIntervalInMilliseconds: 5500, - }, - }, - }, - outboundPolicy: { timeoutPolicy: { responseTimeoutInSeconds: 12 } }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponentResiliencyPolicyWithAllOptions(); - createOrUpdateDaprComponentResiliencyPolicyWithOutboundPolicyOnly(); - createOrUpdateDaprComponentResiliencyPolicyWithSparseOptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesDeleteSample.ts deleted file mode 100644 index 61f84f7717c9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a resiliency policy for a Dapr component. - * - * @summary Delete a resiliency policy for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Delete.json - */ -async function deleteDaprComponentResiliencyPolicy() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.delete( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main() { - deleteDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesGetSample.ts deleted file mode 100644 index 5c8b7a26affd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Dapr component resiliency policy. - * - * @summary Get a Dapr component resiliency policy. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_Get.json - */ -async function getDaprComponentResiliencyPolicy() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const name = "myresiliencypolicy"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponentResiliencyPolicies.get( - resourceGroupName, - environmentName, - componentName, - name, - ); - console.log(result); -} - -async function main() { - getDaprComponentResiliencyPolicy(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesListSample.ts deleted file mode 100644 index 864592afdf70..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentResiliencyPoliciesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the resiliency policies for a Dapr component. - * - * @summary Get the resiliency policies for a Dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponentResiliencyPolicies_List.json - */ -async function listDaprComponentResiliencyPolicies() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "mydaprcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprComponentResiliencyPolicies.list( - resourceGroupName, - environmentName, - componentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponentResiliencyPolicies(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 83d96a7d2994..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,114 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DaprComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_SecretStoreComponent.json - */ -async function createOrUpdateDaprComponentWithSecretStoreComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secretStoreComponent: "my-secret-store", - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr Component in a Managed Environment. - * - * @summary Creates or updates a Dapr Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_CreateOrUpdate_Secrets.json - */ -async function createOrUpdateDaprComponentWithSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const daprComponentEnvelope: DaprComponent = { - componentType: "state.azure.cosmosdb", - ignoreErrors: false, - initTimeout: "50s", - metadata: [ - { name: "url", value: "" }, - { name: "database", value: "itemsDB" }, - { name: "collection", value: "items" }, - { name: "masterkey", secretRef: "masterkey" }, - ], - scopes: ["container-app-1", "container-app-2"], - secrets: [{ name: "masterkey", value: "keyvalue" }], - serviceComponentBind: [ - { - name: "statestore", - metadata: { name: "daprcomponentBind", value: "redis-bind" }, - serviceId: - "/subscriptions/9f7371f1-b593-4c3c-84e2-9167806ad358/resourceGroups/ca-syn2-group/providers/Microsoft.App/containerapps/cappredis", - }, - ], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - componentName, - daprComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprComponentWithSecretStoreComponent(); - createOrUpdateDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsDeleteSample.ts deleted file mode 100644 index af7fbfbc9e30..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr Component from a Managed Environment. - * - * @summary Delete a Dapr Component from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main() { - deleteDaprComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsGetSample.ts deleted file mode 100644 index 1a80824e51b8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsGetSample.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_SecretStoreComponent.json - */ -async function getDaprComponentWithSecretStoreComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr component. - * - * @summary Get a dapr component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_Get_Secrets.json - */ -async function getDaprComponentWithSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main() { - getDaprComponentWithSecretStoreComponent(); - getDaprComponentWithSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSample.ts deleted file mode 100644 index 976adfb8c1a1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr Components for a managed environment. - * - * @summary Get the Dapr Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprComponents.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprComponents(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSecretsSample.ts deleted file mode 100644 index debf1bd50d63..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprComponentsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a dapr component - * - * @summary List secrets for a dapr component - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprComponents_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const componentName = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.listSecrets( - resourceGroupName, - environmentName, - componentName, - ); - console.log(result); -} - -async function main() { - listContainerAppsSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsCreateOrUpdateSample.ts deleted file mode 100644 index 44bdb498d5b9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsCreateOrUpdateSample.ts +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DaprSubscription, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_BulkSubscribeAndScopes.json - */ -async function createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - bulkSubscribe: { - enabled: true, - maxAwaitDurationMs: 500, - maxMessagesCount: 123, - }, - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - scopes: ["warehouseapp", "customersupportapp"], - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_DefaultRoute.json - */ -async function createOrUpdateDaprSubscriptionWithDefaultRouteOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - pubsubName: "mypubsubcomponent", - routes: { default: "/products" }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Dapr subscription in a Managed Environment. - * - * @summary Creates or updates a Dapr subscription in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_CreateOrUpdate_RouteRulesAndMetadata.json - */ -async function createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const daprSubscriptionEnvelope: DaprSubscription = { - metadata: { foo: "bar", hello: "world" }, - pubsubName: "mypubsubcomponent", - routes: { - default: "/products", - rules: [ - { path: "/widgets", match: "event.type == 'widget'" }, - { path: "/gadgets", match: "event.type == 'gadget'" }, - ], - }, - topic: "inventory", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - createOrUpdateDaprSubscriptionWithDefaultRouteOnly(); - createOrUpdateDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsDeleteSample.ts deleted file mode 100644 index 362f92473074..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Dapr subscription from a Managed Environment. - * - * @summary Delete a Dapr subscription from a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Delete.json - */ -async function deleteDaprSubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mysubscription"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.delete( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - deleteDaprSubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsGetSample.ts deleted file mode 100644 index d7dc18c9a62e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsGetSample.ts +++ /dev/null @@ -1,90 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_DefaultRoute.json - */ -async function getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_BulkSubscribeAndScopes.json - */ -async function getDaprSubscriptionWithDefaultRouteOnly() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get a dapr subscription. - * - * @summary Get a dapr subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_Get_RouteRulesAndMetadata.json - */ -async function getDaprSubscriptionWithRouteRulesAndMetadata() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mypubsubcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprSubscriptions.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - getDaprSubscriptionWithBulkSubscribeConfigurationAndScopes(); - getDaprSubscriptionWithDefaultRouteOnly(); - getDaprSubscriptionWithRouteRulesAndMetadata(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsListSample.ts deleted file mode 100644 index 5a5bfecfc6a4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/daprSubscriptionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Dapr subscriptions for a managed environment. - * - * @summary Get the Dapr subscriptions for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DaprSubscriptions_List.json - */ -async function listDaprSubscriptions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.daprSubscriptions.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listDaprSubscriptions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsCreateOrUpdateSample.ts deleted file mode 100644 index 6c4717911fe3..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,85 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DotNetComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate.json - */ -async function createOrUpdateNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a .NET Component in a Managed Environment. - * - * @summary Creates or updates a .NET Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateNetComponent(); - createOrUpdateNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsDeleteSample.ts deleted file mode 100644 index 4a5a91e64196..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a .NET Component. - * - * @summary Delete a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Delete.json - */ -async function deleteNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - deleteNetComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsGetSample.ts deleted file mode 100644 index ab13d2888547..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsGetSample.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get.json - */ -async function getNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get a .NET Component. - * - * @summary Get a .NET Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Get_ServiceBind.json - */ -async function getNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - getNetComponent(); - getNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsListSample.ts deleted file mode 100644 index 18d4302d0cc9..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsListSample.ts +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List.json - */ -async function listNetComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.dotNetComponents.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the .NET Components for a managed environment. - * - * @summary Get the .NET Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_List_ServiceBind.json - */ -async function listNetComponentsWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.dotNetComponents.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listNetComponents(); - listNetComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsUpdateSample.ts deleted file mode 100644 index 7e6282598bb6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/dotNetComponentsUpdateSample.ts +++ /dev/null @@ -1,85 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - DotNetComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch.json - */ -async function patchNetComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a .NET Component using JSON Merge Patch - * - * @summary Patches a .NET Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/DotNetComponents_Patch_ServiceBind.json - */ -async function patchNetComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "mydotnetcomponent"; - const dotNetComponentEnvelope: DotNetComponent = { - componentType: "AspireDashboard", - configurations: [{ propertyName: "dashboard-theme", value: "dark" }], - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/dotNetComponents/yellowcat", - }, - ], - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.dotNetComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - ); - console.log(result); -} - -async function main() { - patchNetComponent(); - patchNetComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/functionsExtensionInvokeFunctionsHostSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/functionsExtensionInvokeFunctionsHostSample.ts deleted file mode 100644 index 241f31396b1b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/functionsExtensionInvokeFunctionsHostSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Proxies a Functions host call to the function app backed by the container app. - * - * @summary Proxies a Functions host call to the function app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/FunctionsExtension_Post.json - */ -async function invokeFunctionsHostUsingFunctionsExtensionApi() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const containerAppName = "testcontainerApp0"; - const revisionName = "testcontainerApp0-pjxhsye"; - const functionAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.functionsExtension.invokeFunctionsHost( - resourceGroupName, - containerAppName, - revisionName, - functionAppName, - ); - console.log(result); -} - -async function main() { - invokeFunctionsHostUsingFunctionsExtensionApi(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/getCustomDomainVerificationIdSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/getCustomDomainVerificationIdSample.ts deleted file mode 100644 index 12409e460403..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/getCustomDomainVerificationIdSample.ts +++ /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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the verification id of a subscription used for verifying custom domains - * - * @summary Get the verification id of a subscription used for verifying custom domains - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Subscriptions_GetCustomDomainVerificationId.json - */ -async function listAllOperations() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "d27c3573-f76e-4b26-b871-0ccd2203d08c"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.getCustomDomainVerificationId(); - console.log(result); -} - -async function main() { - listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsCreateOrUpdateSample.ts deleted file mode 100644 index e042ef5a5109..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,103 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - JavaComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate.json - */ -async function createOrUpdateJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Java Component in a Managed Environment. - * - * @summary Creates or updates a Java Component in a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_CreateOrUpdate_ServiceBind.json - */ -async function createOrUpdateJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateJavaComponent(); - createOrUpdateJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsDeleteSample.ts deleted file mode 100644 index 44ba8f1b12a8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Java Component. - * - * @summary Delete a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Delete.json - */ -async function deleteJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginDeleteAndWait( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - deleteJavaComponent(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsGetSample.ts deleted file mode 100644 index 49049d18f88c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsGetSample.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get.json - */ -async function getJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get a Java Component. - * - * @summary Get a Java Component. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Get_ServiceBind.json - */ -async function getJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.get( - resourceGroupName, - environmentName, - name, - ); - console.log(result); -} - -async function main() { - getJavaComponent(); - getJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsListSample.ts deleted file mode 100644 index f87e0ac33b8a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsListSample.ts +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List.json - */ -async function listJavaComponents() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.javaComponents.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -/** - * This sample demonstrates how to Get the Java Components for a managed environment. - * - * @summary Get the Java Components for a managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_List_ServiceBind.json - */ -async function listJavaComponentsWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.javaComponents.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listJavaComponents(); - listJavaComponentsWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsUpdateSample.ts deleted file mode 100644 index aaebe7fff7d7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/javaComponentsUpdateSample.ts +++ /dev/null @@ -1,103 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - JavaComponent, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch.json - */ -async function patchJavaComponent() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Patches a Java Component using JSON Merge Patch - * - * @summary Patches a Java Component using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/JavaComponents_Patch_ServiceBind.json - */ -async function patchJavaComponentWithServiceBinds() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "myenvironment"; - const name = "myjavacomponent"; - const javaComponentEnvelope: JavaComponent = { - properties: { - componentType: "SpringBootAdmin", - configurations: [ - { propertyName: "spring.boot.admin.ui.enable-toasts", value: "true" }, - { - propertyName: "spring.boot.admin.monitor.status-interval", - value: "10000ms", - }, - ], - scale: { maxReplicas: 1, minReplicas: 1 }, - serviceBinds: [ - { - name: "yellowcat", - serviceId: - "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/javaComponents/yellowcat", - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.javaComponents.beginUpdateAndWait( - resourceGroupName, - environmentName, - name, - javaComponentEnvelope, - ); - console.log(result); -} - -async function main() { - patchJavaComponent(); - patchJavaComponentWithServiceBinds(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobExecutionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobExecutionSample.ts deleted file mode 100644 index 151328de7c5d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobExecutionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get details of a single job execution - * - * @summary Get details of a single job execution - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Execution_Get.json - */ -async function getASingleJobExecution() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobExecution( - resourceGroupName, - jobName, - jobExecutionName, - ); - console.log(result); -} - -async function main() { - getASingleJobExecution(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsCreateOrUpdateSample.ts deleted file mode 100644 index f208bc71e607..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsCreateOrUpdateSample.ts +++ /dev/null @@ -1,247 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { Job, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate.json - */ -async function createOrUpdateContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - identitySettings: [ - { - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - lifecycle: "All", - }, - { identity: "system", lifecycle: "Init" }, - ], - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "SystemAssigned,UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - volumeMounts: [ - { - mountPath: "/mnt/path1", - subPath: "subPath1", - volumeName: "azurefile", - }, - { - mountPath: "/mnt/path2", - subPath: "subPath2", - volumeName: "nfsazurefile", - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_ConnectedEnvironment.json - */ -async function createOrUpdateContainerAppsJobOnAConnectedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/connectedEnvironments/demokube", - extendedLocation: { - name: "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.ExtendedLocation/customLocations/testcustomlocation", - type: "CustomLocation", - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 5, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or Update a Container Apps Job. - * - * @summary Create or Update a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_CreateorUpdate_EventTrigger.json - */ -async function createOrUpdateContainerAppsJobWithEventDrivenTrigger() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: Job = { - configuration: { - eventTriggerConfig: { - parallelism: 4, - replicaCompletionCount: 1, - scale: { - maxExecutions: 5, - minExecutions: 1, - pollingInterval: 40, - rules: [ - { - name: "servicebuscalingrule", - type: "azure-servicebus", - identity: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myidentity", - metadata: { topicName: "my-topic" }, - }, - ], - }, - }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Event", - }, - environmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - identity: { - type: "UserAssigned", - userAssignedIdentities: { - "/subscriptions/34adfa4fCedf4dc0Ba29B6d1a69ab345/resourcegroups/rg/providers/MicrosoftManagedIdentity/userAssignedIdentities/myidentity": - {}, - }, - }, - location: "East US", - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginCreateOrUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateContainerAppsJob(); - createOrUpdateContainerAppsJobOnAConnectedEnvironment(); - createOrUpdateContainerAppsJobWithEventDrivenTrigger(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsDeleteSample.ts deleted file mode 100644 index 69d7eb9a847b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Container Apps Job. - * - * @summary Delete a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Delete.json - */ -async function deleteContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testWorkerContainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginDeleteAndWait( - resourceGroupName, - jobName, - ); - console.log(result); -} - -async function main() { - deleteContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsExecutionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsExecutionsListSample.ts deleted file mode 100644 index 4b1c63a4a797..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsExecutionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a Container Apps Job's executions - * - * @summary Get a Container Apps Job's executions - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Executions_Get.json - */ -async function getAContainerAppsJobExecutions() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobsExecutions.list( - resourceGroupName, - jobName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getAContainerAppsJobExecutions(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetDetectorSample.ts deleted file mode 100644 index e05d2385794f..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the diagnostics data for a Container App Job. - * - * @summary Get the diagnostics data for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_GetDetector.json - */ -async function getDiagnosticDataForAContainerAppJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const detectorName = "containerappjobnetworkIO"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.getDetector( - resourceGroupName, - jobName, - detectorName, - ); - console.log(result); -} - -async function main() { - getDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetSample.ts deleted file mode 100644 index 84a94531cc6c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Container Apps Job. - * - * @summary Get the properties of a Container Apps Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Get.json - */ -async function getContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.get(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - getContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListByResourceGroupSample.ts deleted file mode 100644 index 2529aed0bca2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given resource group. - * - * @summary Get the Container Apps Jobs in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListByResourceGroup.json - */ -async function listContainerAppsJobsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listByResourceGroup(resourceGroupName)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsJobsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListBySubscriptionSample.ts deleted file mode 100644 index c1848a9d94b2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Container Apps Jobs in a given subscription. - * - * @summary Get the Container Apps Jobs in a given subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_ListBySubscription.json - */ -async function listContainerAppsJobsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listContainerAppsJobsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListDetectorsSample.ts deleted file mode 100644 index 747f4c13acac..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a Container App Job. - * - * @summary Get the list of diagnostics for a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListDetectors.json - */ -async function getTheListOfAvailableDiagnosticDataForAContainerAppJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const jobName = "mikonojob1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.jobs.listDetectors( - resourceGroupName, - jobName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - getTheListOfAvailableDiagnosticDataForAContainerAppJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListSecretsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListSecretsSample.ts deleted file mode 100644 index 5777e84c9b07..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsListSecretsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List secrets for a container apps job - * - * @summary List secrets for a container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ListSecrets.json - */ -async function listContainerAppsJobSecrets() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.listSecrets(resourceGroupName, jobName); - console.log(result); -} - -async function main() { - listContainerAppsJobSecrets(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsProxyGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsProxyGetSample.ts deleted file mode 100644 index 196819f7b364..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsProxyGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Container App Job. - * - * @summary Get the properties of a Container App Job. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_ProxyGet.json - */ -async function getContainerAppJobByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const apiName = "rootApi"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.proxyGet( - resourceGroupName, - jobName, - apiName, - ); - console.log(result); -} - -async function main() { - getContainerAppJobByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsResumeSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsResumeSample.ts deleted file mode 100644 index 6918a6d49c6b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsResumeSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Resumes a suspended job - * - * @summary Resumes a suspended job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Resume.json - */ -async function resumeJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginResumeAndWait( - resourceGroupName, - jobName, - ); - console.log(result); -} - -async function main() { - resumeJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStartSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStartSample.ts deleted file mode 100644 index 0afff5b1cf0b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStartSample.ts +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - JobExecutionTemplate, - JobsStartOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Start a Container Apps Job - * - * @summary Start a Container Apps Job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Start.json - */ -async function runAContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const template: JobExecutionTemplate = { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }; - const options: JobsStartOptionalParams = { template }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStartAndWait( - resourceGroupName, - jobName, - options, - ); - console.log(result); -} - -async function main() { - runAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopExecutionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopExecutionSample.ts deleted file mode 100644 index c741a7e083a5..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopExecutionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Execution.json - */ -async function terminateAContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobExecutionName = "jobExecution1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopExecutionAndWait( - resourceGroupName, - jobName, - jobExecutionName, - ); - console.log(result); -} - -async function main() { - terminateAContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopMultipleExecutionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopMultipleExecutionsSample.ts deleted file mode 100644 index 1f7904face5c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsStopMultipleExecutionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Terminates execution of a running container apps job - * - * @summary Terminates execution of a running container apps job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Stop_Multiple.json - */ -async function terminateMultipleContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginStopMultipleExecutionsAndWait( - resourceGroupName, - jobName, - ); - console.log(result); -} - -async function main() { - terminateMultipleContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsSuspendSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsSuspendSample.ts deleted file mode 100644 index b497dc43bc41..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsSuspendSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Suspends a job - * - * @summary Suspends a job - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Jobs_Suspend.json - */ -async function suspendJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginSuspendAndWait( - resourceGroupName, - jobName, - ); - console.log(result); -} - -async function main() { - suspendJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsUpdateSample.ts deleted file mode 100644 index 14037e3e7331..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/jobsUpdateSample.ts +++ /dev/null @@ -1,80 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - JobPatchProperties, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Container Apps Job using JSON Merge Patch - * - * @summary Patches a Container Apps Job using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Job_Patch.json - */ -async function patchContainerAppsJob() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const jobName = "testcontainerAppsJob0"; - const jobEnvelope: JobPatchProperties = { - properties: { - configuration: { - manualTriggerConfig: { parallelism: 4, replicaCompletionCount: 1 }, - replicaRetryLimit: 10, - replicaTimeout: 10, - triggerType: "Manual", - }, - template: { - containers: [ - { - name: "testcontainerAppsJob0", - image: "repo/testcontainerAppsJob0:v1", - probes: [ - { - type: "Liveness", - httpGet: { - path: "/health", - httpHeaders: [{ name: "Custom-Header", value: "Awesome" }], - port: 8080, - }, - initialDelaySeconds: 3, - periodSeconds: 3, - }, - ], - }, - ], - initContainers: [ - { - name: "testinitcontainerAppsJob0", - args: ["-c", "while true; do echo hello; sleep 10;done"], - command: ["/bin/sh"], - image: "repo/testcontainerAppsJob0:v4", - resources: { cpu: 0.2, memory: "100Mi" }, - }, - ], - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.jobs.beginUpdateAndWait( - resourceGroupName, - jobName, - jobEnvelope, - ); - console.log(result); -} - -async function main() { - patchContainerAppsJob(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsCreateOrUpdateSample.ts deleted file mode 100644 index 8e5f124c6f28..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsCreateOrUpdateSample.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. - */ -import { LogicApp, ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update a Logic App extension resource - * - * @summary Create or update a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Create.json - */ -async function createLogicAppExtension() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const resource: LogicApp = { properties: {} }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.createOrUpdate( - resourceGroupName, - containerAppName, - logicAppName, - resource, - ); - console.log(result); -} - -async function main() { - createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeleteSample.ts deleted file mode 100644 index d2d0763303c8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes a Logic App extension resource - * - * @summary Deletes a Logic App extension resource - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Delete.json - */ -async function createLogicAppExtension() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.delete( - resourceGroupName, - containerAppName, - logicAppName, - ); - console.log(result); -} - -async function main() { - createLogicAppExtension(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeployWorkflowArtifactsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeployWorkflowArtifactsSample.ts deleted file mode 100644 index 4401ddf97f11..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsDeployWorkflowArtifactsSample.ts +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - WorkflowArtifacts, - LogicAppsDeployWorkflowArtifactsOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_DeleteDeployWorkflowArtifacts.json - */ -async function deleteWorkflowArtifacts() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts: WorkflowArtifacts = { - filesToDelete: ["test/workflow.json", "test/"], - }; - const options: LogicAppsDeployWorkflowArtifactsOptionalParams = { - workflowArtifacts, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates the artifacts for the logic app - * - * @summary Creates or updates the artifacts for the logic app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_PostDeployWorkflowArtifacts.json - */ -async function deploysWorkflowArtifacts() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const workflowArtifacts: WorkflowArtifacts = { - appSettings: { - eventHub_connectionString: - "Endpoint=sb://example.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=EXAMPLE1a2b3c4d5e6fEXAMPLE=", - }, - files: { - "connections.json": { - managedApiConnections: {}, - serviceProviderConnections: { - eventHub: { - displayName: "example1", - parameterValues: { - connectionString: "@appsetting('eventHub_connectionString')", - }, - serviceProvider: { id: "/serviceProviders/eventHub" }, - }, - }, - }, - "test1/workflow.json": { - 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: LogicAppsDeployWorkflowArtifactsOptionalParams = { - workflowArtifacts, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.deployWorkflowArtifacts( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - console.log(result); -} - -async function main() { - deleteWorkflowArtifacts(); - deploysWorkflowArtifacts(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetSample.ts deleted file mode 100644 index 812fa29a27f2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets a logic app extension resource. - * - * @summary Gets a logic app extension resource. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_Get.json - */ -async function getLogicAppExtensionByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.get( - resourceGroupName, - containerAppName, - logicAppName, - ); - console.log(result); -} - -async function main() { - getLogicAppExtensionByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetWorkflowSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetWorkflowSample.ts deleted file mode 100644 index 76901cd60da7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsGetWorkflowSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get workflow information by its name - * - * @summary Get workflow information by its name - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_GetWorkflow.json - */ -async function getAWorkflow() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const workflowName = "stateful1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.getWorkflow( - resourceGroupName, - containerAppName, - logicAppName, - workflowName, - ); - console.log(result); -} - -async function main() { - getAWorkflow(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsInvokeSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsInvokeSample.ts deleted file mode 100644 index e98d68c79c7a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsInvokeSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Proxies a the API call to the logic app backed by the container app. - * - * @summary Proxies a the API call to the logic app backed by the container app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListCallbackURL.json - */ -async function getWorkflowListCallBackUrl() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.invoke( - resourceGroupName, - containerAppName, - logicAppName, - "/runtime/webhooks/workflow/api/management/workflows/Stateful1/triggers/When_a_HTTP_request_is_received/listCallbackUrl", - "POST" - ); - console.log(result); -} - -async function main() { - getWorkflowListCallBackUrl(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsConnectionsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsConnectionsSample.ts deleted file mode 100644 index 3ddd174a1024..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsConnectionsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets logic app's connections. - * - * @summary Gets logic app's connections. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListConnections.json - */ -async function listTheWorkflowsConfigurationConnections() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "testrg123"; - const containerAppName = "testapp2"; - const logicAppName = "testapp2"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.logicApps.listWorkflowsConnections( - resourceGroupName, - containerAppName, - logicAppName, - ); - console.log(result); -} - -async function main() { - listTheWorkflowsConfigurationConnections(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsSample.ts deleted file mode 100644 index cce0150f30e4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/logicAppsListWorkflowsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List the workflows for a logic app. - * - * @summary List the workflows for a logic app. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/LogicApps_ListWorkflows.json - */ -async function listTheWorkflows() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const containerAppName = "testcontainerApp0"; - const logicAppName = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.logicApps.listWorkflows( - resourceGroupName, - containerAppName, - logicAppName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listTheWorkflows(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesCreateOrUpdateSample.ts deleted file mode 100644 index 9dd38f419073..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesCreateOrUpdateSample.ts +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ManagedCertificate, - ManagedCertificatesCreateOrUpdateOptionalParams, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or Update a Managed Certificate. - * - * @summary Create or Update a Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope: ManagedCertificate = { - location: "East US", - properties: { - domainControlValidation: "CNAME", - subjectName: "my-subject-name.company.country.net", - }, - }; - const options: ManagedCertificatesCreateOrUpdateOptionalParams = { - managedCertificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - managedCertificateName, - options, - ); - console.log(result); -} - -async function main() { - createOrUpdateCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesDeleteSample.ts deleted file mode 100644 index 6f7edc6d839b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Deletes the specified Managed Certificate. - * - * @summary Deletes the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.delete( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main() { - deleteCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesGetSample.ts deleted file mode 100644 index d8068f58dabc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the specified Managed Certificate. - * - * @summary Get the specified Managed Certificate. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificate_Get.json - */ -async function getCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.get( - resourceGroupName, - environmentName, - managedCertificateName, - ); - console.log(result); -} - -async function main() { - getCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesListSample.ts deleted file mode 100644 index 1d61e385ef16..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the Managed Certificates in a given managed environment. - * - * @summary Get the Managed Certificates in a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_ListByManagedEnvironment.json - */ -async function listManagedCertificatesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedCertificates.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listManagedCertificatesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesUpdateSample.ts deleted file mode 100644 index fa3e52a9b22b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedCertificatesUpdateSample.ts +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ManagedCertificatePatch, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a managed certificate. Oly patching of tags is supported - * - * @summary Patches a managed certificate. Oly patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedCertificates_Patch.json - */ -async function patchManagedCertificate() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const managedCertificateName = "certificate-firendly-name"; - const managedCertificateEnvelope: ManagedCertificatePatch = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedCertificates.update( - resourceGroupName, - environmentName, - managedCertificateName, - managedCertificateEnvelope, - ); - console.log(result); -} - -async function main() { - patchManagedCertificate(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsGetDetectorSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsGetDetectorSample.ts deleted file mode 100644 index 76f84ee26a29..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsGetDetectorSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the diagnostics data for a Managed Environment used to host container apps. - * - * @summary Get the diagnostics data for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_Get.json - */ -async function getDiagnosticDataForAManagedEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const detectorName = "ManagedEnvAvailabilityMetrics"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.getDetector( - resourceGroupName, - environmentName, - detectorName, - ); - console.log(result); -} - -async function main() { - getDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsListDetectorsSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsListDetectorsSample.ts deleted file mode 100644 index 2e3b462859e0..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentDiagnosticsListDetectorsSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the list of diagnostics for a Managed Environment used to host container apps. - * - * @summary Get the list of diagnostics for a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentDiagnostics_List.json - */ -async function getTheListOfAvailableDiagnosticDataForAManagedEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "f07f3711-b45e-40fe-a941-4e6d93f851e6"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "mikono-workerapp-test-rg"; - const environmentName = "mikonokubeenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentDiagnostics.listDetectors( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getTheListOfAvailableDiagnosticDataForAManagedEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts deleted file mode 100644 index 66caddc99278..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsCreateOrUpdateSample.ts +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - PrivateEndpointConnection, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Update the state of a private endpoint connection for a given managed environment. - * - * @summary Update the state of a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_CreateOrUpdate.json - */ -async function updateAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const privateEndpointConnectionEnvelope: PrivateEndpointConnection = { - privateLinkServiceConnectionState: { - actionsRequired: "None", - status: "Approved", - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.managedEnvironmentPrivateEndpointConnections.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - privateEndpointConnectionEnvelope, - ); - console.log(result); -} - -async function main() { - updateAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsDeleteSample.ts deleted file mode 100644 index 56eb38f4a425..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a private endpoint connection for a given managed environment. - * - * @summary Delete a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Delete.json - */ -async function deleteAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = - await client.managedEnvironmentPrivateEndpointConnections.beginDeleteAndWait( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main() { - deleteAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsGetSample.ts deleted file mode 100644 index 01103bdd732a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get a private endpoint connection for a given managed environment. - * - * @summary Get a private endpoint connection for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_Get.json - */ -async function getAPrivateEndpointConnectionByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const privateEndpointConnectionName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentPrivateEndpointConnections.get( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - ); - console.log(result); -} - -async function main() { - getAPrivateEndpointConnectionByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsListSample.ts deleted file mode 100644 index 3e9db3663900..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateEndpointConnectionsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List private endpoint connections for a given managed environment. - * - * @summary List private endpoint connections for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateEndpointConnections_List.json - */ -async function listPrivateEndpointConnectionsByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentPrivateEndpointConnections.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listPrivateEndpointConnectionsByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateLinkResourcesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateLinkResourcesListSample.ts deleted file mode 100644 index 1986fb140ce7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentPrivateLinkResourcesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to List private link resources for a given managed environment. - * - * @summary List private link resources for a given managed environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentPrivateLinkResources_List.json - */ -async function listPrivateLinkResourcesByManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentPrivateLinkResources.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listPrivateLinkResourcesByManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentUsagesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentUsagesListSample.ts deleted file mode 100644 index 2d02c46599fd..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentUsagesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets the current usage information as well as the limits for environment. - * - * @summary Gets the current usage information as well as the limits for environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentUsages_List.json - */ -async function listManagedEnvironmentUsages() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironmentUsages.list( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listManagedEnvironmentUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 13dab75e8330..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,183 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ManagedEnvironment, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CustomInfrastructureResourceGroup_Create.json - */ -async function createEnvironmentWithCustomInfrastructureResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - infrastructureResourceGroup: "myInfrastructureRgName", - location: "East US", - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Creates or updates a Managed Environment used to host container apps. - * - * @summary Creates or updates a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appInsightsConfiguration: { - connectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://eastus-8.in.applicationinsights.azure.com/;LiveEndpoint=https://eastus.livediagnostics.monitor.azure.com/", - }, - appLogsConfiguration: { - logAnalyticsConfiguration: { - customerId: "string", - dynamicJsonColumns: true, - sharedKey: "string", - }, - }, - customDomainConfiguration: { - certificatePassword: "1234", - certificateValue: Buffer.from("Y2VydA=="), - dnsSuffix: "www.my-name.com", - }, - daprAIConnectionString: - "InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://northcentralus-0.in.applicationinsights.azure.com/", - identity: { - type: "SystemAssigned, UserAssigned", - userAssignedIdentities: { - "/subscriptions/00000000000000000000000000000000/resourceGroups/contosoResources/providers/MicrosoftManagedIdentity/userAssignedIdentities/contosoIdentity": - {}, - }, - }, - location: "East US", - openTelemetryConfiguration: { - destinationsConfiguration: { - dataDogConfiguration: { - key: "000000000000000000000000", - site: "string", - }, - otlpConfigurations: [ - { - name: "dashboard", - endpoint: "dashboard.k8s.region.azurecontainerapps.io:80", - headers: [{ key: "api-key", value: "xxxxxxxxxxx" }], - insecure: true, - }, - ], - }, - logsConfiguration: { destinations: ["appInsights"] }, - metricsConfiguration: { destinations: ["dataDog"], includeKeda: true }, - tracesConfiguration: { destinations: ["appInsights"], includeDapr: true }, - }, - peerAuthentication: { mtls: { enabled: true } }, - peerTrafficConfiguration: { encryption: { enabled: true } }, - vnetConfiguration: { - infrastructureSubnetId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/RGName/providers/Microsoft.Network/virtualNetworks/VNetName/subnets/subnetName1", - }, - workloadProfiles: [ - { - name: "My-GP-01", - enableFips: true, - maximumCount: 12, - minimumCount: 3, - workloadProfileType: "GeneralPurpose", - }, - { - name: "My-MO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "MemoryOptimized", - }, - { - name: "My-CO-01", - maximumCount: 6, - minimumCount: 3, - workloadProfileType: "ComputeOptimized", - }, - { name: "My-consumption-01", workloadProfileType: "Consumption" }, - ], - zoneRedundant: true, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - createEnvironmentWithCustomInfrastructureResourceGroup(); - createEnvironments(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDeleteSample.ts deleted file mode 100644 index c689045884ac..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete a Managed Environment if it does not have any container apps. - * - * @summary Delete a Managed Environment if it does not have any container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - deleteEnvironmentByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDiagnosticsGetRootSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDiagnosticsGetRootSample.ts deleted file mode 100644 index 3c8c90850dc8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsDiagnosticsGetRootSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsDiagnostics.getRoot( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetAuthTokenSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetAuthTokenSample.ts deleted file mode 100644 index c5cff30f3f3e..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetAuthTokenSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_GetAuthToken.json - */ -async function getManagedEnvironmentAuthToken() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = process.env["APPCONTAINERS_RESOURCE_GROUP"] || "rg"; - const environmentName = "testenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.getAuthToken( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getManagedEnvironmentAuthToken(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetSample.ts deleted file mode 100644 index 41da37c31c92..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsGetSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get the properties of a Managed Environment used to host container apps. - * - * @summary Get the properties of a Managed Environment used to host container apps. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - getEnvironmentsByName(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index 276879b1354d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all the Managed Environments in a resource group. - * - * @summary Get all the Managed Environments in a resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listByResourceGroup( - resourceGroupName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsByResourceGroup(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index 47eada1b82f4..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all Managed Environments for a subscription. - * - * @summary Get all Managed Environments for a subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listBySubscription()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListWorkloadProfileStatesSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListWorkloadProfileStatesSample.ts deleted file mode 100644 index 26927fabb7ba..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsListWorkloadProfileStatesSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all workload Profile States for a Managed Environment. - * - * @summary Get all workload Profile States for a Managed Environment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_ListWorkloadProfileStates.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listWorkloadProfileStates( - resourceGroupName, - environmentName, - )) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listEnvironmentsBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 4a003069ea13..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts +++ /dev/null @@ -1,89 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ManagedEnvironmentStorage, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ManagedEnvironmentStorage = { - properties: { - azureFile: { - accessMode: "ReadOnly", - accountKey: "key", - accountName: "account1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Create or update storage for a managedEnvironment. - * - * @summary Create or update storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate_NfsAzureFile.json - */ -async function createOrUpdateEnvironmentsStorageForNfsAzureFile() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const storageEnvelope: ManagedEnvironmentStorage = { - properties: { - nfsAzureFile: { - accessMode: "ReadOnly", - server: "server1", - shareName: "share1", - }, - }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.createOrUpdate( - resourceGroupName, - environmentName, - storageName, - storageEnvelope, - ); - console.log(result); -} - -async function main() { - createOrUpdateEnvironmentsStorage(); - createOrUpdateEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index b8c5bcfa0674..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Delete storage for a managedEnvironment. - * - * @summary Delete storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index d2546a5f06c7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStorage() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Get storage for a managedEnvironment. - * - * @summary Get storage for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_Get_NfsAzureFile.json - */ -async function getAEnvironmentsStorageForNfsAzureFile() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const storageName = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - environmentName, - storageName, - ); - console.log(result); -} - -async function main() { - getAEnvironmentsStorage(); - getAEnvironmentsStorageForNfsAzureFile(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesListSample.ts deleted file mode 100644 index 2f2013513687..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsStoragesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Get all storages for a managedEnvironment. - * - * @summary Get all storages for a managedEnvironment. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list( - resourceGroupName, - environmentName, - ); - console.log(result); -} - -async function main() { - listEnvironmentsStoragesBySubscription(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsUpdateSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsUpdateSample.ts deleted file mode 100644 index b3d2b4865b65..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/managedEnvironmentsUpdateSample.ts +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - ManagedEnvironment, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Patches a Managed Environment using JSON Merge Patch - * - * @summary Patches a Managed Environment using JSON Merge Patch - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - location: "East US", - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginUpdateAndWait( - resourceGroupName, - environmentName, - environmentEnvelope, - ); - console.log(result); -} - -async function main() { - patchManagedEnvironment(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/namespacesCheckNameAvailabilitySample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/namespacesCheckNameAvailabilitySample.ts deleted file mode 100644 index 353e2bc1826a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/namespacesCheckNameAvailabilitySample.ts +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ -import { - CheckNameAvailabilityRequest, - ContainerAppsAPIClient, -} from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Certificates_CheckNameAvailability.json - */ -async function certificatesCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcertificatename", - type: "Microsoft.App/managedEnvironments/certificates", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -/** - * This sample demonstrates how to Checks if resource name is available. - * - * @summary Checks if resource name is available. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/ContainerApps_CheckNameAvailability.json - */ -async function containerAppsCheckNameAvailability() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = - process.env["APPCONTAINERS_RESOURCE_GROUP"] || "examplerg"; - const environmentName = "testcontainerenv"; - const checkNameAvailabilityRequest: CheckNameAvailabilityRequest = { - name: "testcappname", - type: "Microsoft.App/containerApps", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.namespaces.checkNameAvailability( - resourceGroupName, - environmentName, - checkNameAvailabilityRequest, - ); - console.log(result); -} - -async function main() { - certificatesCheckNameAvailability(); - containerAppsCheckNameAvailability(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/operationsListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/operationsListSample.ts deleted file mode 100644 index 16f363debc37..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/operationsListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Lists all of the available RP operations. - * - * @summary Lists all of the available RP operations. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Operations_List.json - */ -async function listAllOperations() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || - "00000000-0000-0000-0000-000000000000"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.operations.list()) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listAllOperations(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/usagesListSample.ts b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/usagesListSample.ts deleted file mode 100644 index 0747686f0db8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/src/usagesListSample.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. - */ -import { ContainerAppsAPIClient } from "@azure/arm-appcontainers"; -import { DefaultAzureCredential } from "@azure/identity"; -import "dotenv/config"; - -/** - * This sample demonstrates how to Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * - * @summary Gets, for the specified location, the current resource usage information as well as the limits under the subscription. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2024-08-02-preview/examples/Usages_List.json - */ -async function listUsages() { - const subscriptionId = - process.env["APPCONTAINERS_SUBSCRIPTION_ID"] || "subid"; - const location = "westus"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.usages.list(location)) { - resArray.push(item); - } - console.log(resArray); -} - -async function main() { - listUsages(); -} - -main().catch(console.error); diff --git a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/tsconfig.json b/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/tsconfig.json deleted file mode 100644 index 984eed535aa8..000000000000 --- a/sdk/appcontainers/arm-appcontainers/samples/v2-beta/typescript/tsconfig.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "compilerOptions": { - "target": "ES2020", - "module": "commonjs", - "moduleResolution": "node", - "resolveJsonModule": true, - "esModuleInterop": true, - "allowSyntheticDefaultImports": true, - "strict": true, - "alwaysStrict": true, - "outDir": "dist", - "rootDir": "src" - }, - "include": [ - "src/**/*.ts" - ] -} diff --git a/sdk/appcontainers/arm-appcontainers/src/containerAppsAPIClient.ts b/sdk/appcontainers/arm-appcontainers/src/containerAppsAPIClient.ts index 5ffab2f9fc2e..caa7c9c91869 100644 --- a/sdk/appcontainers/arm-appcontainers/src/containerAppsAPIClient.ts +++ b/sdk/appcontainers/arm-appcontainers/src/containerAppsAPIClient.ts @@ -15,43 +15,28 @@ import { } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { - AppResiliencyOperationsImpl, ContainerAppsAuthConfigsImpl, AvailableWorkloadProfilesImpl, BillingMetersImpl, - BuildersImpl, - BuildsByBuilderResourceImpl, - BuildsImpl, - BuildAuthTokenImpl, ConnectedEnvironmentsImpl, ConnectedEnvironmentsCertificatesImpl, ConnectedEnvironmentsDaprComponentsImpl, ConnectedEnvironmentsStoragesImpl, ContainerAppsImpl, - ContainerAppsBuildsByContainerAppImpl, - ContainerAppsBuildsImpl, - ContainerAppsPatchesImpl, ContainerAppsRevisionsImpl, ContainerAppsRevisionReplicasImpl, ContainerAppsDiagnosticsImpl, ManagedEnvironmentDiagnosticsImpl, ManagedEnvironmentsDiagnosticsImpl, JobsImpl, - DotNetComponentsImpl, - FunctionsExtensionImpl, OperationsImpl, JavaComponentsImpl, JobsExecutionsImpl, - LogicAppsImpl, ManagedEnvironmentsImpl, CertificatesImpl, ManagedCertificatesImpl, NamespacesImpl, - ManagedEnvironmentPrivateEndpointConnectionsImpl, - ManagedEnvironmentPrivateLinkResourcesImpl, - DaprComponentResiliencyPoliciesImpl, DaprComponentsImpl, - DaprSubscriptionsImpl, ManagedEnvironmentsStoragesImpl, ContainerAppsSessionPoolsImpl, ContainerAppsSourceControlsImpl, @@ -59,43 +44,28 @@ import { ManagedEnvironmentUsagesImpl, } from "./operations/index.js"; import { - AppResiliencyOperations, ContainerAppsAuthConfigs, AvailableWorkloadProfiles, BillingMeters, - Builders, - BuildsByBuilderResource, - Builds, - BuildAuthToken, ConnectedEnvironments, ConnectedEnvironmentsCertificates, ConnectedEnvironmentsDaprComponents, ConnectedEnvironmentsStorages, ContainerApps, - ContainerAppsBuildsByContainerApp, - ContainerAppsBuilds, - ContainerAppsPatches, ContainerAppsRevisions, ContainerAppsRevisionReplicas, ContainerAppsDiagnostics, ManagedEnvironmentDiagnostics, ManagedEnvironmentsDiagnostics, Jobs, - DotNetComponents, - FunctionsExtension, Operations, JavaComponents, JobsExecutions, - LogicApps, ManagedEnvironments, Certificates, ManagedCertificates, Namespaces, - ManagedEnvironmentPrivateEndpointConnections, - ManagedEnvironmentPrivateLinkResources, - DaprComponentResiliencyPolicies, DaprComponents, - DaprSubscriptions, ManagedEnvironmentsStorages, ContainerAppsSessionPools, ContainerAppsSourceControls, @@ -120,7 +90,7 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { /** * Initializes a new instance of the ContainerAppsAPIClient class. * @param credentials Subscription credentials which uniquely identify client subscription. - * @param subscriptionId The ID of the target subscription. The value must be an UUID. + * @param subscriptionId The ID of the target subscription. * @param options The parameter options */ constructor( @@ -144,7 +114,7 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { credential: credentials, }; - const packageDetails = `azsdk-js-arm-appcontainers/2.2.0-beta.2`; + const packageDetails = `azsdk-js-arm-appcontainers/2.2.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -198,15 +168,10 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2024-08-02-preview"; - this.appResiliencyOperations = new AppResiliencyOperationsImpl(this); + this.apiVersion = options.apiVersion || "2025-01-01"; this.containerAppsAuthConfigs = new ContainerAppsAuthConfigsImpl(this); this.availableWorkloadProfiles = new AvailableWorkloadProfilesImpl(this); this.billingMeters = new BillingMetersImpl(this); - this.builders = new BuildersImpl(this); - this.buildsByBuilderResource = new BuildsByBuilderResourceImpl(this); - this.builds = new BuildsImpl(this); - this.buildAuthToken = new BuildAuthTokenImpl(this); this.connectedEnvironments = new ConnectedEnvironmentsImpl(this); this.connectedEnvironmentsCertificates = new ConnectedEnvironmentsCertificatesImpl(this); @@ -216,10 +181,6 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { this, ); this.containerApps = new ContainerAppsImpl(this); - this.containerAppsBuildsByContainerApp = - new ContainerAppsBuildsByContainerAppImpl(this); - this.containerAppsBuilds = new ContainerAppsBuildsImpl(this); - this.containerAppsPatches = new ContainerAppsPatchesImpl(this); this.containerAppsRevisions = new ContainerAppsRevisionsImpl(this); this.containerAppsRevisionReplicas = new ContainerAppsRevisionReplicasImpl( this, @@ -231,24 +192,14 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { this.managedEnvironmentsDiagnostics = new ManagedEnvironmentsDiagnosticsImpl(this); this.jobs = new JobsImpl(this); - this.dotNetComponents = new DotNetComponentsImpl(this); - this.functionsExtension = new FunctionsExtensionImpl(this); this.operations = new OperationsImpl(this); this.javaComponents = new JavaComponentsImpl(this); this.jobsExecutions = new JobsExecutionsImpl(this); - this.logicApps = new LogicAppsImpl(this); this.managedEnvironments = new ManagedEnvironmentsImpl(this); this.certificates = new CertificatesImpl(this); this.managedCertificates = new ManagedCertificatesImpl(this); this.namespaces = new NamespacesImpl(this); - this.managedEnvironmentPrivateEndpointConnections = - new ManagedEnvironmentPrivateEndpointConnectionsImpl(this); - this.managedEnvironmentPrivateLinkResources = - new ManagedEnvironmentPrivateLinkResourcesImpl(this); - this.daprComponentResiliencyPolicies = - new DaprComponentResiliencyPoliciesImpl(this); this.daprComponents = new DaprComponentsImpl(this); - this.daprSubscriptions = new DaprSubscriptionsImpl(this); this.managedEnvironmentsStorages = new ManagedEnvironmentsStoragesImpl( this, ); @@ -321,43 +272,28 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { ); } - appResiliencyOperations: AppResiliencyOperations; containerAppsAuthConfigs: ContainerAppsAuthConfigs; availableWorkloadProfiles: AvailableWorkloadProfiles; billingMeters: BillingMeters; - builders: Builders; - buildsByBuilderResource: BuildsByBuilderResource; - builds: Builds; - buildAuthToken: BuildAuthToken; connectedEnvironments: ConnectedEnvironments; connectedEnvironmentsCertificates: ConnectedEnvironmentsCertificates; connectedEnvironmentsDaprComponents: ConnectedEnvironmentsDaprComponents; connectedEnvironmentsStorages: ConnectedEnvironmentsStorages; containerApps: ContainerApps; - containerAppsBuildsByContainerApp: ContainerAppsBuildsByContainerApp; - containerAppsBuilds: ContainerAppsBuilds; - containerAppsPatches: ContainerAppsPatches; containerAppsRevisions: ContainerAppsRevisions; containerAppsRevisionReplicas: ContainerAppsRevisionReplicas; containerAppsDiagnostics: ContainerAppsDiagnostics; managedEnvironmentDiagnostics: ManagedEnvironmentDiagnostics; managedEnvironmentsDiagnostics: ManagedEnvironmentsDiagnostics; jobs: Jobs; - dotNetComponents: DotNetComponents; - functionsExtension: FunctionsExtension; operations: Operations; javaComponents: JavaComponents; jobsExecutions: JobsExecutions; - logicApps: LogicApps; managedEnvironments: ManagedEnvironments; certificates: Certificates; managedCertificates: ManagedCertificates; namespaces: Namespaces; - managedEnvironmentPrivateEndpointConnections: ManagedEnvironmentPrivateEndpointConnections; - managedEnvironmentPrivateLinkResources: ManagedEnvironmentPrivateLinkResources; - daprComponentResiliencyPolicies: DaprComponentResiliencyPolicies; daprComponents: DaprComponents; - daprSubscriptions: DaprSubscriptions; managedEnvironmentsStorages: ManagedEnvironmentsStorages; containerAppsSessionPools: ContainerAppsSessionPools; containerAppsSourceControls: ContainerAppsSourceControls; diff --git a/sdk/appcontainers/arm-appcontainers/src/lroImpl.ts b/sdk/appcontainers/arm-appcontainers/src/lroImpl.ts index d8bc98987053..5f88efab981b 100644 --- a/sdk/appcontainers/arm-appcontainers/src/lroImpl.ts +++ b/sdk/appcontainers/arm-appcontainers/src/lroImpl.ts @@ -5,6 +5,10 @@ * Code generated by Microsoft (R) AutoRest Code Generator. * 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"; diff --git a/sdk/appcontainers/arm-appcontainers/src/models/index.ts b/sdk/appcontainers/arm-appcontainers/src/models/index.ts index e08884048b4d..3be4516ccb7e 100644 --- a/sdk/appcontainers/arm-appcontainers/src/models/index.ts +++ b/sdk/appcontainers/arm-appcontainers/src/models/index.ts @@ -10,185 +10,10 @@ import * as coreClient from "@azure/core-client"; export type JavaComponentPropertiesUnion = | JavaComponentProperties - | SpringCloudGatewayComponent | SpringBootAdminComponent - | NacosComponent | SpringCloudEurekaComponent | SpringCloudConfigComponent; -/** Policy to set request timeouts */ -export interface TimeoutPolicy { - /** Timeout, in seconds, for a request to respond */ - responseTimeoutInSeconds?: number; - /** Timeout, in seconds, for a request to initiate a connection */ - connectionTimeoutInSeconds?: number; -} - -/** Policy that defines http request retry conditions */ -export interface HttpRetryPolicy { - /** Maximum number of times a request will retry */ - maxRetries?: number; - /** Headers that must be present for a request to be retried */ - headers?: HeaderMatch[]; - /** Additional http status codes that can trigger a retry */ - httpStatusCodes?: number[]; - /** Errors that can trigger a retry */ - errors?: string[]; - /** Initial delay, in milliseconds, before retrying a request */ - initialDelayInMilliseconds?: number; - /** Maximum interval, in milliseconds, between retries */ - maxIntervalInMilliseconds?: number; -} - -/** Conditions required to match a header */ -export interface HeaderMatch { - /** Name of the header */ - header?: string; - /** Exact value of the header */ - exactMatch?: string; - /** Prefix value of the header */ - prefixMatch?: string; - /** Suffix value of the header */ - suffixMatch?: string; - /** Regex value of the header */ - regexMatch?: string; -} - -/** Policy that defines tcp request retry conditions */ -export interface TcpRetryPolicy { - /** Maximum number of attempts to connect to the tcp service */ - maxConnectAttempts?: number; -} - -/** Policy that defines circuit breaker conditions */ -export interface CircuitBreakerPolicy { - /** Number of consecutive errors before the circuit breaker opens */ - consecutiveErrors?: number; - /** The time interval, in seconds, between endpoint checks. This can result in opening the circuit breaker if the check fails as well as closing the circuit breaker if the check succeeds. Defaults to 10s. */ - intervalInSeconds?: number; - /** Maximum percentage of hosts that will be ejected after failure threshold has been met */ - maxEjectionPercent?: number; -} - -/** Defines parameters for http connection pooling */ -export interface HttpConnectionPool { - /** Maximum number of pending http1 requests allowed */ - http1MaxPendingRequests?: number; - /** Maximum number of http2 requests allowed */ - http2MaxRequests?: number; -} - -/** Defines parameters for tcp connection pooling */ -export interface TcpConnectionPool { - /** Maximum number of tcp connections allowed */ - maxConnections?: number; -} - -/** Common fields that are returned in the response for all Azure Resource Manager resources */ -export interface Resource { - /** - * Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; - /** - * The name of the resource - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** - * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * Azure Resource Manager metadata containing createdBy and modifiedBy information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; -} - -/** Metadata pertaining to creation and last modification of the resource. */ -export interface SystemData { - /** The identity that created the resource. */ - createdBy?: string; - /** The type of identity that created the resource. */ - createdByType?: CreatedByType; - /** The timestamp of resource creation (UTC). */ - createdAt?: Date; - /** The identity that last modified the resource. */ - lastModifiedBy?: string; - /** The type of identity that last modified the resource. */ - lastModifiedByType?: CreatedByType; - /** The timestamp of resource last modification (UTC) */ - lastModifiedAt?: Date; -} - -/** App Service error response. */ -export interface DefaultErrorResponse { - /** - * Error model. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly error?: DefaultErrorResponseError; -} - -/** Error model. */ -export interface DefaultErrorResponseError { - /** - * Standardized string to programmatically identify the error. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly code?: string; - /** - * Detailed error description and debugging information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly message?: string; - /** - * Detailed error description and debugging information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly target?: string; - /** Details or the error */ - details?: DefaultErrorResponseErrorDetailsItem[]; - /** - * More information to debug error. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly innererror?: string; -} - -/** Detailed errors. */ -export interface DefaultErrorResponseErrorDetailsItem { - /** - * Standardized string to programmatically identify the error. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly code?: string; - /** - * Detailed error description and debugging information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly message?: string; - /** - * Detailed error description and debugging information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly target?: string; -} - -/** Collection of AppResiliency policies */ -export interface AppResiliencyCollection { - /** Collection of resources. */ - value: AppResiliency[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - /** AuthConfig collection ARM resource. */ export interface AuthConfigCollection { /** Collection of resources. */ @@ -613,6 +438,100 @@ export interface EncryptionSettings { containerAppAuthSigningSecretName?: string; } +/** Common fields that are returned in the response for all Azure Resource Manager resources */ +export interface Resource { + /** + * Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; + /** + * The name of the resource + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * Azure Resource Manager metadata containing createdBy and modifiedBy information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; +} + +/** Metadata pertaining to creation and last modification of the resource. */ +export interface SystemData { + /** The identity that created the resource. */ + createdBy?: string; + /** The type of identity that created the resource. */ + createdByType?: CreatedByType; + /** The timestamp of resource creation (UTC). */ + createdAt?: Date; + /** The identity that last modified the resource. */ + lastModifiedBy?: string; + /** The type of identity that last modified the resource. */ + lastModifiedByType?: CreatedByType; + /** The timestamp of resource last modification (UTC) */ + lastModifiedAt?: Date; +} + +/** App Service error response. */ +export interface DefaultErrorResponse { + /** + * Error model. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly error?: DefaultErrorResponseError; +} + +/** Error model. */ +export interface DefaultErrorResponseError { + /** + * Standardized string to programmatically identify the error. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly code?: string; + /** + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message?: string; + /** + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly target?: string; + /** Details or the error */ + details?: DefaultErrorResponseErrorDetailsItem[]; + /** + * More information to debug error. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly innererror?: string; +} + +/** Detailed errors. */ +export interface DefaultErrorResponseErrorDetailsItem { + /** + * Standardized string to programmatically identify the error. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly code?: string; + /** + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message?: string; + /** + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly target?: string; +} + /** Collection of available workload profiles in the location. */ export interface AvailableWorkloadProfilesCollection { /** Collection of workload profiles. */ @@ -695,34 +614,6 @@ export interface BillingMeterCollection { value: BillingMeter[]; } -/** Billing meter. */ -export interface BillingMeter { - /** - * Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; - /** - * The name of the resource - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** - * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * Azure Resource Manager metadata containing createdBy and modifiedBy information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; - /** Region for the billing meter. */ - location?: string; - /** Revision resource specific properties */ - properties?: BillingMeterProperties; -} - /** Revision resource specific properties */ export interface BillingMeterProperties { /** Used to categorize billing meters. */ @@ -733,170 +624,40 @@ export interface BillingMeterProperties { displayName?: string; } -/** The response of a BuilderResource list operation. */ -export interface BuilderCollection { - /** The BuilderResource items on this page */ - value: BuilderResource[]; - /** The link to the next page of items */ - nextLink?: string; +/** Collection of connectedEnvironments */ +export interface ConnectedEnvironmentCollection { + /** Collection of resources. */ + value?: ConnectedEnvironment[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; } -/** Model representing a mapping from a container registry to the identity used to connect to it. */ -export interface ContainerRegistry { - /** Login server of the container registry. */ - containerRegistryServer: string; - /** Resource ID of the managed identity. */ - identityResourceId: string; +/** The complex type of the extended location. */ +export interface ExtendedLocation { + /** The name of the extended location. */ + name?: string; + /** The type of the extended location. */ + type?: ExtendedLocationTypes; } -/** Managed service identity (system assigned and/or user assigned identities) */ -export interface ManagedServiceIdentity { +/** Configuration properties for apps environment custom domain */ +export interface CustomDomainConfiguration { /** - * The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity. + * Id used to verify domain name ownership * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly principalId?: string; - /** - * The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tenantId?: string; - /** Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed). */ - type: ManagedServiceIdentityType; - /** The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests. */ - userAssignedIdentities?: { [propertyName: string]: UserAssignedIdentity }; -} - -/** User assigned identity properties */ -export interface UserAssignedIdentity { - /** - * The principal ID of the assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The client ID of the assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly clientId?: string; -} - -/** The type used for update operations of the BuilderResource. */ -export interface BuilderResourceUpdate { - /** The managed service identities assigned to this resource. */ - identity?: ManagedServiceIdentity; - /** Resource tags. */ - tags?: { [propertyName: string]: string }; - /** Resource ID of the container apps environment that the builder is associated with. */ - environmentId?: string; -} - -/** The response of a BuildResource list operation. */ -export interface BuildCollection { - /** The BuildResource items on this page */ - value: BuildResource[]; - /** The link to the next page of items */ - nextLink?: string; -} - -/** Container registry that the final image will be uploaded to. */ -export interface ContainerRegistryWithCustomImage { - /** Login server of the container registry that the final image should be uploaded to. Builder resource needs to have this container registry defined along with an identity to use to access it. */ - server: string; - /** Full name that the final image should be uploaded as, including both image name and tag. */ - image?: string; -} - -/** Configuration of the build. */ -export interface BuildConfiguration { - /** Base OS used to build and run the app. */ - baseOs?: string; - /** Platform to be used to build and run the app. */ - platform?: string; - /** Platform version to be used to build and run the app. */ - platformVersion?: string; - /** List of environment variables to be passed to the build, secrets should not be used in environment variable. */ - environmentVariables?: EnvironmentVariable[]; - /** List of steps to perform before the build. */ - preBuildSteps?: PreBuildStep[]; -} - -/** Model representing an environment variable. */ -export interface EnvironmentVariable { - /** Environment variable name. */ - name: string; - /** Environment variable value. */ - value: string; -} - -/** Model representing a pre-build step. */ -export interface PreBuildStep { - /** Description of the pre-build step. */ - description?: string; - /** List of custom commands to run. */ - scripts?: string[]; - /** Http get request to send before the build. */ - httpGet?: HttpGet; -} - -/** Model representing a http get request. */ -export interface HttpGet { - /** URL to make HTTP GET request against. */ - url: string; - /** Name of the file that the request should be saved to. */ - fileName?: string; - /** List of headers to send with the request. */ - headers?: string[]; -} - -/** Build Auth Token. */ -export interface BuildToken { - /** - * Authentication token. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly token?: string; - /** - * Token expiration date. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly expires?: Date; -} - -/** Collection of connectedEnvironments */ -export interface ConnectedEnvironmentCollection { - /** Collection of resources. */ - value?: ConnectedEnvironment[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** The complex type of the extended location. */ -export interface ExtendedLocation { - /** The name of the extended location. */ - name?: string; - /** The type of the extended location. */ - type?: ExtendedLocationTypes; -} - -/** Configuration properties for apps environment custom domain */ -export interface CustomDomainConfiguration { - /** - * Id used to verify domain name ownership - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly customDomainVerificationId?: string; - /** Dns suffix for the environment domain */ - dnsSuffix?: string; - /** Certificate stored in Azure Key Vault. */ - certificateKeyVaultProperties?: CertificateKeyVaultProperties; - /** PFX or PEM blob */ - certificateValue?: Uint8Array; - /** Certificate password */ - certificatePassword?: string; + readonly customDomainVerificationId?: string; + /** Dns suffix for the environment domain */ + dnsSuffix?: string; + /** Certificate stored in Azure Key Vault. */ + certificateKeyVaultProperties?: CertificateKeyVaultProperties; + /** PFX or PEM blob */ + certificateValue?: Uint8Array; + /** Certificate password */ + certificatePassword?: string; /** * Certificate expiration date. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -1004,8 +765,6 @@ export interface CertificateProperties { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly publicKeyHash?: string; - /** The type of the certificate. Allowed values are `ServerSSLCertificate` and `ImagePullTrustedCA` */ - certificateType?: CertificateType; } /** A certificate to update */ @@ -1047,24 +806,6 @@ export interface DaprMetadata { secretRef?: string; } -/** Configuration to bind a Dapr Component to a dev ContainerApp Service */ -export interface DaprComponentServiceBinding { - /** Name of the service bind */ - name?: string; - /** Resource id of the target service */ - serviceId?: string; - /** Service bind metadata */ - metadata?: DaprServiceBindMetadata; -} - -/** Dapr component metadata. */ -export interface DaprServiceBindMetadata { - /** Service bind metadata property name. */ - name?: string; - /** Service bind metadata property value. */ - value?: string; -} - /** Dapr component Secrets Collection for ListSecrets Action. */ export interface DaprSecretsCollection { /** Collection of secrets used by a Dapr component */ @@ -1095,8 +836,6 @@ export interface ConnectedEnvironmentStoragesCollection { export interface ConnectedEnvironmentStorageProperties { /** Azure file properties */ azureFile?: AzureFileProperties; - /** SMB storage properties */ - smb?: SmbStorage; } /** Azure File Properties. */ @@ -1111,22 +850,6 @@ export interface AzureFileProperties { shareName?: string; } -/** SMB storage properties */ -export interface SmbStorage { - /** The host name or IP address of the SMB server. */ - host?: string; - /** The path to the SMB shared folder. */ - shareName?: string; - /** The user to log on to the SMB server. */ - username?: string; - /** The domain name for the user. */ - domain?: string; - /** The password for the user. */ - password?: string; - /** Access mode for storage */ - accessMode?: AccessMode; -} - /** Container App collection ARM resource. */ export interface ContainerAppCollection { /** Collection of resources. */ @@ -1138,10 +861,36 @@ export interface ContainerAppCollection { readonly nextLink?: string; } -/** Container App auto patch configuration. */ -export interface ContainerAppPropertiesPatchingConfiguration { - /** Patching mode for the container app. Null or default in this field will be interpreted as Automatic by RP. Automatic mode will automatically apply available patches. Manual mode will require the user to manually apply patches. Disabled mode will stop patch detection and auto patching. */ - patchingMode?: PatchingMode; +/** Managed service identity (system assigned and/or user assigned identities) */ +export interface ManagedServiceIdentity { + /** + * The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly tenantId?: string; + /** Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed). */ + type: ManagedServiceIdentityType; + /** The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests. */ + userAssignedIdentities?: { [propertyName: string]: UserAssignedIdentity }; +} + +/** User assigned identity properties */ +export interface UserAssignedIdentity { + /** + * The principal ID of the assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The client ID of the assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly clientId?: string; } /** Non versioned Container App configuration properties that define the mutable settings of a Container app */ @@ -1165,8 +914,6 @@ export interface Configuration { maxInactiveRevisions?: number; /** Container App to be a dev Container App Service */ service?: Service; - /** Optional settings for Managed Identities that are assigned to the Container App. If a Managed Identity is not specified here, default settings will be used. */ - identitySettings?: IdentitySettings[]; } /** Container App Ingress configuration. */ @@ -1200,8 +947,6 @@ export interface Ingress { corsPolicy?: CorsPolicy; /** Settings to expose additional ports on container app */ additionalPortMappings?: IngressPortMapping[]; - /** Whether an http app listens on http or https */ - targetPortHttpScheme?: IngressTargetPortHttpScheme; } /** Traffic weight assigned to a revision */ @@ -1306,44 +1051,12 @@ export interface Dapr { export interface Runtime { /** Java app configuration */ java?: RuntimeJava; - /** .NET app configuration */ - dotnet?: RuntimeDotnet; } /** Java app configuration */ export interface RuntimeJava { /** Enable jmx core metrics for the java app */ enableMetrics?: boolean; - /** Diagnostic capabilities achieved by java agent */ - javaAgent?: RuntimeJavaAgent; -} - -/** Diagnostic capabilities achieved by java agent */ -export interface RuntimeJavaAgent { - /** Enable java agent injection for the java app. */ - enabled?: boolean; - /** Capabilities on the java logging scenario. */ - logging?: RuntimeJavaAgentLogging; -} - -/** Capabilities on the java logging scenario. */ -export interface RuntimeJavaAgentLogging { - /** Settings of the logger for the java app. */ - loggerSettings?: LoggerSetting[]; -} - -/** Logger settings for java workloads. */ -export interface LoggerSetting { - /** Logger name. */ - logger: string; - /** The specified logger's log level. */ - level: Level; -} - -/** .NET app configuration */ -export interface RuntimeDotnet { - /** Auto configure the ASP.NET Core Data Protection feature */ - autoConfigureDataProtection?: boolean; } /** Container App to be a dev service */ @@ -1352,14 +1065,6 @@ export interface Service { type: string; } -/** Optional settings for a Managed Identity that is assigned to the Container App. */ -export interface IdentitySettings { - /** The resource ID of a user-assigned managed identity that is assigned to the Container App, or 'system' for system-assigned identity. */ - identity: string; - /** Use to select the lifecycle stages of a Container App during which the Managed Identity should be available. */ - lifecycle?: IdentitySettingsLifeCycle; -} - /** * Container App versioned application definition. * Defines the desired state of an immutable revision. @@ -1386,8 +1091,6 @@ export interface Template { export interface BaseContainer { /** Container image tag. */ image?: string; - /** The type of the image. Set to CloudBuild to let the system manages the image, where user will not be able to update image through image field. Set to ContainerImage for user provided image. */ - imageType?: ImageType; /** Custom container name. */ name?: string; /** Container start command. */ @@ -1493,9 +1196,9 @@ export interface Scale { minReplicas?: number; /** Optional. Maximum number of container replicas. Defaults to 10 if not set. */ maxReplicas?: number; - /** Optional. KEDA Cooldown Period. Defaults to 300 seconds if not set. */ + /** Optional. KEDA Cooldown Period in seconds. Defaults to 300 seconds if not set. */ cooldownPeriod?: number; - /** Optional. KEDA Polling Interval. Defaults to 30 seconds if not set. */ + /** Optional. KEDA Polling Interval in seconds. Defaults to 30 seconds if not set. */ pollingInterval?: number; /** Scaling rules. */ rules?: ScaleRule[]; @@ -1600,10 +1303,6 @@ export interface ServiceBind { serviceId?: string; /** Name of the service bind */ name?: string; - /** Type of the client to be used to connect to the service */ - clientType?: string; - /** Customized keys for customizing injected values to the app */ - customizedKeys?: { [propertyName: string]: string }; } /** Custom domain analysis. */ @@ -1725,151 +1424,6 @@ export interface ContainerAppSecret { readonly keyVaultUrl?: string; } -/** The response of a Container Apps Build Resource list operation. */ -export interface ContainerAppsBuildCollection { - /** The Container Apps Build Resource items on this page */ - value: ContainerAppsBuildResource[]; - /** The link to the next page of items */ - nextLink?: string; -} - -/** Configuration of the build. */ -export interface ContainerAppsBuildConfiguration { - /** - * Base OS used to build and run the app. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly baseOs?: string; - /** - * Platform to be used to build and run the app. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly platform?: string; - /** - * Platform version to be used to build and run the app. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly platformVersion?: string; - /** - * List of environment variables to be passed to the build, secrets should not be used in environment variable. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly environmentVariables?: EnvironmentVariable[]; - /** - * List of steps to perform before the build. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly preBuildSteps?: PreBuildStep[]; -} - -/** Container App patch collection */ -export interface PatchCollection { - /** Collection of patch resources. */ - value: ContainerAppsPatchResource[]; - /** the link to the next page of items */ - nextLink?: string; -} - -/** Top level properties that describes current states of the patch resource */ -export interface PatchProperties { - /** The Azure resource id of the target environment for the patch. */ - targetEnvironmentId?: string; - /** The Azure resource id of the target container app for the patch. */ - targetContainerAppId?: string; - /** The Azure resource id of the target revision for the patch. */ - targetRevisionId?: string; - /** - * The status of the patch operation. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly patchApplyStatus?: PatchApplyStatus; - /** - * The UTC timestamp that describes when the patch object was created. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly createdAt?: Date; - /** - * The UTC timestamp that describes when the patch object was last updated. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly lastModifiedAt?: Date; - /** - * Detailed info describes the patch operation for the target container app. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly patchDetails?: PatchDetails[]; -} - -/** The detailed info of patch operation performing when applying a patch. */ -export interface PatchDetails { - /** - * The name of the target container for the patch. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly targetContainerName: string; - /** - * The name of the target image for the patch. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly targetImage: string; - /** - * The UTC timestamp that describes the latest detection was done. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly lastDetectionTime: Date; - /** - * The status of the patch detection. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly detectionStatus: DetectionStatus; - /** - * The name of the new image created by the patch. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly newImageName?: string; - /** - * New layer update details in the target image. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly newLayer?: PatchDetailsNewLayer; - /** - * The old layer details in the target image. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly oldLayer?: PatchDetailsOldLayer; - /** - * The type for the patch. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly patchType?: PatchType; -} - -/** New layer update details in the target image. */ -export interface PatchDetailsNewLayer { - /** The details of the new layer for the target image. */ - name?: string; - /** The framework and its version in the new run image for the target image. */ - frameworkAndVersion?: string; - /** The OS name and its version in the new run image for the target image. */ - osAndVersion?: string; -} - -/** The old layer details in the target image. */ -export interface PatchDetailsOldLayer { - /** The details of the old layer for the target image. */ - name?: string; - /** The framework and its version in the old run image for the target image. */ - frameworkAndVersion?: string; - /** The OS name and its version in the old run image for the target image. */ - osAndVersion?: string; -} - -/** The configuration for patcher to skip a patch or not. */ -export interface PatchSkipConfig { - /** The flag to indicate whether to skip the patch or not. */ - skip?: boolean; -} - /** Container App Revisions collection ARM resource. */ export interface RevisionCollection { /** Collection of resources. */ @@ -1913,11 +1467,6 @@ export interface ReplicaContainer { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly execEndpoint?: string; - /** - * Container debug endpoint - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly debugEndpoint?: string; } /** Container App Revision Replicas collection ARM resource. */ @@ -2098,92 +1647,12 @@ export interface LogAnalyticsConfiguration { customerId?: string; /** Log analytics customer key */ sharedKey?: string; - /** Boolean indicating whether to parse json string log into dynamic json columns */ - dynamicJsonColumns?: boolean; -} - -/** Configuration of Application Insights */ -export interface AppInsightsConfiguration { - /** Application Insights connection string */ - connectionString?: string; -} - -/** Configuration of Open Telemetry */ -export interface OpenTelemetryConfiguration { - /** Open telemetry destinations configuration */ - destinationsConfiguration?: DestinationsConfiguration; - /** Open telemetry trace configuration */ - tracesConfiguration?: TracesConfiguration; - /** Open telemetry logs configuration */ - logsConfiguration?: LogsConfiguration; - /** Open telemetry metrics configuration */ - metricsConfiguration?: MetricsConfiguration; -} - -/** Configuration of Open Telemetry destinations */ -export interface DestinationsConfiguration { - /** Open telemetry datadog destination configuration */ - dataDogConfiguration?: DataDogConfiguration; - /** Open telemetry otlp configurations */ - otlpConfigurations?: OtlpConfiguration[]; -} - -/** Configuration of datadog */ -export interface DataDogConfiguration { - /** The data dog site */ - site?: string; - /** The data dog api key */ - key?: string; -} - -/** Configuration of otlp */ -export interface OtlpConfiguration { - /** The name of otlp configuration */ - name?: string; - /** The endpoint of otlp configuration */ - endpoint?: string; - /** Boolean indicating if otlp configuration is insecure */ - insecure?: boolean; - /** Headers of otlp configurations */ - headers?: Header[]; -} - -/** Header of otlp configuration */ -export interface Header { - /** The key of otlp configuration header */ - key?: string; - /** The value of otlp configuration header */ - value?: string; -} - -/** Configuration of Open Telemetry traces */ -export interface TracesConfiguration { - /** Boolean indicating if including dapr traces */ - includeDapr?: boolean; - /** Open telemetry traces destinations */ - destinations?: string[]; -} - -/** Configuration of Open Telemetry logs */ -export interface LogsConfiguration { - /** Open telemetry logs destinations */ - destinations?: string[]; -} - -/** Configuration of Open Telemetry metrics */ -export interface MetricsConfiguration { - /** Boolean indicating if including keda metrics */ - includeKeda?: boolean; - /** Open telemetry metrics destinations */ - destinations?: string[]; } /** Workload profile to scope container app execution. */ export interface WorkloadProfile { /** Workload profile type for the workloads to run on. */ name: string; - /** Whether to use a FIPS-enabled OS. Supported only for dedicated workload profiles. */ - enableFips?: boolean; /** Workload profile type for the workloads to run on. */ workloadProfileType: string; /** The minimum capacity. */ @@ -2234,25 +1703,6 @@ export interface ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption enabled?: boolean; } -/** The Private Endpoint resource. */ -export interface PrivateEndpoint { - /** - * The ARM identifier for Private Endpoint - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; -} - -/** A collection of information about the state of the connection between service consumer and provider. */ -export interface PrivateLinkServiceConnectionState { - /** Indicates whether the connection has been Approved/Rejected/Removed by the owner of the service. */ - status?: PrivateEndpointServiceConnectionStatus; - /** The reason for approval/rejection of the connection. */ - description?: string; - /** A message indicating if changes on the service provider require any updates on the consumer. */ - actionsRequired?: string; -} - /** Non versioned Container Apps Job configuration properties */ export interface JobConfiguration { /** Collection of secrets used by a Container Apps Job */ @@ -2271,8 +1721,6 @@ export interface JobConfiguration { eventTriggerConfig?: JobConfigurationEventTriggerConfig; /** Collection of private container registry credentials used by a Container apps job */ registries?: RegistryCredentials[]; - /** Optional settings for Managed Identities that are assigned to the Container App Job. If a Managed Identity is not specified here, default settings will be used. */ - identitySettings?: IdentitySettings[]; } /** Manual trigger configuration for a single execution job. Properties replicaCompletionCount and parallelism would be set to 1 by default */ @@ -2328,7 +1776,7 @@ export interface JobScaleRule { metadata?: Record; /** Authentication secrets for the scale rule. */ auth?: ScaleRuleAuth[]; - /** The resource ID of a user-assigned managed identity that is assigned to the job, or 'system' for system-assigned identity. */ + /** The resource ID of a user-assigned managed identity that is assigned to the Container App, or 'system' for system-assigned identity. */ identity?: string; } @@ -2342,33 +1790,6 @@ export interface JobTemplate { volumes?: Volume[]; } -/** .NET Components ARM resource. */ -export interface DotNetComponentsCollection { - /** Collection of resources. */ - value: DotNetComponent[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Configuration properties for a .NET Component */ -export interface DotNetComponentConfigurationProperty { - /** The name of the property */ - propertyName?: string; - /** The value of the property */ - value?: string; -} - -/** Configuration to bind a .NET Component to another .NET Component */ -export interface DotNetComponentServiceBind { - /** Name of the service bind */ - name?: string; - /** Resource id of the target service */ - serviceId?: string; -} - /** Available operations of the service */ export interface AvailableOperations { /** Collection of available operation details */ @@ -2418,12 +1839,7 @@ export interface JavaComponentsCollection { /** Java Component common properties. */ export interface JavaComponentProperties { /** Polymorphic discriminator, which specifies the different types this object can be */ - componentType: - | "SpringCloudGateway" - | "SpringBootAdmin" - | "Nacos" - | "SpringCloudEureka" - | "SpringCloudConfig"; + componentType: "SpringBootAdmin" | "SpringCloudEureka" | "SpringCloudConfig"; /** * Provisioning state of the Java Component. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -2474,8 +1890,6 @@ export interface JobsCollection { /** Container Apps Job resource specific properties. */ export interface JobPatchProperties { - /** The complex type of the extended location. */ - extendedLocation?: ExtendedLocation; /** Managed identities needed by a container app job to interact with other Azure services to not maintain any secrets or credentials in code. */ identity?: ManagedServiceIdentity; /** Resource tags. */ @@ -2558,34 +1972,6 @@ export interface JobExecution { endTime?: Date; /** Job's execution container. */ template?: JobExecutionTemplate; - /** Detailed status of the job execution. */ - detailedStatus?: ExecutionStatus; -} - -/** Container Apps Job execution status. */ -export interface ExecutionStatus { - /** Replicas in the execution. */ - replicas?: ReplicaExecutionStatus[]; -} - -/** Container Apps Job execution replica status. */ -export interface ReplicaExecutionStatus { - /** Replica Name. */ - name?: string; - /** Containers in the execution replica */ - containers?: ContainerExecutionStatus[]; -} - -/** Container Apps Job execution container status. Contains status code and reason */ -export interface ContainerExecutionStatus { - /** Container Name. */ - name?: string; - /** Exit code */ - code?: number; - /** Additional information for the container status */ - additionalInformation?: string; - /** Status of the container */ - status?: string; } /** Container Apps Job Secrets Collection ARM resource. */ @@ -2594,90 +1980,6 @@ export interface JobSecretsCollection { value: Secret[]; } -/** Collection of 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?: 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; -} - -/** Body of the error response returned from the API. */ -export interface ErrorEntity { - /** Type of error. */ - extendedCode?: string; - /** Message template. */ - messageTemplate?: string; - /** Parameters for the template. */ - parameters?: string[]; - /** Inner errors. */ - innerErrors?: ErrorEntity[]; - /** Error Details. */ - details?: ErrorEntity[]; - /** The error target. */ - target?: string; - /** Basic error code. */ - code?: string; - /** Any details of the error. */ - message?: string; -} - -/** The workflow filter. */ -export interface WorkflowArtifacts { - /** Application settings of the workflow. */ - appSettings?: Record; - /** Files of the app. */ - files?: Record; - /** Files of the app to delete. */ - filesToDelete?: string[]; -} - /** Collection of Environments */ export interface ManagedEnvironmentsCollection { /** Collection of resources. */ @@ -2750,118 +2052,6 @@ export interface WorkloadProfileStatesProperties { currentCount?: number; } -/** List of private endpoint connection associated with the specified resource */ -export interface PrivateEndpointConnectionListResult { - /** Array of private endpoint connections */ - value?: PrivateEndpointConnection[]; - /** - * URL to get the next set of operation list results (if there are any). - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** A list of private link resources */ -export interface PrivateLinkResourceListResult { - /** Array of private link resources */ - value?: PrivateLinkResource[]; - /** - * URL to get the next set of operation list results (if there are any). - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Dapr Component Resiliency Policies ARM resource. */ -export interface DaprComponentResiliencyPoliciesCollection { - /** Collection of resources. */ - value: DaprComponentResiliencyPolicy[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Dapr Component Resiliency Policy Configuration. */ -export interface DaprComponentResiliencyPolicyConfiguration { - /** The optional HTTP retry policy configuration */ - httpRetryPolicy?: DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration; - /** The optional timeout policy configuration */ - timeoutPolicy?: DaprComponentResiliencyPolicyTimeoutPolicyConfiguration; - /** The optional circuit breaker policy configuration */ - circuitBreakerPolicy?: DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration; -} - -/** Dapr Component Resiliency Policy HTTP Retry Policy Configuration. */ -export interface DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration { - /** The optional maximum number of retries */ - maxRetries?: number; - /** The optional retry backoff configuration */ - retryBackOff?: DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration; -} - -/** Dapr Component Resiliency Policy HTTP Retry Backoff Configuration. */ -export interface DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration { - /** The optional initial delay in milliseconds before an operation is retried */ - initialDelayInMilliseconds?: number; - /** The optional maximum time interval in milliseconds between retry attempts */ - maxIntervalInMilliseconds?: number; -} - -/** Dapr Component Resiliency Policy Timeout Policy Configuration. */ -export interface DaprComponentResiliencyPolicyTimeoutPolicyConfiguration { - /** The optional response timeout in seconds */ - responseTimeoutInSeconds?: number; -} - -/** Dapr Component Resiliency Policy Circuit Breaker Policy Configuration. */ -export interface DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration { - /** The number of consecutive errors before the circuit is opened. */ - consecutiveErrors?: number; - /** The interval in seconds until a retry attempt is made after the circuit is opened. */ - timeoutInSeconds?: number; - /** The optional interval in seconds after which the error count resets to 0. An interval of 0 will never reset. If not specified, the timeoutInSeconds value will be used. */ - intervalInSeconds?: number; -} - -/** Dapr Subscriptions ARM resource. */ -export interface DaprSubscriptionsCollection { - /** Collection of resources. */ - value: DaprSubscription[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Dapr PubSub Event Subscription Routes configuration. */ -export interface DaprSubscriptionRoutes { - /** The list of Dapr PubSub Event Subscription Route Rules. */ - rules?: DaprSubscriptionRouteRule[]; - /** The default path to deliver events that do not match any of the rules. */ - default?: string; -} - -/** Dapr Pubsub Event Subscription Route Rule is used to specify the condition for sending a message to a specific path. */ -export interface DaprSubscriptionRouteRule { - /** The optional CEL expression used to match the event. If the match is not specified, then the route is considered the default. The rules are tested in the order specified, so they should be define from most-to-least specific. The default route should appear last in the list. */ - match?: string; - /** The path for events that match this rule */ - path?: string; -} - -/** Dapr PubSub Bulk Subscription Options. */ -export interface DaprSubscriptionBulkSubscribeOptions { - /** Enable bulk subscription */ - enabled?: boolean; - /** Maximum number of messages to deliver in a bulk message. */ - maxMessagesCount?: number; - /** Maximum duration in milliseconds to wait before a bulk message is sent to the app. */ - maxAwaitDurationMs?: number; -} - /** Collection of Storage for Environments */ export interface ManagedEnvironmentStoragesCollection { /** Collection of storage resources. */ @@ -2878,7 +2068,7 @@ export interface ManagedEnvironmentStorageProperties { /** NFS Azure File Properties. */ export interface NfsAzureFileProperties { - /** Server for NFS azure file. */ + /** Server for NFS azure file. Specify the Azure storage account server address. */ server?: string; /** Access mode for storage */ accessMode?: AccessMode; @@ -2915,10 +2105,18 @@ export interface SessionPoolSecret { /** Dynamic pool configuration. */ export interface DynamicPoolConfiguration { - /** The execution type of the session pool. */ - executionType?: ExecutionType; - /** The cooldown period of a session in seconds. */ + /** The lifecycle configuration of a session in the dynamic session pool */ + lifecycleConfiguration?: LifecycleConfiguration; +} + +/** The lifecycle configuration properties of a session in the dynamic session pool */ +export interface LifecycleConfiguration { + /** The lifecycle type of the session pool. */ + lifecycleType?: LifecycleType; + /** The cooldown period of a session in seconds when the lifecycle type is 'Timed'. */ cooldownPeriodInSeconds?: number; + /** The maximum alive period of a session in seconds when the lifecycle type is 'OnContainerExit'. */ + maxAlivePeriodInSeconds?: number; } /** Custom container configuration. */ @@ -2979,8 +2177,20 @@ export interface SessionNetworkConfiguration { status?: SessionNetworkStatus; } +/** Optional settings for a Managed Identity that is assigned to the Session pool. */ +export interface ManagedIdentitySetting { + /** The resource ID of a user-assigned managed identity that is assigned to the Session Pool, or 'system' for system-assigned identity. */ + identity: string; + /** Use to select the lifecycle stages of a Session Pool during which the Managed Identity should be available. */ + lifecycle?: IdentitySettingsLifeCycle; +} + /** Container App session pool updatable properties. */ export interface SessionPoolUpdatableProperties { + /** Resource tags. */ + tags?: { [propertyName: string]: string }; + /** Managed identities needed by a session pool to interact with other Azure services to not maintain any secrets or credentials in code. */ + identity?: ManagedServiceIdentity; /** The scale configuration of the session pool. */ scaleConfiguration?: ScaleConfiguration; /** The secrets of the session pool. */ @@ -3012,8 +2222,6 @@ export interface GithubActionConfiguration { azureCredentials?: AzureCredentials; /** Context path */ contextPath?: string; - /** Dockerfile path */ - dockerfilePath?: string; /** One time Github PAT to configure github environment */ githubPersonalAccessToken?: string; /** Image name */ @@ -3026,8 +2234,6 @@ export interface GithubActionConfiguration { runtimeStack?: string; /** Runtime version */ runtimeVersion?: string; - /** List of environment variables to be passed to the build. */ - buildEnvironmentVariables?: EnvironmentVariable[]; } /** Container App registry information. */ @@ -3081,20 +2287,6 @@ export interface UsageName { localizedValue?: string; } -/** Spring Cloud Gateway route definition */ -export interface ScgRoute { - /** Id of the route */ - id: string; - /** Uri of the route */ - uri: string; - /** Predicates of the route */ - predicates?: string[]; - /** Filters of the route */ - filters?: string[]; - /** Order of the route */ - order?: number; -} - /** Container App Ingress configuration. */ export interface JavaComponentIngress { /** @@ -3121,40 +2313,6 @@ export interface TrackedResource extends Resource { location: string; } -/** The Private Endpoint Connection resource. */ -export interface PrivateEndpointConnection extends Resource { - /** - * The group ids for the private endpoint resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly groupIds?: string[]; - /** The resource of private end point. */ - privateEndpoint?: PrivateEndpoint; - /** A collection of information about the state of the connection between service consumer and provider. */ - privateLinkServiceConnectionState?: PrivateLinkServiceConnectionState; - /** - * The provisioning state of the private endpoint connection resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: PrivateEndpointConnectionProvisioningState; -} - -/** A private link resource */ -export interface PrivateLinkResource extends Resource { - /** - * The private link resource group id. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly groupId?: string; - /** - * The private link resource required member names. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly requiredMembers?: string[]; - /** The private link resource private link DNS zone name. */ - requiredZoneNames?: string[]; -} - /** Container App init container definition */ export interface InitContainer extends BaseContainer {} @@ -3164,16 +2322,6 @@ export interface Container extends BaseContainer { probes?: ContainerAppProbe[]; } -/** Spring Cloud Gateway properties. */ -export interface SpringCloudGatewayComponent extends JavaComponentProperties { - /** Polymorphic discriminator, which specifies the different types this object can be */ - componentType: "SpringCloudGateway"; - /** Java Component Ingress configurations. */ - ingress?: JavaComponentIngress; - /** Gateway route definition */ - springCloudGatewayRoutes?: ScgRoute[]; -} - /** Spring Boot Admin properties. */ export interface SpringBootAdminComponent extends JavaComponentProperties { /** Polymorphic discriminator, which specifies the different types this object can be */ @@ -3182,14 +2330,6 @@ export interface SpringBootAdminComponent extends JavaComponentProperties { ingress?: JavaComponentIngress; } -/** Nacos properties. */ -export interface NacosComponent extends JavaComponentProperties { - /** Polymorphic discriminator, which specifies the different types this object can be */ - componentType: "Nacos"; - /** Java Component Ingress configurations. */ - ingress?: JavaComponentIngress; -} - /** Spring Cloud Eureka properties. */ export interface SpringCloudEurekaComponent extends JavaComponentProperties { /** Polymorphic discriminator, which specifies the different types this object can be */ @@ -3204,22 +2344,6 @@ export interface SpringCloudConfigComponent extends JavaComponentProperties { componentType: "SpringCloudConfig"; } -/** Configuration to setup App Resiliency */ -export interface AppResiliency extends ProxyResource { - /** Policy to set request timeouts */ - timeoutPolicy?: TimeoutPolicy; - /** Policy that defines http request retry conditions */ - httpRetryPolicy?: HttpRetryPolicy; - /** Policy that defines tcp request retry conditions */ - tcpRetryPolicy?: TcpRetryPolicy; - /** Policy that defines circuit breaker conditions */ - circuitBreakerPolicy?: CircuitBreakerPolicy; - /** Defines parameters for http connection pooling */ - httpConnectionPool?: HttpConnectionPool; - /** Defines parameters for tcp connection pooling */ - tcpConnectionPool?: TcpConnectionPool; -} - /** Configuration settings for the Azure ContainerApp Service Authentication / Authorization feature. */ export interface AuthConfig extends ProxyResource { /** The configuration settings of the platform of ContainerApp Service Authentication/Authorization. */ @@ -3244,37 +2368,12 @@ export interface AvailableWorkloadProfile extends ProxyResource { properties?: AvailableWorkloadProfileProperties; } -/** Information pertaining to an individual build. */ -export interface BuildResource extends ProxyResource { - /** - * Build provisioning state. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: BuildProvisioningState; - /** - * Status of the build once it has been provisioned. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly buildStatus?: BuildStatus; - /** Container registry that the final image will be uploaded to. */ - destinationContainerRegistry?: ContainerRegistryWithCustomImage; - /** Configuration of the build. */ - configuration?: BuildConfiguration; - /** - * Endpoint to which the source code should be uploaded. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly uploadEndpoint?: string; - /** - * Endpoint from which the build logs can be streamed. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly logStreamEndpoint?: string; - /** - * Endpoint to use to retrieve an authentication token for log streaming and uploading source code. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tokenEndpoint?: string; +/** Billing meter. */ +export interface BillingMeter extends ProxyResource { + /** Region for the billing meter. */ + location?: string; + /** Revision resource specific properties */ + properties?: BillingMeterProperties; } /** Dapr Component. */ @@ -3295,8 +2394,6 @@ export interface DaprComponent extends ProxyResource { metadata?: DaprMetadata[]; /** Names of container apps that can use this Dapr component */ scopes?: string[]; - /** List of container app services that are bound to the Dapr component */ - serviceComponentBind?: DaprComponentServiceBinding[]; } /** Storage resource for connectedEnvironment. */ @@ -3305,44 +2402,6 @@ export interface ConnectedEnvironmentStorage extends ProxyResource { properties?: ConnectedEnvironmentStorageProperties; } -/** Information pertaining to an individual build. */ -export interface ContainerAppsBuildResource extends ProxyResource { - /** - * Build provisioning state. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: BuildProvisioningState; - /** - * Status of the build once it has been provisioned. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly buildStatus?: BuildStatus; - /** - * Container registry that the final image will be uploaded to. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly destinationContainerRegistry?: ContainerRegistryWithCustomImage; - /** - * Configuration of the build. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly configuration?: ContainerAppsBuildConfiguration; - /** - * Endpoint from which the build logs can be streamed. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly logStreamEndpoint?: string; -} - -/** Container App Patch */ -export interface ContainerAppsPatchResource extends ProxyResource { - /** - * Properties that describes current states of the patch resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly properties?: PatchProperties; -} - /** Container App Revision. */ export interface Revision extends ProxyResource { /** @@ -3434,65 +2493,18 @@ export interface Diagnostics extends ProxyResource { properties?: DiagnosticsProperties; } -/** .NET Component. */ -export interface DotNetComponent extends ProxyResource { - /** Type of the .NET Component. */ - componentType?: DotNetComponentType; - /** - * Provisioning state of the .NET Component. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: DotNetComponentProvisioningState; - /** List of .NET Components configuration properties */ - configurations?: DotNetComponentConfigurationProperty[]; - /** List of .NET Components that are bound to the .NET component */ - serviceBinds?: DotNetComponentServiceBind[]; -} - /** Java Component. */ export interface JavaComponent extends ProxyResource { /** Java Component resource specific properties */ properties?: JavaComponentPropertiesUnion; } -/** A logic app extension resource */ -export interface LogicApp extends ProxyResource { - /** The resource-specific properties for this resource. */ - properties?: Record; -} - /** Collection of all the workload Profile States for a Managed Environment.. */ export interface WorkloadProfileStates extends ProxyResource { /** Workload Profile resource specific properties. */ properties?: WorkloadProfileStatesProperties; } -/** Dapr Component Resiliency Policy. */ -export interface DaprComponentResiliencyPolicy extends ProxyResource { - /** The optional inbound component resiliency policy configuration */ - inboundPolicy?: DaprComponentResiliencyPolicyConfiguration; - /** The optional outbound component resiliency policy configuration */ - outboundPolicy?: DaprComponentResiliencyPolicyConfiguration; -} - -/** Dapr PubSub Event Subscription. */ -export interface DaprSubscription extends ProxyResource { - /** Dapr PubSub component name */ - pubsubName?: string; - /** Topic name */ - topic?: string; - /** Deadletter topic name */ - deadLetterTopic?: string; - /** Subscription routes */ - routes?: DaprSubscriptionRoutes; - /** Application scopes to restrict the subscription to specific apps. */ - scopes?: string[]; - /** Subscription metadata */ - metadata?: { [propertyName: string]: string }; - /** Bulk subscription options */ - bulkSubscribe?: DaprSubscriptionBulkSubscribeOptions; -} - /** Storage resource for managedEnvironment. */ export interface ManagedEnvironmentStorage extends ProxyResource { /** Storage properties */ @@ -3518,21 +2530,6 @@ export interface SourceControl extends ProxyResource { githubActionConfiguration?: GithubActionConfiguration; } -/** Information about the SourceToCloud builder resource. */ -export interface BuilderResource extends TrackedResource { - /** The managed service identities assigned to this resource. */ - identity?: ManagedServiceIdentity; - /** - * Provisioning state of a builder resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: BuilderProvisioningState; - /** Resource ID of the container apps environment that the builder is associated with. */ - environmentId?: string; - /** List of mappings of container registries and the managed identity used to connect to it. */ - containerRegistries?: ContainerRegistry[]; -} - /** An environment for Kubernetes cluster specialized for web workloads by Azure App Service */ export interface ConnectedEnvironment extends TrackedResource { /** The complex type of the extended location. */ @@ -3574,26 +2571,22 @@ export interface ContainerApp extends TrackedResource { identity?: ManagedServiceIdentity; /** The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource. */ managedBy?: string; - /** Metadata used to render different experiences for resources of the same type; e.g. WorkflowApp is a kind of Microsoft.App/ContainerApps type. If supported, the resource provider must validate and persist this value. */ - kind?: Kind; /** * Provisioning state of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: ContainerAppProvisioningState; /** - * Any errors that occurred during deployment + * Running status of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly deploymentErrors?: string; + readonly runningStatus?: ContainerAppRunningStatus; /** Deprecated. Resource ID of the Container App's environment. */ managedEnvironmentId?: string; /** Resource ID of environment. */ environmentId?: string; /** Workload profile name to pin for container app execution. */ workloadProfileName?: string; - /** Container App auto patch configuration. */ - patchingConfiguration?: ContainerAppPropertiesPatchingConfiguration; /** * Name of the latest revision of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -3676,16 +2669,8 @@ export interface ManagedEnvironment extends TrackedResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly staticIp?: string; - /** - * Cluster configuration which enables the log daemon to export - * app logs to a destination. Currently only "log-analytics" is - * supported - */ + /** Cluster configuration which enables the log daemon to export app logs to configured destination. */ appLogsConfiguration?: AppLogsConfiguration; - /** Environment level Application Insights configuration */ - appInsightsConfiguration?: AppInsightsConfiguration; - /** Environment Open Telemetry configuration */ - openTelemetryConfiguration?: OpenTelemetryConfiguration; /** Whether or not this Managed Environment is zone-redundant. */ zoneRedundant?: boolean; /** Custom domain configuration for the environment */ @@ -3707,19 +2692,10 @@ export interface ManagedEnvironment extends TrackedResource { peerAuthentication?: ManagedEnvironmentPropertiesPeerAuthentication; /** Peer traffic settings for the Managed Environment */ peerTrafficConfiguration?: ManagedEnvironmentPropertiesPeerTrafficConfiguration; - /** - * Private endpoint connections to the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly privateEndpointConnections?: PrivateEndpointConnection[]; - /** Property to allow or block all public traffic. Allowed Values: 'Enabled', 'Disabled'. */ - publicNetworkAccess?: PublicNetworkAccess; } /** Container App Job */ export interface Job extends TrackedResource { - /** The complex type of the extended location. */ - extendedLocation?: ExtendedLocation; /** Managed identities needed by a container app job to interact with other Azure services to not maintain any secrets or credentials in code. */ identity?: ManagedServiceIdentity; /** @@ -3727,11 +2703,6 @@ export interface Job extends TrackedResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: JobProvisioningState; - /** - * Current running state of the job - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly runningState?: JobRunningState; /** Resource ID of environment. */ environmentId?: string; /** Workload profile name to pin for container apps job execution. */ @@ -3774,6 +2745,8 @@ export interface EnvironmentAuthToken extends TrackedResource { /** Container App session pool. */ export interface SessionPool extends TrackedResource { + /** Managed identities needed by a session pool to interact with other Azure services to not maintain any secrets or credentials in code. */ + identity?: ManagedServiceIdentity; /** Resource ID of the session pool's environment. */ environmentId?: string; /** The container type of the sessions. */ @@ -3805,31 +2778,8 @@ export interface SessionPool extends TrackedResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: SessionPoolProvisioningState; -} - -/** Defines headers for Builders_createOrUpdate operation. */ -export interface BuildersCreateOrUpdateHeaders { - azureAsyncOperation?: string; -} - -/** Defines headers for Builders_update operation. */ -export interface BuildersUpdateHeaders { - location?: string; -} - -/** Defines headers for Builders_delete operation. */ -export interface BuildersDeleteHeaders { - location?: string; -} - -/** Defines headers for Builds_createOrUpdate operation. */ -export interface BuildsCreateOrUpdateHeaders { - azureAsyncOperation?: string; -} - -/** Defines headers for Builds_delete operation. */ -export interface BuildsDeleteHeaders { - location?: string; + /** Optional settings for a Managed Identity that is assigned to the Session pool. */ + managedIdentitySettings?: ManagedIdentitySetting[]; } /** Defines headers for ConnectedEnvironments_delete operation. */ @@ -3857,27 +2807,6 @@ export interface ContainerAppsStopHeaders { location?: string; } -/** Defines headers for ContainerAppsBuilds_delete operation. */ -export interface ContainerAppsBuildsDeleteHeaders { - location?: string; -} - -/** Defines headers for ContainerAppsPatches_delete operation. */ -export interface ContainerAppsPatchesDeleteHeaders { - location?: string; -} - -/** Defines headers for ContainerAppsPatches_skipConfigure operation. */ -export interface ContainerAppsPatchesSkipConfigureHeaders { - location?: string; -} - -/** Defines headers for ContainerAppsPatches_apply operation. */ -export interface ContainerAppsPatchesApplyHeaders { - azureAsyncOperation?: string; - location?: string; -} - /** Defines headers for Jobs_delete operation. */ export interface JobsDeleteHeaders { location?: string; @@ -3903,50 +2832,23 @@ export interface JobsStopMultipleExecutionsHeaders { location?: string; } -/** Defines headers for Jobs_resume operation. */ -export interface JobsResumeHeaders { - azureAsyncOperation?: string; +/** Defines headers for JavaComponents_update operation. */ +export interface JavaComponentsUpdateHeaders { location?: string; } -/** Defines headers for Jobs_suspend operation. */ -export interface JobsSuspendHeaders { - azureAsyncOperation?: string; +/** Defines headers for JavaComponents_delete operation. */ +export interface JavaComponentsDeleteHeaders { location?: string; } -/** Defines headers for DotNetComponents_update operation. */ -export interface DotNetComponentsUpdateHeaders { +/** Defines headers for ContainerAppsSessionPools_update operation. */ +export interface ContainerAppsSessionPoolsUpdateHeaders { location?: string; } -/** Defines headers for DotNetComponents_delete operation. */ -export interface DotNetComponentsDeleteHeaders { - location?: string; -} - -/** Defines headers for JavaComponents_update operation. */ -export interface JavaComponentsUpdateHeaders { - location?: string; -} - -/** Defines headers for JavaComponents_delete operation. */ -export interface JavaComponentsDeleteHeaders { - location?: string; -} - -/** Defines headers for ManagedEnvironmentPrivateEndpointConnections_delete operation. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders { - location?: string; -} - -/** Defines headers for ContainerAppsSessionPools_update operation. */ -export interface ContainerAppsSessionPoolsUpdateHeaders { - location?: string; -} - -/** Defines headers for ContainerAppsSessionPools_delete operation. */ -export interface ContainerAppsSessionPoolsDeleteHeaders { +/** Defines headers for ContainerAppsSessionPools_delete operation. */ +export interface ContainerAppsSessionPoolsDeleteHeaders { location?: string; } @@ -3992,117 +2894,6 @@ export enum KnownApplicability { */ export type Applicability = string; -/** Known values of {@link BuilderProvisioningState} that the service accepts. */ -export enum KnownBuilderProvisioningState { - /** Succeeded */ - Succeeded = "Succeeded", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** Creating */ - Creating = "Creating", - /** Updating */ - Updating = "Updating", - /** Deleting */ - Deleting = "Deleting", -} - -/** - * Defines values for BuilderProvisioningState. \ - * {@link KnownBuilderProvisioningState} can be used interchangeably with BuilderProvisioningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Succeeded** \ - * **Failed** \ - * **Canceled** \ - * **Creating** \ - * **Updating** \ - * **Deleting** - */ -export type BuilderProvisioningState = string; - -/** Known values of {@link ManagedServiceIdentityType} that the service accepts. */ -export enum KnownManagedServiceIdentityType { - /** None */ - None = "None", - /** SystemAssigned */ - SystemAssigned = "SystemAssigned", - /** UserAssigned */ - UserAssigned = "UserAssigned", - /** SystemAssignedUserAssigned */ - SystemAssignedUserAssigned = "SystemAssigned,UserAssigned", -} - -/** - * Defines values for ManagedServiceIdentityType. \ - * {@link KnownManagedServiceIdentityType} can be used interchangeably with ManagedServiceIdentityType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **None** \ - * **SystemAssigned** \ - * **UserAssigned** \ - * **SystemAssigned,UserAssigned** - */ -export type ManagedServiceIdentityType = string; - -/** Known values of {@link BuildProvisioningState} that the service accepts. */ -export enum KnownBuildProvisioningState { - /** Succeeded */ - Succeeded = "Succeeded", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** Creating */ - Creating = "Creating", - /** Updating */ - Updating = "Updating", - /** Deleting */ - Deleting = "Deleting", -} - -/** - * Defines values for BuildProvisioningState. \ - * {@link KnownBuildProvisioningState} can be used interchangeably with BuildProvisioningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Succeeded** \ - * **Failed** \ - * **Canceled** \ - * **Creating** \ - * **Updating** \ - * **Deleting** - */ -export type BuildProvisioningState = string; - -/** Known values of {@link BuildStatus} that the service accepts. */ -export enum KnownBuildStatus { - /** NotStarted */ - NotStarted = "NotStarted", - /** InProgress */ - InProgress = "InProgress", - /** Succeeded */ - Succeeded = "Succeeded", - /** Canceled */ - Canceled = "Canceled", - /** Failed */ - Failed = "Failed", -} - -/** - * Defines values for BuildStatus. \ - * {@link KnownBuildStatus} can be used interchangeably with BuildStatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotStarted** \ - * **InProgress** \ - * **Succeeded** \ - * **Canceled** \ - * **Failed** - */ -export type BuildStatus = string; - /** Known values of {@link ExtendedLocationTypes} that the service accepts. */ export enum KnownExtendedLocationTypes { /** CustomLocation */ @@ -4199,24 +2990,6 @@ export enum KnownCertificateProvisioningState { */ export type CertificateProvisioningState = string; -/** Known values of {@link CertificateType} that the service accepts. */ -export enum KnownCertificateType { - /** ServerSSLCertificate */ - ServerSSLCertificate = "ServerSSLCertificate", - /** ImagePullTrustedCA */ - ImagePullTrustedCA = "ImagePullTrustedCA", -} - -/** - * Defines values for CertificateType. \ - * {@link KnownCertificateType} can be used interchangeably with CertificateType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **ServerSSLCertificate** \ - * **ImagePullTrustedCA** - */ -export type CertificateType = string; - /** Known values of {@link AccessMode} that the service accepts. */ export enum KnownAccessMode { /** ReadOnly */ @@ -4235,20 +3008,29 @@ export enum KnownAccessMode { */ export type AccessMode = string; -/** Known values of {@link Kind} that the service accepts. */ -export enum KnownKind { - /** Workflowapp */ - Workflowapp = "workflowapp", +/** Known values of {@link ManagedServiceIdentityType} that the service accepts. */ +export enum KnownManagedServiceIdentityType { + /** None */ + None = "None", + /** SystemAssigned */ + SystemAssigned = "SystemAssigned", + /** UserAssigned */ + UserAssigned = "UserAssigned", + /** SystemAssignedUserAssigned */ + SystemAssignedUserAssigned = "SystemAssigned,UserAssigned", } /** - * Defines values for Kind. \ - * {@link KnownKind} can be used interchangeably with Kind, + * Defines values for ManagedServiceIdentityType. \ + * {@link KnownManagedServiceIdentityType} can be used interchangeably with ManagedServiceIdentityType, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **workflowapp** + * **None** \ + * **SystemAssigned** \ + * **UserAssigned** \ + * **SystemAssigned,UserAssigned** */ -export type Kind = string; +export type ManagedServiceIdentityType = string; /** Known values of {@link ContainerAppProvisioningState} that the service accepts. */ export enum KnownContainerAppProvisioningState { @@ -4277,26 +3059,32 @@ export enum KnownContainerAppProvisioningState { */ export type ContainerAppProvisioningState = string; -/** Known values of {@link PatchingMode} that the service accepts. */ -export enum KnownPatchingMode { - /** Automatic */ - Automatic = "Automatic", - /** Manual */ - Manual = "Manual", - /** Disabled */ - Disabled = "Disabled", +/** Known values of {@link ContainerAppRunningStatus} that the service accepts. */ +export enum KnownContainerAppRunningStatus { + /** Container App is transitioning between Stopped and Running states. */ + Progressing = "Progressing", + /** Container App is in Running state. */ + Running = "Running", + /** Container App is in Stopped state. */ + Stopped = "Stopped", + /** Container App Job is in Suspended state. */ + Suspended = "Suspended", + /** Container App Job is in Ready state. */ + Ready = "Ready", } /** - * Defines values for PatchingMode. \ - * {@link KnownPatchingMode} can be used interchangeably with PatchingMode, + * Defines values for ContainerAppRunningStatus. \ + * {@link KnownContainerAppRunningStatus} can be used interchangeably with ContainerAppRunningStatus, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **Automatic** \ - * **Manual** \ - * **Disabled** + * **Progressing**: Container App is transitioning between Stopped and Running states. \ + * **Running**: Container App is in Running state. \ + * **Stopped**: Container App is in Stopped state. \ + * **Suspended**: Container App Job is in Suspended state. \ + * **Ready**: Container App Job is in Ready state. */ -export type PatchingMode = string; +export type ContainerAppRunningStatus = string; /** Known values of {@link ActiveRevisionsMode} that the service accepts. */ export enum KnownActiveRevisionsMode { @@ -4415,24 +3203,6 @@ export enum KnownIngressClientCertificateMode { */ export type IngressClientCertificateMode = string; -/** Known values of {@link IngressTargetPortHttpScheme} that the service accepts. */ -export enum KnownIngressTargetPortHttpScheme { - /** Http */ - Http = "http", - /** Https */ - Https = "https", -} - -/** - * Defines values for IngressTargetPortHttpScheme. \ - * {@link KnownIngressTargetPortHttpScheme} can be used interchangeably with IngressTargetPortHttpScheme, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **http** \ - * **https** - */ -export type IngressTargetPortHttpScheme = string; - /** Known values of {@link AppProtocol} that the service accepts. */ export enum KnownAppProtocol { /** Http */ @@ -4475,78 +3245,6 @@ export enum KnownLogLevel { */ export type LogLevel = string; -/** Known values of {@link Level} that the service accepts. */ -export enum KnownLevel { - /** Off */ - Off = "off", - /** Error */ - Error = "error", - /** Info */ - Info = "info", - /** Debug */ - Debug = "debug", - /** Trace */ - Trace = "trace", - /** Warn */ - Warn = "warn", -} - -/** - * Defines values for Level. \ - * {@link KnownLevel} can be used interchangeably with Level, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **off** \ - * **error** \ - * **info** \ - * **debug** \ - * **trace** \ - * **warn** - */ -export type Level = string; - -/** Known values of {@link IdentitySettingsLifeCycle} that the service accepts. */ -export enum KnownIdentitySettingsLifeCycle { - /** Init */ - Init = "Init", - /** Main */ - Main = "Main", - /** None */ - None = "None", - /** All */ - All = "All", -} - -/** - * Defines values for IdentitySettingsLifeCycle. \ - * {@link KnownIdentitySettingsLifeCycle} can be used interchangeably with IdentitySettingsLifeCycle, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Init** \ - * **Main** \ - * **None** \ - * **All** - */ -export type IdentitySettingsLifeCycle = string; - -/** Known values of {@link ImageType} that the service accepts. */ -export enum KnownImageType { - /** CloudBuild */ - CloudBuild = "CloudBuild", - /** ContainerImage */ - ContainerImage = "ContainerImage", -} - -/** - * Defines values for ImageType. \ - * {@link KnownImageType} can be used interchangeably with ImageType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **CloudBuild** \ - * **ContainerImage** - */ -export type ImageType = string; - /** Known values of {@link Scheme} that the service accepts. */ export enum KnownScheme { /** Http */ @@ -4596,8 +3294,6 @@ export enum KnownStorageType { Secret = "Secret", /** NfsAzureFile */ NfsAzureFile = "NfsAzureFile", - /** Smb */ - Smb = "Smb", } /** @@ -4608,95 +3304,10 @@ export enum KnownStorageType { * **AzureFile** \ * **EmptyDir** \ * **Secret** \ - * **NfsAzureFile** \ - * **Smb** + * **NfsAzureFile** */ export type StorageType = string; -/** Known values of {@link PatchApplyStatus} that the service accepts. */ -export enum KnownPatchApplyStatus { - /** NotStarted */ - NotStarted = "NotStarted", - /** RebaseInProgress */ - RebaseInProgress = "RebaseInProgress", - /** CreatingRevision */ - CreatingRevision = "CreatingRevision", - /** Succeeded */ - Succeeded = "Succeeded", - /** Canceled */ - Canceled = "Canceled", - /** RebaseFailed */ - RebaseFailed = "RebaseFailed", - /** RevisionCreationFailed */ - RevisionCreationFailed = "RevisionCreationFailed", - /** ImagePushPullFailed */ - ImagePushPullFailed = "ImagePushPullFailed", - /** ManuallySkipped */ - ManuallySkipped = "ManuallySkipped", -} - -/** - * Defines values for PatchApplyStatus. \ - * {@link KnownPatchApplyStatus} can be used interchangeably with PatchApplyStatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotStarted** \ - * **RebaseInProgress** \ - * **CreatingRevision** \ - * **Succeeded** \ - * **Canceled** \ - * **RebaseFailed** \ - * **RevisionCreationFailed** \ - * **ImagePushPullFailed** \ - * **ManuallySkipped** - */ -export type PatchApplyStatus = string; - -/** Known values of {@link DetectionStatus} that the service accepts. */ -export enum KnownDetectionStatus { - /** Succeeded */ - Succeeded = "Succeeded", - /** RegistryLoginFailed */ - RegistryLoginFailed = "RegistryLoginFailed", - /** Failed */ - Failed = "Failed", -} - -/** - * Defines values for DetectionStatus. \ - * {@link KnownDetectionStatus} can be used interchangeably with DetectionStatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Succeeded** \ - * **RegistryLoginFailed** \ - * **Failed** - */ -export type DetectionStatus = string; - -/** Known values of {@link PatchType} that the service accepts. */ -export enum KnownPatchType { - /** FrameworkSecurity */ - FrameworkSecurity = "FrameworkSecurity", - /** OSSecurity */ - OSSecurity = "OSSecurity", - /** FrameworkAndOSSecurity */ - FrameworkAndOSSecurity = "FrameworkAndOSSecurity", - /** Other */ - Other = "Other", -} - -/** - * Defines values for PatchType. \ - * {@link KnownPatchType} can be used interchangeably with PatchType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **FrameworkSecurity** \ - * **OSSecurity** \ - * **FrameworkAndOSSecurity** \ - * **Other** - */ -export type PatchType = string; - /** Known values of {@link RevisionHealthState} that the service accepts. */ export enum KnownRevisionHealthState { /** Healthy */ @@ -4859,137 +3470,41 @@ export enum KnownEnvironmentProvisioningState { */ export type EnvironmentProvisioningState = string; -/** Known values of {@link PrivateEndpointServiceConnectionStatus} that the service accepts. */ -export enum KnownPrivateEndpointServiceConnectionStatus { - /** Pending */ - Pending = "Pending", - /** Approved */ - Approved = "Approved", - /** Rejected */ - Rejected = "Rejected", - /** Disconnected */ - Disconnected = "Disconnected", -} - -/** - * Defines values for PrivateEndpointServiceConnectionStatus. \ - * {@link KnownPrivateEndpointServiceConnectionStatus} can be used interchangeably with PrivateEndpointServiceConnectionStatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Pending** \ - * **Approved** \ - * **Rejected** \ - * **Disconnected** - */ -export type PrivateEndpointServiceConnectionStatus = string; - -/** Known values of {@link PrivateEndpointConnectionProvisioningState} that the service accepts. */ -export enum KnownPrivateEndpointConnectionProvisioningState { +/** Known values of {@link JobProvisioningState} that the service accepts. */ +export enum KnownJobProvisioningState { + /** InProgress */ + InProgress = "InProgress", /** Succeeded */ Succeeded = "Succeeded", /** Failed */ Failed = "Failed", /** Canceled */ Canceled = "Canceled", - /** Waiting */ - Waiting = "Waiting", - /** Updating */ - Updating = "Updating", /** Deleting */ Deleting = "Deleting", - /** Pending */ - Pending = "Pending", } /** - * Defines values for PrivateEndpointConnectionProvisioningState. \ - * {@link KnownPrivateEndpointConnectionProvisioningState} can be used interchangeably with PrivateEndpointConnectionProvisioningState, + * Defines values for JobProvisioningState. \ + * {@link KnownJobProvisioningState} can be used interchangeably with JobProvisioningState, * this enum contains the known values that the service supports. * ### Known values supported by the service + * **InProgress** \ * **Succeeded** \ * **Failed** \ * **Canceled** \ - * **Waiting** \ - * **Updating** \ - * **Deleting** \ - * **Pending** + * **Deleting** */ -export type PrivateEndpointConnectionProvisioningState = string; +export type JobProvisioningState = string; -/** Known values of {@link PublicNetworkAccess} that the service accepts. */ -export enum KnownPublicNetworkAccess { - /** Enabled */ - Enabled = "Enabled", - /** Disabled */ - Disabled = "Disabled", -} - -/** - * Defines values for PublicNetworkAccess. \ - * {@link KnownPublicNetworkAccess} can be used interchangeably with PublicNetworkAccess, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Enabled** \ - * **Disabled** - */ -export type PublicNetworkAccess = string; - -/** Known values of {@link JobProvisioningState} that the service accepts. */ -export enum KnownJobProvisioningState { - /** InProgress */ - InProgress = "InProgress", - /** Succeeded */ - Succeeded = "Succeeded", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** Deleting */ - Deleting = "Deleting", -} - -/** - * Defines values for JobProvisioningState. \ - * {@link KnownJobProvisioningState} can be used interchangeably with JobProvisioningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **InProgress** \ - * **Succeeded** \ - * **Failed** \ - * **Canceled** \ - * **Deleting** - */ -export type JobProvisioningState = string; - -/** Known values of {@link JobRunningState} that the service accepts. */ -export enum KnownJobRunningState { - /** Ready */ - Ready = "Ready", - /** Progressing */ - Progressing = "Progressing", - /** Suspended */ - Suspended = "Suspended", -} - -/** - * Defines values for JobRunningState. \ - * {@link KnownJobRunningState} can be used interchangeably with JobRunningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Ready** \ - * **Progressing** \ - * **Suspended** - */ -export type JobRunningState = string; - -/** Known values of {@link TriggerType} that the service accepts. */ -export enum KnownTriggerType { - /** Schedule */ - Schedule = "Schedule", - /** Event */ - Event = "Event", - /** Manual */ - Manual = "Manual", +/** Known values of {@link TriggerType} that the service accepts. */ +export enum KnownTriggerType { + /** Schedule */ + Schedule = "Schedule", + /** Event */ + Event = "Event", + /** Manual */ + Manual = "Manual", } /** @@ -5003,48 +3518,6 @@ export enum KnownTriggerType { */ export type TriggerType = string; -/** Known values of {@link DotNetComponentType} that the service accepts. */ -export enum KnownDotNetComponentType { - /** AspireDashboard */ - AspireDashboard = "AspireDashboard", -} - -/** - * Defines values for DotNetComponentType. \ - * {@link KnownDotNetComponentType} can be used interchangeably with DotNetComponentType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **AspireDashboard** - */ -export type DotNetComponentType = string; - -/** Known values of {@link DotNetComponentProvisioningState} that the service accepts. */ -export enum KnownDotNetComponentProvisioningState { - /** Succeeded */ - Succeeded = "Succeeded", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** Deleting */ - Deleting = "Deleting", - /** InProgress */ - InProgress = "InProgress", -} - -/** - * Defines values for DotNetComponentProvisioningState. \ - * {@link KnownDotNetComponentProvisioningState} can be used interchangeably with DotNetComponentProvisioningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Succeeded** \ - * **Failed** \ - * **Canceled** \ - * **Deleting** \ - * **InProgress** - */ -export type DotNetComponentProvisioningState = string; - /** Known values of {@link JavaComponentType} that the service accepts. */ export enum KnownJavaComponentType { /** SpringBootAdmin */ @@ -5053,10 +3526,6 @@ export enum KnownJavaComponentType { SpringCloudEureka = "SpringCloudEureka", /** SpringCloudConfig */ SpringCloudConfig = "SpringCloudConfig", - /** SpringCloudGateway */ - SpringCloudGateway = "SpringCloudGateway", - /** Nacos */ - Nacos = "Nacos", } /** @@ -5066,9 +3535,7 @@ export enum KnownJavaComponentType { * ### Known values supported by the service * **SpringBootAdmin** \ * **SpringCloudEureka** \ - * **SpringCloudConfig** \ - * **SpringCloudGateway** \ - * **Nacos** + * **SpringCloudConfig** */ export type JavaComponentType = string; @@ -5132,54 +3599,6 @@ export enum KnownJobExecutionRunningState { */ export type JobExecutionRunningState = 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 LogicAppsProxyMethod} that the service accepts. */ -export enum KnownLogicAppsProxyMethod { - /** GET */ - GET = "GET", - /** Post */ - Post = "POST", -} - -/** - * Defines values for LogicAppsProxyMethod. \ - * {@link KnownLogicAppsProxyMethod} can be used interchangeably with LogicAppsProxyMethod, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **GET** \ - * **POST** - */ -export type LogicAppsProxyMethod = string; - /** Known values of {@link ManagedCertificateDomainControlValidation} that the service accepts. */ export enum KnownManagedCertificateDomainControlValidation { /** Cname */ @@ -5237,20 +3656,23 @@ export enum KnownPoolManagementType { */ export type PoolManagementType = string; -/** Known values of {@link ExecutionType} that the service accepts. */ -export enum KnownExecutionType { +/** Known values of {@link LifecycleType} that the service accepts. */ +export enum KnownLifecycleType { /** Timed */ Timed = "Timed", + /** OnContainerExit */ + OnContainerExit = "OnContainerExit", } /** - * Defines values for ExecutionType. \ - * {@link KnownExecutionType} can be used interchangeably with ExecutionType, + * Defines values for LifecycleType. \ + * {@link KnownLifecycleType} can be used interchangeably with LifecycleType, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **Timed** + * **Timed** \ + * **OnContainerExit** */ -export type ExecutionType = string; +export type LifecycleType = string; /** Known values of {@link SessionNetworkStatus} that the service accepts. */ export enum KnownSessionNetworkStatus { @@ -5297,6 +3719,24 @@ export enum KnownSessionPoolProvisioningState { */ export type SessionPoolProvisioningState = string; +/** Known values of {@link IdentitySettingsLifeCycle} that the service accepts. */ +export enum KnownIdentitySettingsLifeCycle { + /** None */ + None = "None", + /** Main */ + Main = "Main", +} + +/** + * Defines values for IdentitySettingsLifeCycle. \ + * {@link KnownIdentitySettingsLifeCycle} can be used interchangeably with IdentitySettingsLifeCycle, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **None** \ + * **Main** + */ +export type IdentitySettingsLifeCycle = string; + /** Known values of {@link SourceControlOperationState} that the service accepts. */ export enum KnownSourceControlOperationState { /** InProgress */ @@ -5334,51 +3774,6 @@ export type CookieExpirationConvention = export type ForwardProxyConvention = "NoProxy" | "Standard" | "Custom"; /** Defines values for DnsVerificationTestResult. */ export type DnsVerificationTestResult = "Passed" | "Failed" | "Skipped"; -/** Defines values for WorkflowHealthState. */ -export type WorkflowHealthState = - | "NotSpecified" - | "Healthy" - | "Unhealthy" - | "Unknown"; - -/** Optional parameters. */ -export interface AppResiliencyCreateOrUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createOrUpdate operation. */ -export type AppResiliencyCreateOrUpdateResponse = AppResiliency; - -/** Optional parameters. */ -export interface AppResiliencyUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the update operation. */ -export type AppResiliencyUpdateResponse = AppResiliency; - -/** Optional parameters. */ -export interface AppResiliencyDeleteOptionalParams - extends coreClient.OperationOptions {} - -/** Optional parameters. */ -export interface AppResiliencyGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type AppResiliencyGetResponse = AppResiliency; - -/** Optional parameters. */ -export interface AppResiliencyListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type AppResiliencyListResponse = AppResiliencyCollection; - -/** Optional parameters. */ -export interface AppResiliencyListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type AppResiliencyListNextResponse = AppResiliencyCollection; /** Optional parameters. */ export interface ContainerAppsAuthConfigsListByContainerAppOptionalParams @@ -5437,128 +3832,6 @@ export interface BillingMetersGetOptionalParams /** Contains response data for the get operation. */ export type BillingMetersGetResponse = BillingMeterCollection; -/** Optional parameters. */ -export interface BuildersListBySubscriptionOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscription operation. */ -export type BuildersListBySubscriptionResponse = BuilderCollection; - -/** Optional parameters. */ -export interface BuildersListByResourceGroupOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroup operation. */ -export type BuildersListByResourceGroupResponse = BuilderCollection; - -/** Optional parameters. */ -export interface BuildersGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type BuildersGetResponse = BuilderResource; - -/** Optional parameters. */ -export interface BuildersCreateOrUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type BuildersCreateOrUpdateResponse = BuilderResource; - -/** Optional parameters. */ -export interface BuildersUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the update operation. */ -export type BuildersUpdateResponse = BuilderResource; - -/** Optional parameters. */ -export interface BuildersDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the delete operation. */ -export type BuildersDeleteResponse = BuildersDeleteHeaders; - -/** Optional parameters. */ -export interface BuildersListBySubscriptionNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscriptionNext operation. */ -export type BuildersListBySubscriptionNextResponse = BuilderCollection; - -/** Optional parameters. */ -export interface BuildersListByResourceGroupNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroupNext operation. */ -export type BuildersListByResourceGroupNextResponse = BuilderCollection; - -/** Optional parameters. */ -export interface BuildsByBuilderResourceListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type BuildsByBuilderResourceListResponse = BuildCollection; - -/** Optional parameters. */ -export interface BuildsByBuilderResourceListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type BuildsByBuilderResourceListNextResponse = BuildCollection; - -/** Optional parameters. */ -export interface BuildsGetOptionalParams extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type BuildsGetResponse = BuildResource; - -/** Optional parameters. */ -export interface BuildsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type BuildsCreateOrUpdateResponse = BuildResource; - -/** Optional parameters. */ -export interface BuildsDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the delete operation. */ -export type BuildsDeleteResponse = BuildsDeleteHeaders; - -/** Optional parameters. */ -export interface BuildAuthTokenListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type BuildAuthTokenListResponse = BuildToken; - /** Optional parameters. */ export interface ConnectedEnvironmentsListBySubscriptionOptionalParams extends coreClient.OperationOptions {} @@ -5778,122 +4051,22 @@ export interface ContainerAppsCreateOrUpdateOptionalParams updateIntervalInMs?: number; /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type ContainerAppsCreateOrUpdateResponse = ContainerApp; - -/** Optional parameters. */ -export interface ContainerAppsDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Optional parameters. */ -export interface ContainerAppsUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the update operation. */ -export type ContainerAppsUpdateResponse = ContainerApp; - -/** Optional parameters. */ -export interface ContainerAppsListCustomHostNameAnalysisOptionalParams - extends coreClient.OperationOptions { - /** Custom hostname. */ - customHostname?: string; -} - -/** Contains response data for the listCustomHostNameAnalysis operation. */ -export type ContainerAppsListCustomHostNameAnalysisResponse = - CustomHostnameAnalysisResult; - -/** Optional parameters. */ -export interface ContainerAppsListSecretsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listSecrets operation. */ -export type ContainerAppsListSecretsResponse = SecretsCollection; - -/** Optional parameters. */ -export interface ContainerAppsGetAuthTokenOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getAuthToken operation. */ -export type ContainerAppsGetAuthTokenResponse = ContainerAppAuthToken; - -/** Optional parameters. */ -export interface ContainerAppsStartOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the start operation. */ -export type ContainerAppsStartResponse = ContainerApp; - -/** Optional parameters. */ -export interface ContainerAppsStopOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the stop operation. */ -export type ContainerAppsStopResponse = ContainerApp; - -/** Optional parameters. */ -export interface ContainerAppsListBySubscriptionNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscriptionNext operation. */ -export type ContainerAppsListBySubscriptionNextResponse = - ContainerAppCollection; - -/** Optional parameters. */ -export interface ContainerAppsListByResourceGroupNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroupNext operation. */ -export type ContainerAppsListByResourceGroupNextResponse = - ContainerAppCollection; - -/** Optional parameters. */ -export interface ContainerAppsBuildsByContainerAppListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type ContainerAppsBuildsByContainerAppListResponse = - ContainerAppsBuildCollection; - -/** Optional parameters. */ -export interface ContainerAppsBuildsByContainerAppListNextOptionalParams - extends coreClient.OperationOptions {} +} -/** Contains response data for the listNext operation. */ -export type ContainerAppsBuildsByContainerAppListNextResponse = - ContainerAppsBuildCollection; +/** Contains response data for the createOrUpdate operation. */ +export type ContainerAppsCreateOrUpdateResponse = ContainerApp; /** Optional parameters. */ -export interface ContainerAppsBuildsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type ContainerAppsBuildsGetResponse = ContainerAppsBuildResource; +export interface ContainerAppsDeleteOptionalParams + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Optional parameters. */ -export interface ContainerAppsBuildsDeleteOptionalParams +export interface ContainerAppsUpdateOptionalParams extends coreClient.OperationOptions { /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; @@ -5901,42 +4074,36 @@ export interface ContainerAppsBuildsDeleteOptionalParams resumeFrom?: string; } -/** Contains response data for the delete operation. */ -export type ContainerAppsBuildsDeleteResponse = - ContainerAppsBuildsDeleteHeaders; +/** Contains response data for the update operation. */ +export type ContainerAppsUpdateResponse = ContainerApp; /** Optional parameters. */ -export interface ContainerAppsPatchesListByContainerAppOptionalParams +export interface ContainerAppsListCustomHostNameAnalysisOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. For example, $filter=properties/patchApplyStatus eq 'Succeeded' */ - filter?: string; + /** Custom hostname. */ + customHostname?: string; } -/** Contains response data for the listByContainerApp operation. */ -export type ContainerAppsPatchesListByContainerAppResponse = PatchCollection; +/** Contains response data for the listCustomHostNameAnalysis operation. */ +export type ContainerAppsListCustomHostNameAnalysisResponse = + CustomHostnameAnalysisResult; /** Optional parameters. */ -export interface ContainerAppsPatchesGetOptionalParams +export interface ContainerAppsListSecretsOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the get operation. */ -export type ContainerAppsPatchesGetResponse = ContainerAppsPatchResource; +/** Contains response data for the listSecrets operation. */ +export type ContainerAppsListSecretsResponse = SecretsCollection; /** Optional parameters. */ -export interface ContainerAppsPatchesDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} +export interface ContainerAppsGetAuthTokenOptionalParams + extends coreClient.OperationOptions {} -/** Contains response data for the delete operation. */ -export type ContainerAppsPatchesDeleteResponse = - ContainerAppsPatchesDeleteHeaders; +/** Contains response data for the getAuthToken operation. */ +export type ContainerAppsGetAuthTokenResponse = ContainerAppAuthToken; /** Optional parameters. */ -export interface ContainerAppsPatchesSkipConfigureOptionalParams +export interface ContainerAppsStartOptionalParams extends coreClient.OperationOptions { /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; @@ -5944,12 +4111,11 @@ export interface ContainerAppsPatchesSkipConfigureOptionalParams resumeFrom?: string; } -/** Contains response data for the skipConfigure operation. */ -export type ContainerAppsPatchesSkipConfigureResponse = - ContainerAppsPatchesSkipConfigureHeaders; +/** Contains response data for the start operation. */ +export type ContainerAppsStartResponse = ContainerApp; /** Optional parameters. */ -export interface ContainerAppsPatchesApplyOptionalParams +export interface ContainerAppsStopOptionalParams extends coreClient.OperationOptions { /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; @@ -5957,16 +4123,24 @@ export interface ContainerAppsPatchesApplyOptionalParams resumeFrom?: string; } -/** Contains response data for the apply operation. */ -export type ContainerAppsPatchesApplyResponse = ContainerAppsPatchResource; +/** Contains response data for the stop operation. */ +export type ContainerAppsStopResponse = ContainerApp; + +/** Optional parameters. */ +export interface ContainerAppsListBySubscriptionNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySubscriptionNext operation. */ +export type ContainerAppsListBySubscriptionNextResponse = + ContainerAppCollection; /** Optional parameters. */ -export interface ContainerAppsPatchesListByContainerAppNextOptionalParams +export interface ContainerAppsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listByContainerAppNext operation. */ -export type ContainerAppsPatchesListByContainerAppNextResponse = - PatchCollection; +/** Contains response data for the listByResourceGroupNext operation. */ +export type ContainerAppsListByResourceGroupNextResponse = + ContainerAppCollection; /** Optional parameters. */ export interface ContainerAppsRevisionsListRevisionsOptionalParams @@ -6210,28 +4384,6 @@ export interface JobsListSecretsOptionalParams /** Contains response data for the listSecrets operation. */ export type JobsListSecretsResponse = JobSecretsCollection; -/** Optional parameters. */ -export interface JobsResumeOptionalParams extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the resume operation. */ -export type JobsResumeResponse = Job; - -/** Optional parameters. */ -export interface JobsSuspendOptionalParams extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the suspend operation. */ -export type JobsSuspendResponse = Job; - /** Optional parameters. */ export interface JobsListDetectorsNextOptionalParams extends coreClient.OperationOptions {} @@ -6253,73 +4405,6 @@ export interface JobsListByResourceGroupNextOptionalParams /** Contains response data for the listByResourceGroupNext operation. */ export type JobsListByResourceGroupNextResponse = JobsCollection; -/** Optional parameters. */ -export interface DotNetComponentsListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type DotNetComponentsListResponse = DotNetComponentsCollection; - -/** Optional parameters. */ -export interface DotNetComponentsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type DotNetComponentsGetResponse = DotNetComponent; - -/** Optional parameters. */ -export interface DotNetComponentsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type DotNetComponentsCreateOrUpdateResponse = DotNetComponent; - -/** Optional parameters. */ -export interface DotNetComponentsUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the update operation. */ -export type DotNetComponentsUpdateResponse = DotNetComponent; - -/** Optional parameters. */ -export interface DotNetComponentsDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the delete operation. */ -export type DotNetComponentsDeleteResponse = DotNetComponentsDeleteHeaders; - -/** Optional parameters. */ -export interface DotNetComponentsListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type DotNetComponentsListNextResponse = DotNetComponentsCollection; - -/** Optional parameters. */ -export interface FunctionsExtensionInvokeFunctionsHostOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the invokeFunctionsHost operation. */ -export type FunctionsExtensionInvokeFunctionsHostResponse = { - /** The parsed response body. */ - body: string; -}; - /** Optional parameters. */ export interface OperationsListOptionalParams extends coreClient.OperationOptions {} @@ -6425,66 +4510,6 @@ export type GetCustomDomainVerificationIdResponse = { body: string; }; -/** Optional parameters. */ -export interface LogicAppsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type LogicAppsGetResponse = LogicApp; - -/** Optional parameters. */ -export interface LogicAppsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createOrUpdate operation. */ -export type LogicAppsCreateOrUpdateResponse = LogicApp; - -/** Optional parameters. */ -export interface LogicAppsDeleteOptionalParams - extends coreClient.OperationOptions {} - -/** Optional parameters. */ -export interface LogicAppsListWorkflowsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listWorkflows operation. */ -export type LogicAppsListWorkflowsResponse = WorkflowEnvelopeCollection; - -/** Optional parameters. */ -export interface LogicAppsGetWorkflowOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getWorkflow operation. */ -export type LogicAppsGetWorkflowResponse = WorkflowEnvelope; - -/** Optional parameters. */ -export interface LogicAppsDeployWorkflowArtifactsOptionalParams - extends coreClient.OperationOptions { - /** Application settings and files of the workflow. */ - workflowArtifacts?: WorkflowArtifacts; -} - -/** Optional parameters. */ -export interface LogicAppsListWorkflowsConnectionsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listWorkflowsConnections operation. */ -export type LogicAppsListWorkflowsConnectionsResponse = WorkflowEnvelope; - -/** Optional parameters. */ -export interface LogicAppsInvokeOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the invoke operation. */ -export type LogicAppsInvokeResponse = Record; - -/** Optional parameters. */ -export interface LogicAppsListWorkflowsNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listWorkflowsNext operation. */ -export type LogicAppsListWorkflowsNextResponse = WorkflowEnvelopeCollection; - /** Optional parameters. */ export interface ManagedEnvironmentsListBySubscriptionOptionalParams extends coreClient.OperationOptions {} @@ -6676,108 +4701,6 @@ export interface NamespacesCheckNameAvailabilityOptionalParams export type NamespacesCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type ManagedEnvironmentPrivateEndpointConnectionsListResponse = - PrivateEndpointConnectionListResult; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type ManagedEnvironmentPrivateEndpointConnectionsGetResponse = - PrivateEndpointConnection; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse = - PrivateEndpointConnection; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the delete operation. */ -export type ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse = - ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateEndpointConnectionsListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type ManagedEnvironmentPrivateEndpointConnectionsListNextResponse = - PrivateEndpointConnectionListResult; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateLinkResourcesListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type ManagedEnvironmentPrivateLinkResourcesListResponse = - PrivateLinkResourceListResult; - -/** Optional parameters. */ -export interface ManagedEnvironmentPrivateLinkResourcesListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type ManagedEnvironmentPrivateLinkResourcesListNextResponse = - PrivateLinkResourceListResult; - -/** Optional parameters. */ -export interface DaprComponentResiliencyPoliciesListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type DaprComponentResiliencyPoliciesListResponse = - DaprComponentResiliencyPoliciesCollection; - -/** Optional parameters. */ -export interface DaprComponentResiliencyPoliciesGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type DaprComponentResiliencyPoliciesGetResponse = - DaprComponentResiliencyPolicy; - -/** Optional parameters. */ -export interface DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createOrUpdate operation. */ -export type DaprComponentResiliencyPoliciesCreateOrUpdateResponse = - DaprComponentResiliencyPolicy; - -/** Optional parameters. */ -export interface DaprComponentResiliencyPoliciesDeleteOptionalParams - extends coreClient.OperationOptions {} - -/** Optional parameters. */ -export interface DaprComponentResiliencyPoliciesListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type DaprComponentResiliencyPoliciesListNextResponse = - DaprComponentResiliencyPoliciesCollection; - /** Optional parameters. */ export interface DaprComponentsListOptionalParams extends coreClient.OperationOptions {} @@ -6817,38 +4740,6 @@ export interface DaprComponentsListNextOptionalParams /** Contains response data for the listNext operation. */ export type DaprComponentsListNextResponse = DaprComponentsCollection; -/** Optional parameters. */ -export interface DaprSubscriptionsListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type DaprSubscriptionsListResponse = DaprSubscriptionsCollection; - -/** Optional parameters. */ -export interface DaprSubscriptionsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type DaprSubscriptionsGetResponse = DaprSubscription; - -/** Optional parameters. */ -export interface DaprSubscriptionsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createOrUpdate operation. */ -export type DaprSubscriptionsCreateOrUpdateResponse = DaprSubscription; - -/** Optional parameters. */ -export interface DaprSubscriptionsDeleteOptionalParams - extends coreClient.OperationOptions {} - -/** Optional parameters. */ -export interface DaprSubscriptionsListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type DaprSubscriptionsListNextResponse = DaprSubscriptionsCollection; - /** Optional parameters. */ export interface ManagedEnvironmentsStoragesListOptionalParams extends coreClient.OperationOptions {} @@ -6970,8 +4861,6 @@ export type ContainerAppsSourceControlsGetResponse = SourceControl; /** Optional parameters. */ export interface ContainerAppsSourceControlsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - /** Github personal access token used for SourceControl. */ - xMsGithubAuxiliary?: string; /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ @@ -6984,12 +4873,6 @@ export type ContainerAppsSourceControlsCreateOrUpdateResponse = SourceControl; /** Optional parameters. */ export interface ContainerAppsSourceControlsDeleteOptionalParams extends coreClient.OperationOptions { - /** Github personal access token used for SourceControl. */ - xMsGithubAuxiliary?: string; - /** Ignore Workflow Deletion Failure. */ - ignoreWorkflowDeletionFailure?: boolean; - /** Delete workflow. */ - deleteWorkflow?: boolean; /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ diff --git a/sdk/appcontainers/arm-appcontainers/src/models/mappers.ts b/sdk/appcontainers/arm-appcontainers/src/models/mappers.ts index 04cec4036b98..a30bf4313e1e 100644 --- a/sdk/appcontainers/arm-appcontainers/src/models/mappers.ts +++ b/sdk/appcontainers/arm-appcontainers/src/models/mappers.ts @@ -8,487 +8,387 @@ import * as coreClient from "@azure/core-client"; -export const TimeoutPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TimeoutPolicy", - modelProperties: { - responseTimeoutInSeconds: { - serializedName: "responseTimeoutInSeconds", - type: { - name: "Number", - }, - }, - connectionTimeoutInSeconds: { - serializedName: "connectionTimeoutInSeconds", - type: { - name: "Number", - }, - }, - }, - }, -}; - -export const HttpRetryPolicy: coreClient.CompositeMapper = { +export const AuthConfigCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "HttpRetryPolicy", + className: "AuthConfigCollection", modelProperties: { - maxRetries: { - serializedName: "maxRetries", - type: { - name: "Number", - }, - }, - headers: { - serializedName: "matches.headers", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "HeaderMatch", - }, - }, - }, - }, - httpStatusCodes: { - serializedName: "matches.httpStatusCodes", - type: { - name: "Sequence", - element: { - type: { - name: "Number", - }, - }, - }, - }, - errors: { - serializedName: "matches.errors", - type: { - name: "Sequence", - element: { - type: { - name: "String", + className: "AuthConfig", }, }, }, }, - initialDelayInMilliseconds: { - serializedName: "retryBackOff.initialDelayInMilliseconds", - type: { - name: "Number", - }, - }, - maxIntervalInMilliseconds: { - serializedName: "retryBackOff.maxIntervalInMilliseconds", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Number", + name: "String", }, }, }, }, }; -export const HeaderMatch: coreClient.CompositeMapper = { +export const AuthPlatform: coreClient.CompositeMapper = { type: { name: "Composite", - className: "HeaderMatch", + className: "AuthPlatform", modelProperties: { - header: { - serializedName: "header", + enabled: { + serializedName: "enabled", type: { - name: "String", + name: "Boolean", }, }, - exactMatch: { - serializedName: "match.exactMatch", + runtimeVersion: { + serializedName: "runtimeVersion", type: { name: "String", }, }, - prefixMatch: { - serializedName: "match.prefixMatch", + }, + }, +}; + +export const GlobalValidation: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "GlobalValidation", + modelProperties: { + unauthenticatedClientAction: { + serializedName: "unauthenticatedClientAction", type: { - name: "String", + name: "Enum", + allowedValues: [ + "RedirectToLoginPage", + "AllowAnonymous", + "Return401", + "Return403", + ], }, }, - suffixMatch: { - serializedName: "match.suffixMatch", + redirectToProvider: { + serializedName: "redirectToProvider", type: { name: "String", }, }, - regexMatch: { - serializedName: "match.regexMatch", + excludedPaths: { + serializedName: "excludedPaths", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, }, }, }; -export const TcpRetryPolicy: coreClient.CompositeMapper = { +export const IdentityProviders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TcpRetryPolicy", + className: "IdentityProviders", modelProperties: { - maxConnectAttempts: { - serializedName: "maxConnectAttempts", + azureActiveDirectory: { + serializedName: "azureActiveDirectory", type: { - name: "Number", + name: "Composite", + className: "AzureActiveDirectory", }, }, - }, - }, -}; - -export const CircuitBreakerPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CircuitBreakerPolicy", - modelProperties: { - consecutiveErrors: { - serializedName: "consecutiveErrors", + facebook: { + serializedName: "facebook", type: { - name: "Number", + name: "Composite", + className: "Facebook", }, }, - intervalInSeconds: { - serializedName: "intervalInSeconds", + gitHub: { + serializedName: "gitHub", type: { - name: "Number", + name: "Composite", + className: "GitHub", }, }, - maxEjectionPercent: { - serializedName: "maxEjectionPercent", + google: { + serializedName: "google", type: { - name: "Number", + name: "Composite", + className: "Google", }, }, - }, - }, -}; - -export const HttpConnectionPool: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "HttpConnectionPool", - modelProperties: { - http1MaxPendingRequests: { - serializedName: "http1MaxPendingRequests", + twitter: { + serializedName: "twitter", type: { - name: "Number", + name: "Composite", + className: "Twitter", }, }, - http2MaxRequests: { - serializedName: "http2MaxRequests", + apple: { + serializedName: "apple", type: { - name: "Number", + name: "Composite", + className: "Apple", }, }, - }, - }, -}; - -export const TcpConnectionPool: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TcpConnectionPool", - modelProperties: { - maxConnections: { - serializedName: "maxConnections", + azureStaticWebApps: { + serializedName: "azureStaticWebApps", type: { - name: "Number", + name: "Composite", + className: "AzureStaticWebApps", + }, + }, + customOpenIdConnectProviders: { + serializedName: "customOpenIdConnectProviders", + type: { + name: "Dictionary", + value: { + type: { + name: "Composite", + className: "CustomOpenIdConnectProvider", + }, + }, }, }, }, }, }; -export const Resource: coreClient.CompositeMapper = { +export const AzureActiveDirectory: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Resource", + className: "AzureActiveDirectory", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + enabled: { + serializedName: "enabled", type: { - name: "String", + name: "Boolean", }, }, - name: { - serializedName: "name", - readOnly: true, + registration: { + serializedName: "registration", type: { - name: "String", + name: "Composite", + className: "AzureActiveDirectoryRegistration", }, }, - type: { - serializedName: "type", - readOnly: true, + login: { + serializedName: "login", type: { - name: "String", + name: "Composite", + className: "AzureActiveDirectoryLogin", }, }, - systemData: { - serializedName: "systemData", + validation: { + serializedName: "validation", type: { name: "Composite", - className: "SystemData", + className: "AzureActiveDirectoryValidation", + }, + }, + isAutoProvisioned: { + serializedName: "isAutoProvisioned", + type: { + name: "Boolean", }, }, }, }, }; -export const SystemData: coreClient.CompositeMapper = { +export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SystemData", + className: "AzureActiveDirectoryRegistration", modelProperties: { - createdBy: { - serializedName: "createdBy", + openIdIssuer: { + serializedName: "openIdIssuer", type: { name: "String", }, }, - createdByType: { - serializedName: "createdByType", + clientId: { + serializedName: "clientId", type: { name: "String", }, }, - createdAt: { - serializedName: "createdAt", + clientSecretSettingName: { + serializedName: "clientSecretSettingName", type: { - name: "DateTime", + name: "String", }, }, - lastModifiedBy: { - serializedName: "lastModifiedBy", + clientSecretCertificateThumbprint: { + serializedName: "clientSecretCertificateThumbprint", type: { name: "String", }, }, - lastModifiedByType: { - serializedName: "lastModifiedByType", + clientSecretCertificateSubjectAlternativeName: { + serializedName: "clientSecretCertificateSubjectAlternativeName", type: { name: "String", }, }, - lastModifiedAt: { - serializedName: "lastModifiedAt", + clientSecretCertificateIssuer: { + serializedName: "clientSecretCertificateIssuer", type: { - name: "DateTime", + name: "String", }, }, }, }, }; -export const DefaultErrorResponse: coreClient.CompositeMapper = { +export const AzureActiveDirectoryLogin: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultErrorResponse", + className: "AzureActiveDirectoryLogin", modelProperties: { - error: { - serializedName: "error", + loginParameters: { + serializedName: "loginParameters", type: { - name: "Composite", - className: "DefaultErrorResponseError", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + disableWWWAuthenticate: { + serializedName: "disableWWWAuthenticate", + type: { + name: "Boolean", }, }, }, }, }; -export const DefaultErrorResponseError: coreClient.CompositeMapper = { +export const AzureActiveDirectoryValidation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultErrorResponseError", + className: "AzureActiveDirectoryValidation", modelProperties: { - code: { - serializedName: "code", - readOnly: true, - type: { - name: "String", - }, - }, - message: { - serializedName: "message", - readOnly: true, - type: { - name: "String", - }, - }, - target: { - serializedName: "target", - readOnly: true, + jwtClaimChecks: { + serializedName: "jwtClaimChecks", type: { - name: "String", + name: "Composite", + className: "JwtClaimChecks", }, }, - details: { - serializedName: "details", + allowedAudiences: { + serializedName: "allowedAudiences", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "DefaultErrorResponseErrorDetailsItem", + name: "String", }, }, }, }, - innererror: { - serializedName: "innererror", - readOnly: true, + defaultAuthorizationPolicy: { + serializedName: "defaultAuthorizationPolicy", type: { - name: "String", + name: "Composite", + className: "DefaultAuthorizationPolicy", }, }, }, }, }; -export const DefaultErrorResponseErrorDetailsItem: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DefaultErrorResponseErrorDetailsItem", - modelProperties: { - code: { - serializedName: "code", - readOnly: true, - type: { - name: "String", - }, - }, - message: { - serializedName: "message", - readOnly: true, - type: { - name: "String", - }, - }, - target: { - serializedName: "target", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, - }; - -export const AppResiliencyCollection: coreClient.CompositeMapper = { +export const JwtClaimChecks: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AppResiliencyCollection", + className: "JwtClaimChecks", modelProperties: { - value: { - serializedName: "value", - required: true, + allowedGroups: { + serializedName: "allowedGroups", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "AppResiliency", + name: "String", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const AuthConfigCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AuthConfigCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + allowedClientApplications: { + serializedName: "allowedClientApplications", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "AuthConfig", + name: "String", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, }, }, }; -export const AuthPlatform: coreClient.CompositeMapper = { +export const DefaultAuthorizationPolicy: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AuthPlatform", + className: "DefaultAuthorizationPolicy", modelProperties: { - enabled: { - serializedName: "enabled", + allowedPrincipals: { + serializedName: "allowedPrincipals", type: { - name: "Boolean", + name: "Composite", + className: "AllowedPrincipals", }, }, - runtimeVersion: { - serializedName: "runtimeVersion", + allowedApplications: { + serializedName: "allowedApplications", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, }, }, }; -export const GlobalValidation: coreClient.CompositeMapper = { +export const AllowedPrincipals: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GlobalValidation", + className: "AllowedPrincipals", modelProperties: { - unauthenticatedClientAction: { - serializedName: "unauthenticatedClientAction", - type: { - name: "Enum", - allowedValues: [ - "RedirectToLoginPage", - "AllowAnonymous", - "Return401", - "Return403", - ], - }, - }, - redirectToProvider: { - serializedName: "redirectToProvider", + groups: { + serializedName: "groups", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - excludedPaths: { - serializedName: "excludedPaths", + identities: { + serializedName: "identities", type: { name: "Sequence", element: { @@ -502,68 +402,74 @@ export const GlobalValidation: coreClient.CompositeMapper = { }, }; -export const IdentityProviders: coreClient.CompositeMapper = { +export const Facebook: coreClient.CompositeMapper = { type: { name: "Composite", - className: "IdentityProviders", + className: "Facebook", modelProperties: { - azureActiveDirectory: { - serializedName: "azureActiveDirectory", - type: { - name: "Composite", - className: "AzureActiveDirectory", - }, - }, - facebook: { - serializedName: "facebook", + enabled: { + serializedName: "enabled", type: { - name: "Composite", - className: "Facebook", + name: "Boolean", }, }, - gitHub: { - serializedName: "gitHub", + registration: { + serializedName: "registration", type: { name: "Composite", - className: "GitHub", + className: "AppRegistration", }, }, - google: { - serializedName: "google", + graphApiVersion: { + serializedName: "graphApiVersion", type: { - name: "Composite", - className: "Google", + name: "String", }, }, - twitter: { - serializedName: "twitter", + login: { + serializedName: "login", type: { name: "Composite", - className: "Twitter", + className: "LoginScopes", }, }, - apple: { - serializedName: "apple", + }, + }, +}; + +export const AppRegistration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AppRegistration", + modelProperties: { + appId: { + serializedName: "appId", type: { - name: "Composite", - className: "Apple", + name: "String", }, }, - azureStaticWebApps: { - serializedName: "azureStaticWebApps", + appSecretSettingName: { + serializedName: "appSecretSettingName", type: { - name: "Composite", - className: "AzureStaticWebApps", + name: "String", }, }, - customOpenIdConnectProviders: { - serializedName: "customOpenIdConnectProviders", + }, + }, +}; + +export const LoginScopes: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "LoginScopes", + modelProperties: { + scopes: { + serializedName: "scopes", type: { - name: "Dictionary", - value: { + name: "Sequence", + element: { type: { - name: "Composite", - className: "CustomOpenIdConnectProvider", + name: "String", }, }, }, @@ -572,10 +478,10 @@ export const IdentityProviders: coreClient.CompositeMapper = { }, }; -export const AzureActiveDirectory: coreClient.CompositeMapper = { +export const GitHub: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectory", + className: "GitHub", modelProperties: { enabled: { serializedName: "enabled", @@ -587,44 +493,25 @@ export const AzureActiveDirectory: coreClient.CompositeMapper = { serializedName: "registration", type: { name: "Composite", - className: "AzureActiveDirectoryRegistration", + className: "ClientRegistration", }, }, login: { serializedName: "login", type: { name: "Composite", - className: "AzureActiveDirectoryLogin", - }, - }, - validation: { - serializedName: "validation", - type: { - name: "Composite", - className: "AzureActiveDirectoryValidation", - }, - }, - isAutoProvisioned: { - serializedName: "isAutoProvisioned", - type: { - name: "Boolean", + className: "LoginScopes", }, }, }, }, }; -export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { +export const ClientRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectoryRegistration", + className: "ClientRegistration", modelProperties: { - openIdIssuer: { - serializedName: "openIdIssuer", - type: { - name: "String", - }, - }, clientId: { serializedName: "clientId", type: { @@ -637,106 +524,53 @@ export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { name: "String", }, }, - clientSecretCertificateThumbprint: { - serializedName: "clientSecretCertificateThumbprint", - type: { - name: "String", - }, - }, - clientSecretCertificateSubjectAlternativeName: { - serializedName: "clientSecretCertificateSubjectAlternativeName", - type: { - name: "String", - }, - }, - clientSecretCertificateIssuer: { - serializedName: "clientSecretCertificateIssuer", - type: { - name: "String", - }, - }, }, }, }; -export const AzureActiveDirectoryLogin: coreClient.CompositeMapper = { +export const Google: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectoryLogin", + className: "Google", modelProperties: { - loginParameters: { - serializedName: "loginParameters", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - disableWWWAuthenticate: { - serializedName: "disableWWWAuthenticate", + enabled: { + serializedName: "enabled", type: { name: "Boolean", }, }, - }, - }, -}; - -export const AzureActiveDirectoryValidation: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AzureActiveDirectoryValidation", - modelProperties: { - jwtClaimChecks: { - serializedName: "jwtClaimChecks", + registration: { + serializedName: "registration", type: { name: "Composite", - className: "JwtClaimChecks", + className: "ClientRegistration", }, }, - allowedAudiences: { - serializedName: "allowedAudiences", + login: { + serializedName: "login", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "Composite", + className: "LoginScopes", }, }, - defaultAuthorizationPolicy: { - serializedName: "defaultAuthorizationPolicy", + validation: { + serializedName: "validation", type: { name: "Composite", - className: "DefaultAuthorizationPolicy", + className: "AllowedAudiencesValidation", }, }, }, }, }; -export const JwtClaimChecks: coreClient.CompositeMapper = { +export const AllowedAudiencesValidation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JwtClaimChecks", + className: "AllowedAudiencesValidation", modelProperties: { - allowedGroups: { - serializedName: "allowedGroups", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - allowedClientApplications: { - serializedName: "allowedClientApplications", + allowedAudiences: { + serializedName: "allowedAudiences", type: { name: "Sequence", element: { @@ -750,68 +584,53 @@ export const JwtClaimChecks: coreClient.CompositeMapper = { }, }; -export const DefaultAuthorizationPolicy: coreClient.CompositeMapper = { +export const Twitter: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultAuthorizationPolicy", + className: "Twitter", modelProperties: { - allowedPrincipals: { - serializedName: "allowedPrincipals", + enabled: { + serializedName: "enabled", type: { - name: "Composite", - className: "AllowedPrincipals", + name: "Boolean", }, }, - allowedApplications: { - serializedName: "allowedApplications", + registration: { + serializedName: "registration", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "Composite", + className: "TwitterRegistration", }, }, }, }, }; -export const AllowedPrincipals: coreClient.CompositeMapper = { +export const TwitterRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AllowedPrincipals", + className: "TwitterRegistration", modelProperties: { - groups: { - serializedName: "groups", + consumerKey: { + serializedName: "consumerKey", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - identities: { - serializedName: "identities", + consumerSecretSettingName: { + serializedName: "consumerSecretSettingName", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, }, }, }; -export const Facebook: coreClient.CompositeMapper = { +export const Apple: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Facebook", + className: "Apple", modelProperties: { enabled: { serializedName: "enabled", @@ -823,13 +642,7 @@ export const Facebook: coreClient.CompositeMapper = { serializedName: "registration", type: { name: "Composite", - className: "AppRegistration", - }, - }, - graphApiVersion: { - serializedName: "graphApiVersion", - type: { - name: "String", + className: "AppleRegistration", }, }, login: { @@ -843,19 +656,19 @@ export const Facebook: coreClient.CompositeMapper = { }, }; -export const AppRegistration: coreClient.CompositeMapper = { +export const AppleRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AppRegistration", + className: "AppleRegistration", modelProperties: { - appId: { - serializedName: "appId", + clientId: { + serializedName: "clientId", type: { name: "String", }, }, - appSecretSettingName: { - serializedName: "appSecretSettingName", + clientSecretSettingName: { + serializedName: "clientSecretSettingName", type: { name: "String", }, @@ -864,30 +677,10 @@ export const AppRegistration: coreClient.CompositeMapper = { }, }; -export const LoginScopes: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "LoginScopes", - modelProperties: { - scopes: { - serializedName: "scopes", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - }, - }, -}; - -export const GitHub: coreClient.CompositeMapper = { +export const AzureStaticWebApps: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GitHub", + className: "AzureStaticWebApps", modelProperties: { enabled: { serializedName: "enabled", @@ -899,24 +692,17 @@ export const GitHub: coreClient.CompositeMapper = { serializedName: "registration", type: { name: "Composite", - className: "ClientRegistration", - }, - }, - login: { - serializedName: "login", - type: { - name: "Composite", - className: "LoginScopes", + className: "AzureStaticWebAppsRegistration", }, }, }, }, }; -export const ClientRegistration: coreClient.CompositeMapper = { +export const AzureStaticWebAppsRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ClientRegistration", + className: "AzureStaticWebAppsRegistration", modelProperties: { clientId: { serializedName: "clientId", @@ -924,20 +710,14 @@ export const ClientRegistration: coreClient.CompositeMapper = { name: "String", }, }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", - type: { - name: "String", - }, - }, }, }, }; -export const Google: coreClient.CompositeMapper = { +export const CustomOpenIdConnectProvider: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Google", + className: "CustomOpenIdConnectProvider", modelProperties: { enabled: { serializedName: "enabled", @@ -949,215 +729,29 @@ export const Google: coreClient.CompositeMapper = { serializedName: "registration", type: { name: "Composite", - className: "ClientRegistration", + className: "OpenIdConnectRegistration", }, }, login: { serializedName: "login", type: { name: "Composite", - className: "LoginScopes", - }, - }, - validation: { - serializedName: "validation", - type: { - name: "Composite", - className: "AllowedAudiencesValidation", + className: "OpenIdConnectLogin", }, }, }, }, }; -export const AllowedAudiencesValidation: coreClient.CompositeMapper = { +export const OpenIdConnectRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AllowedAudiencesValidation", + className: "OpenIdConnectRegistration", modelProperties: { - allowedAudiences: { - serializedName: "allowedAudiences", + clientId: { + serializedName: "clientId", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - }, - }, -}; - -export const Twitter: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Twitter", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "TwitterRegistration", - }, - }, - }, - }, -}; - -export const TwitterRegistration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TwitterRegistration", - modelProperties: { - consumerKey: { - serializedName: "consumerKey", - type: { - name: "String", - }, - }, - consumerSecretSettingName: { - serializedName: "consumerSecretSettingName", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const Apple: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Apple", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "AppleRegistration", - }, - }, - login: { - serializedName: "login", - type: { - name: "Composite", - className: "LoginScopes", - }, - }, - }, - }, -}; - -export const AppleRegistration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AppleRegistration", - modelProperties: { - clientId: { - serializedName: "clientId", - type: { - name: "String", - }, - }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const AzureStaticWebApps: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AzureStaticWebApps", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "AzureStaticWebAppsRegistration", - }, - }, - }, - }, -}; - -export const AzureStaticWebAppsRegistration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AzureStaticWebAppsRegistration", - modelProperties: { - clientId: { - serializedName: "clientId", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const CustomOpenIdConnectProvider: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CustomOpenIdConnectProvider", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "OpenIdConnectRegistration", - }, - }, - login: { - serializedName: "login", - type: { - name: "Composite", - className: "OpenIdConnectLogin", - }, - }, - }, - }, -}; - -export const OpenIdConnectRegistration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "OpenIdConnectRegistration", - modelProperties: { - clientId: { - serializedName: "clientId", - type: { - name: "String", + name: "String", }, }, clientCredential: { @@ -1515,100 +1109,108 @@ export const EncryptionSettings: coreClient.CompositeMapper = { }, }; -export const AvailableWorkloadProfilesCollection: coreClient.CompositeMapper = { +export const Resource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AvailableWorkloadProfilesCollection", + className: "Resource", modelProperties: { - value: { - serializedName: "value", - required: true, + id: { + serializedName: "id", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "AvailableWorkloadProfile", - }, - }, + name: "String", }, }, - nextLink: { - serializedName: "nextLink", + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String", + }, + }, + type: { + serializedName: "type", readOnly: true, type: { name: "String", }, }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData", + }, + }, }, }, }; -export const AvailableWorkloadProfileProperties: coreClient.CompositeMapper = { +export const SystemData: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AvailableWorkloadProfileProperties", + className: "SystemData", modelProperties: { - category: { - serializedName: "category", + createdBy: { + serializedName: "createdBy", type: { name: "String", }, }, - applicability: { - serializedName: "applicability", + createdByType: { + serializedName: "createdByType", type: { name: "String", }, }, - cores: { - serializedName: "cores", + createdAt: { + serializedName: "createdAt", type: { - name: "Number", + name: "DateTime", }, }, - memoryGiB: { - serializedName: "memoryGiB", + lastModifiedBy: { + serializedName: "lastModifiedBy", type: { - name: "Number", + name: "String", }, }, - gpus: { - serializedName: "gpus", + lastModifiedByType: { + serializedName: "lastModifiedByType", type: { - name: "Number", + name: "String", }, }, - displayName: { - serializedName: "displayName", + lastModifiedAt: { + serializedName: "lastModifiedAt", type: { - name: "String", + name: "DateTime", }, }, }, }, }; -export const ErrorResponse: coreClient.CompositeMapper = { +export const DefaultErrorResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorResponse", + className: "DefaultErrorResponse", modelProperties: { error: { serializedName: "error", type: { name: "Composite", - className: "ErrorDetail", + className: "DefaultErrorResponseError", }, }, }, }, }; -export const ErrorDetail: coreClient.CompositeMapper = { +export const DefaultErrorResponseError: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorDetail", + className: "DefaultErrorResponseError", modelProperties: { code: { serializedName: "code", @@ -1633,124 +1235,244 @@ export const ErrorDetail: coreClient.CompositeMapper = { }, details: { serializedName: "details", - readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorDetail", + className: "DefaultErrorResponseErrorDetailsItem", }, }, }, }, - additionalInfo: { - serializedName: "additionalInfo", + innererror: { + serializedName: "innererror", readOnly: true, + type: { + name: "String", + }, + }, + }, + }, +}; + +export const DefaultErrorResponseErrorDetailsItem: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "DefaultErrorResponseErrorDetailsItem", + modelProperties: { + code: { + serializedName: "code", + readOnly: true, + type: { + name: "String", + }, + }, + message: { + serializedName: "message", + readOnly: true, + type: { + name: "String", + }, + }, + target: { + serializedName: "target", + readOnly: true, + type: { + name: "String", + }, + }, + }, + }, + }; + +export const AvailableWorkloadProfilesCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AvailableWorkloadProfilesCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorAdditionalInfo", + className: "AvailableWorkloadProfile", }, }, }, }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String", + }, + }, }, }, }; -export const ErrorAdditionalInfo: coreClient.CompositeMapper = { +export const AvailableWorkloadProfileProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorAdditionalInfo", + className: "AvailableWorkloadProfileProperties", modelProperties: { - type: { - serializedName: "type", - readOnly: true, + category: { + serializedName: "category", type: { name: "String", }, }, - info: { - serializedName: "info", - readOnly: true, + applicability: { + serializedName: "applicability", type: { - name: "Dictionary", - value: { type: { name: "any" } }, + name: "String", + }, + }, + cores: { + serializedName: "cores", + type: { + name: "Number", + }, + }, + memoryGiB: { + serializedName: "memoryGiB", + type: { + name: "Number", + }, + }, + gpus: { + serializedName: "gpus", + type: { + name: "Number", + }, + }, + displayName: { + serializedName: "displayName", + type: { + name: "String", }, }, }, }, }; -export const BillingMeterCollection: coreClient.CompositeMapper = { +export const ErrorResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BillingMeterCollection", + className: "ErrorResponse", modelProperties: { - value: { - serializedName: "value", - required: true, + error: { + serializedName: "error", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "BillingMeter", - }, - }, + name: "Composite", + className: "ErrorDetail", }, }, }, }, }; -export const BillingMeter: coreClient.CompositeMapper = { +export const ErrorDetail: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BillingMeter", + className: "ErrorDetail", modelProperties: { - id: { - serializedName: "id", + code: { + serializedName: "code", readOnly: true, type: { name: "String", }, }, - name: { - serializedName: "name", + message: { + serializedName: "message", readOnly: true, type: { name: "String", }, }, - type: { - serializedName: "type", + target: { + serializedName: "target", readOnly: true, type: { name: "String", }, }, - systemData: { - serializedName: "systemData", + details: { + serializedName: "details", + readOnly: true, type: { - name: "Composite", - className: "SystemData", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorDetail", + }, + }, }, }, - location: { - serializedName: "location", + additionalInfo: { + serializedName: "additionalInfo", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, +}; + +export const ErrorAdditionalInfo: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ErrorAdditionalInfo", + modelProperties: { + type: { + serializedName: "type", + readOnly: true, type: { name: "String", }, }, - properties: { - serializedName: "properties", + info: { + serializedName: "info", + readOnly: true, type: { - name: "Composite", - className: "BillingMeterProperties", + name: "Dictionary", + value: { type: { name: "any" } }, + }, + }, + }, + }, +}; + +export const BillingMeterCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BillingMeterCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "BillingMeter", + }, + }, }, }, }, @@ -1784,26 +1506,26 @@ export const BillingMeterProperties: coreClient.CompositeMapper = { }, }; -export const BuilderCollection: coreClient.CompositeMapper = { +export const ConnectedEnvironmentCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BuilderCollection", + className: "ConnectedEnvironmentCollection", modelProperties: { value: { serializedName: "value", - required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "BuilderResource", + className: "ConnectedEnvironment", }, }, }, }, nextLink: { serializedName: "nextLink", + readOnly: true, type: { name: "String", }, @@ -1812,21 +1534,19 @@ export const BuilderCollection: coreClient.CompositeMapper = { }, }; -export const ContainerRegistry: coreClient.CompositeMapper = { +export const ExtendedLocation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerRegistry", + className: "ExtendedLocation", modelProperties: { - containerRegistryServer: { - serializedName: "containerRegistryServer", - required: true, + name: { + serializedName: "name", type: { name: "String", }, }, - identityResourceId: { - serializedName: "identityResourceId", - required: true, + type: { + serializedName: "type", type: { name: "String", }, @@ -1835,89 +1555,60 @@ export const ContainerRegistry: coreClient.CompositeMapper = { }, }; -export const ManagedServiceIdentity: coreClient.CompositeMapper = { +export const CustomDomainConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedServiceIdentity", + className: "CustomDomainConfiguration", modelProperties: { - principalId: { - serializedName: "principalId", + customDomainVerificationId: { + serializedName: "customDomainVerificationId", readOnly: true, type: { - name: "Uuid", + name: "String", }, }, - tenantId: { - serializedName: "tenantId", - readOnly: true, + dnsSuffix: { + serializedName: "dnsSuffix", type: { - name: "Uuid", + name: "String", }, }, - type: { - serializedName: "type", - required: true, + certificateKeyVaultProperties: { + serializedName: "certificateKeyVaultProperties", type: { - name: "String", + name: "Composite", + className: "CertificateKeyVaultProperties", }, }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", + certificateValue: { + serializedName: "certificateValue", type: { - name: "Dictionary", - value: { - type: { name: "Composite", className: "UserAssignedIdentity" }, - }, + name: "ByteArray", }, }, - }, - }, -}; - -export const UserAssignedIdentity: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "UserAssignedIdentity", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, + certificatePassword: { + serializedName: "certificatePassword", type: { - name: "Uuid", + name: "String", }, }, - clientId: { - serializedName: "clientId", + expirationDate: { + serializedName: "expirationDate", readOnly: true, type: { - name: "Uuid", - }, - }, - }, - }, -}; - -export const BuilderResourceUpdate: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuilderResourceUpdate", - modelProperties: { - identity: { - serializedName: "identity", - type: { - name: "Composite", - className: "ManagedServiceIdentity", + name: "DateTime", }, }, - tags: { - serializedName: "tags", + thumbprint: { + serializedName: "thumbprint", + readOnly: true, type: { - name: "Dictionary", - value: { type: { name: "String" } }, + name: "String", }, }, - environmentId: { - serializedName: "properties.environmentId", + subjectName: { + serializedName: "subjectName", + readOnly: true, type: { name: "String", }, @@ -1926,26 +1617,19 @@ export const BuilderResourceUpdate: coreClient.CompositeMapper = { }, }; -export const BuildCollection: coreClient.CompositeMapper = { +export const CertificateKeyVaultProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BuildCollection", + className: "CertificateKeyVaultProperties", modelProperties: { - value: { - serializedName: "value", - required: true, + identity: { + serializedName: "identity", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "BuildResource", - }, - }, + name: "String", }, }, - nextLink: { - serializedName: "nextLink", + keyVaultUrl: { + serializedName: "keyVaultUrl", type: { name: "String", }, @@ -1954,20 +1638,19 @@ export const BuildCollection: coreClient.CompositeMapper = { }, }; -export const ContainerRegistryWithCustomImage: coreClient.CompositeMapper = { +export const CheckNameAvailabilityRequest: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerRegistryWithCustomImage", + className: "CheckNameAvailabilityRequest", modelProperties: { - server: { - serializedName: "server", - required: true, + name: { + serializedName: "name", type: { name: "String", }, }, - image: { - serializedName: "image", + type: { + serializedName: "type", type: { name: "String", }, @@ -1976,93 +1659,97 @@ export const ContainerRegistryWithCustomImage: coreClient.CompositeMapper = { }, }; -export const BuildConfiguration: coreClient.CompositeMapper = { +export const CheckNameAvailabilityResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BuildConfiguration", + className: "CheckNameAvailabilityResponse", modelProperties: { - baseOs: { - serializedName: "baseOs", + nameAvailable: { + serializedName: "nameAvailable", type: { - name: "String", + name: "Boolean", }, }, - platform: { - serializedName: "platform", + reason: { + serializedName: "reason", type: { name: "String", }, }, - platformVersion: { - serializedName: "platformVersion", + message: { + serializedName: "message", type: { name: "String", }, }, - environmentVariables: { - serializedName: "environmentVariables", + }, + }, +}; + +export const CertificateCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "CertificateCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "EnvironmentVariable", + className: "Certificate", }, }, }, }, - preBuildSteps: { - serializedName: "preBuildSteps", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PreBuildStep", - }, - }, + name: "String", }, }, }, }, }; -export const EnvironmentVariable: coreClient.CompositeMapper = { +export const CertificateProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "EnvironmentVariable", + className: "CertificateProperties", modelProperties: { - name: { - serializedName: "name", - required: true, + provisioningState: { + serializedName: "provisioningState", + readOnly: true, type: { name: "String", }, }, - value: { - serializedName: "value", - required: true, + certificateKeyVaultProperties: { + serializedName: "certificateKeyVaultProperties", + type: { + name: "Composite", + className: "CertificateKeyVaultProperties", + }, + }, + password: { + serializedName: "password", type: { name: "String", }, }, - }, - }, -}; - -export const PreBuildStep: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PreBuildStep", - modelProperties: { - description: { - serializedName: "description", + subjectName: { + serializedName: "subjectName", + readOnly: true, type: { name: "String", }, }, - scripts: { - serializedName: "scripts", + subjectAlternativeNames: { + serializedName: "subjectAlternativeNames", + readOnly: true, type: { name: "Sequence", element: { @@ -2072,86 +1759,88 @@ export const PreBuildStep: coreClient.CompositeMapper = { }, }, }, - httpGet: { - serializedName: "httpGet", + value: { + serializedName: "value", type: { - name: "Composite", - className: "HttpGet", + name: "ByteArray", }, }, - }, - }, -}; - -export const HttpGet: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "HttpGet", - modelProperties: { - url: { - serializedName: "url", - required: true, + issuer: { + serializedName: "issuer", + readOnly: true, type: { name: "String", }, }, - fileName: { - serializedName: "fileName", + issueDate: { + serializedName: "issueDate", + readOnly: true, + type: { + name: "DateTime", + }, + }, + expirationDate: { + serializedName: "expirationDate", + readOnly: true, + type: { + name: "DateTime", + }, + }, + thumbprint: { + serializedName: "thumbprint", + readOnly: true, type: { name: "String", }, }, - headers: { - serializedName: "headers", + valid: { + serializedName: "valid", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "Boolean", + }, + }, + publicKeyHash: { + serializedName: "publicKeyHash", + readOnly: true, + type: { + name: "String", }, }, }, }, }; -export const BuildToken: coreClient.CompositeMapper = { +export const CertificatePatch: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BuildToken", + className: "CertificatePatch", modelProperties: { - token: { - serializedName: "token", - readOnly: true, - type: { - name: "String", - }, - }, - expires: { - serializedName: "expires", - readOnly: true, + tags: { + serializedName: "tags", type: { - name: "DateTime", + name: "Dictionary", + value: { type: { name: "String" } }, }, }, }, }, }; -export const ConnectedEnvironmentCollection: coreClient.CompositeMapper = { +export const DaprComponentsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ConnectedEnvironmentCollection", + className: "DaprComponentsCollection", modelProperties: { value: { serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ConnectedEnvironment", + className: "DaprComponent", }, }, }, @@ -2167,10 +1856,10 @@ export const ConnectedEnvironmentCollection: coreClient.CompositeMapper = { }, }; -export const ExtendedLocation: coreClient.CompositeMapper = { +export const Secret: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ExtendedLocation", + className: "Secret", modelProperties: { name: { serializedName: "name", @@ -2178,8 +1867,20 @@ export const ExtendedLocation: coreClient.CompositeMapper = { name: "String", }, }, - type: { - serializedName: "type", + value: { + serializedName: "value", + type: { + name: "String", + }, + }, + identity: { + serializedName: "identity", + type: { + name: "String", + }, + }, + keyVaultUrl: { + serializedName: "keyVaultUrl", type: { name: "String", }, @@ -2188,102 +1889,70 @@ export const ExtendedLocation: coreClient.CompositeMapper = { }, }; -export const CustomDomainConfiguration: coreClient.CompositeMapper = { +export const DaprMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomDomainConfiguration", + className: "DaprMetadata", modelProperties: { - customDomainVerificationId: { - serializedName: "customDomainVerificationId", - readOnly: true, + name: { + serializedName: "name", type: { name: "String", }, }, - dnsSuffix: { - serializedName: "dnsSuffix", + value: { + serializedName: "value", type: { name: "String", }, }, - certificateKeyVaultProperties: { - serializedName: "certificateKeyVaultProperties", + secretRef: { + serializedName: "secretRef", type: { - name: "Composite", - className: "CertificateKeyVaultProperties", - }, - }, - certificateValue: { - serializedName: "certificateValue", - type: { - name: "ByteArray", - }, - }, - certificatePassword: { - serializedName: "certificatePassword", - type: { - name: "String", - }, - }, - expirationDate: { - serializedName: "expirationDate", - readOnly: true, - type: { - name: "DateTime", - }, - }, - thumbprint: { - serializedName: "thumbprint", - readOnly: true, - type: { - name: "String", - }, - }, - subjectName: { - serializedName: "subjectName", - readOnly: true, - type: { - name: "String", + name: "String", }, }, }, }, }; -export const CertificateKeyVaultProperties: coreClient.CompositeMapper = { +export const DaprSecretsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificateKeyVaultProperties", + className: "DaprSecretsCollection", modelProperties: { - identity: { - serializedName: "identity", - type: { - name: "String", - }, - }, - keyVaultUrl: { - serializedName: "keyVaultUrl", + value: { + serializedName: "value", + required: true, type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DaprSecret", + }, + }, }, }, }, }, }; -export const CheckNameAvailabilityRequest: coreClient.CompositeMapper = { +export const DaprSecret: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CheckNameAvailabilityRequest", + className: "DaprSecret", modelProperties: { name: { serializedName: "name", + readOnly: true, type: { name: "String", }, }, - type: { - serializedName: "type", + value: { + serializedName: "value", + readOnly: true, type: { name: "String", }, @@ -2292,25 +1961,71 @@ export const CheckNameAvailabilityRequest: coreClient.CompositeMapper = { }, }; -export const CheckNameAvailabilityResponse: coreClient.CompositeMapper = { +export const ConnectedEnvironmentStoragesCollection: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ConnectedEnvironmentStoragesCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ConnectedEnvironmentStorage", + }, + }, + }, + }, + }, + }, + }; + +export const ConnectedEnvironmentStorageProperties: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ConnectedEnvironmentStorageProperties", + modelProperties: { + azureFile: { + serializedName: "azureFile", + type: { + name: "Composite", + className: "AzureFileProperties", + }, + }, + }, + }, + }; + +export const AzureFileProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CheckNameAvailabilityResponse", + className: "AzureFileProperties", modelProperties: { - nameAvailable: { - serializedName: "nameAvailable", + accountName: { + serializedName: "accountName", type: { - name: "Boolean", + name: "String", }, }, - reason: { - serializedName: "reason", + accountKey: { + serializedName: "accountKey", type: { name: "String", }, }, - message: { - serializedName: "message", + accessMode: { + serializedName: "accessMode", + type: { + name: "String", + }, + }, + shareName: { + serializedName: "shareName", type: { name: "String", }, @@ -2319,10 +2034,10 @@ export const CheckNameAvailabilityResponse: coreClient.CompositeMapper = { }, }; -export const CertificateCollection: coreClient.CompositeMapper = { +export const ContainerAppCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificateCollection", + className: "ContainerAppCollection", modelProperties: { value: { serializedName: "value", @@ -2332,7 +2047,7 @@ export const CertificateCollection: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Certificate", + className: "ContainerApp", }, }, }, @@ -2348,178 +2063,285 @@ export const CertificateCollection: coreClient.CompositeMapper = { }, }; -export const CertificateProperties: coreClient.CompositeMapper = { +export const ManagedServiceIdentity: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificateProperties", + className: "ManagedServiceIdentity", modelProperties: { - provisioningState: { - serializedName: "provisioningState", + principalId: { + serializedName: "principalId", readOnly: true, type: { - name: "String", + name: "Uuid", }, }, - certificateKeyVaultProperties: { - serializedName: "certificateKeyVaultProperties", + tenantId: { + serializedName: "tenantId", + readOnly: true, type: { - name: "Composite", - className: "CertificateKeyVaultProperties", + name: "Uuid", }, }, - password: { - serializedName: "password", + type: { + serializedName: "type", + required: true, type: { name: "String", }, }, - subjectName: { - serializedName: "subjectName", + userAssignedIdentities: { + serializedName: "userAssignedIdentities", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "UserAssignedIdentity" }, + }, + }, + }, + }, + }, +}; + +export const UserAssignedIdentity: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "UserAssignedIdentity", + modelProperties: { + principalId: { + serializedName: "principalId", readOnly: true, type: { - name: "String", + name: "Uuid", }, }, - subjectAlternativeNames: { - serializedName: "subjectAlternativeNames", + clientId: { + serializedName: "clientId", readOnly: true, + type: { + name: "Uuid", + }, + }, + }, + }, +}; + +export const Configuration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Configuration", + modelProperties: { + secrets: { + serializedName: "secrets", type: { name: "Sequence", element: { type: { - name: "String", + name: "Composite", + className: "Secret", }, }, }, }, - value: { - serializedName: "value", + activeRevisionsMode: { + defaultValue: "Single", + serializedName: "activeRevisionsMode", type: { - name: "ByteArray", + name: "String", }, }, - issuer: { - serializedName: "issuer", - readOnly: true, + ingress: { + serializedName: "ingress", type: { - name: "String", + name: "Composite", + className: "Ingress", }, }, - issueDate: { - serializedName: "issueDate", - readOnly: true, + registries: { + serializedName: "registries", type: { - name: "DateTime", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RegistryCredentials", + }, + }, }, }, - expirationDate: { - serializedName: "expirationDate", - readOnly: true, + dapr: { + serializedName: "dapr", type: { - name: "DateTime", + name: "Composite", + className: "Dapr", }, }, - thumbprint: { - serializedName: "thumbprint", - readOnly: true, + runtime: { + serializedName: "runtime", type: { - name: "String", + name: "Composite", + className: "Runtime", }, }, - valid: { - serializedName: "valid", - readOnly: true, + maxInactiveRevisions: { + serializedName: "maxInactiveRevisions", type: { - name: "Boolean", + name: "Number", }, }, - publicKeyHash: { - serializedName: "publicKeyHash", - readOnly: true, - type: { - name: "String", - }, - }, - certificateType: { - serializedName: "certificateType", + service: { + serializedName: "service", type: { - name: "String", + name: "Composite", + className: "Service", }, }, }, }, }; -export const CertificatePatch: coreClient.CompositeMapper = { +export const Ingress: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificatePatch", + className: "Ingress", modelProperties: { - tags: { - serializedName: "tags", + fqdn: { + serializedName: "fqdn", + readOnly: true, type: { - name: "Dictionary", - value: { type: { name: "String" } }, + name: "String", }, }, - }, - }, -}; - -export const DaprComponentsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprComponentsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + external: { + defaultValue: false, + serializedName: "external", + type: { + name: "Boolean", + }, + }, + targetPort: { + serializedName: "targetPort", + type: { + name: "Number", + }, + }, + exposedPort: { + serializedName: "exposedPort", + type: { + name: "Number", + }, + }, + transport: { + defaultValue: "auto", + serializedName: "transport", + type: { + name: "String", + }, + }, + traffic: { + serializedName: "traffic", type: { name: "Sequence", element: { type: { name: "Composite", - className: "DaprComponent", + className: "TrafficWeight", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + customDomains: { + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "CustomDomain", + }, + }, + }, + }, + allowInsecure: { + defaultValue: false, + serializedName: "allowInsecure", + type: { + name: "Boolean", + }, + }, + ipSecurityRestrictions: { + serializedName: "ipSecurityRestrictions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IpSecurityRestrictionRule", + }, + }, + }, + }, + stickySessions: { + serializedName: "stickySessions", + type: { + name: "Composite", + className: "IngressStickySessions", + }, + }, + clientCertificateMode: { + serializedName: "clientCertificateMode", type: { name: "String", }, }, + corsPolicy: { + serializedName: "corsPolicy", + type: { + name: "Composite", + className: "CorsPolicy", + }, + }, + additionalPortMappings: { + serializedName: "additionalPortMappings", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IngressPortMapping", + }, + }, + }, + }, }, }, }; -export const Secret: coreClient.CompositeMapper = { +export const TrafficWeight: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Secret", + className: "TrafficWeight", modelProperties: { - name: { - serializedName: "name", + revisionName: { + serializedName: "revisionName", type: { name: "String", }, }, - value: { - serializedName: "value", + weight: { + serializedName: "weight", type: { - name: "String", + name: "Number", }, }, - identity: { - serializedName: "identity", + latestRevision: { + defaultValue: false, + serializedName: "latestRevision", type: { - name: "String", + name: "Boolean", }, }, - keyVaultUrl: { - serializedName: "keyVaultUrl", + label: { + serializedName: "label", type: { name: "String", }, @@ -2528,25 +2350,26 @@ export const Secret: coreClient.CompositeMapper = { }, }; -export const DaprMetadata: coreClient.CompositeMapper = { +export const CustomDomain: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprMetadata", + className: "CustomDomain", modelProperties: { name: { serializedName: "name", + required: true, type: { name: "String", }, }, - value: { - serializedName: "value", + bindingType: { + serializedName: "bindingType", type: { name: "String", }, }, - secretRef: { - serializedName: "secretRef", + certificateId: { + serializedName: "certificateId", type: { name: "String", }, @@ -2555,47 +2378,49 @@ export const DaprMetadata: coreClient.CompositeMapper = { }, }; -export const DaprComponentServiceBinding: coreClient.CompositeMapper = { +export const IpSecurityRestrictionRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprComponentServiceBinding", + className: "IpSecurityRestrictionRule", modelProperties: { name: { serializedName: "name", + required: true, type: { name: "String", }, }, - serviceId: { - serializedName: "serviceId", + description: { + serializedName: "description", type: { name: "String", }, }, - metadata: { - serializedName: "metadata", + ipAddressRange: { + serializedName: "ipAddressRange", + required: true, type: { - name: "Composite", - className: "DaprServiceBindMetadata", + name: "String", + }, + }, + action: { + serializedName: "action", + required: true, + type: { + name: "String", }, }, }, }, }; -export const DaprServiceBindMetadata: coreClient.CompositeMapper = { +export const IngressStickySessions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprServiceBindMetadata", + className: "IngressStickySessions", modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - value: { - serializedName: "value", + affinity: { + serializedName: "affinity", type: { name: "String", }, @@ -2604,123 +2429,126 @@ export const DaprServiceBindMetadata: coreClient.CompositeMapper = { }, }; -export const DaprSecretsCollection: coreClient.CompositeMapper = { +export const CorsPolicy: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprSecretsCollection", + className: "CorsPolicy", modelProperties: { - value: { - serializedName: "value", + allowedOrigins: { + serializedName: "allowedOrigins", required: true, type: { name: "Sequence", element: { type: { - name: "Composite", - className: "DaprSecret", + name: "String", }, }, }, }, - }, - }, -}; - -export const DaprSecret: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprSecret", - modelProperties: { - name: { - serializedName: "name", - readOnly: true, + allowedMethods: { + serializedName: "allowedMethods", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - value: { - serializedName: "value", - readOnly: true, + allowedHeaders: { + serializedName: "allowedHeaders", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - }, - }, -}; - -export const ConnectedEnvironmentStoragesCollection: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ConnectedEnvironmentStoragesCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ConnectedEnvironmentStorage", - }, + exposeHeaders: { + serializedName: "exposeHeaders", + type: { + name: "Sequence", + element: { + type: { + name: "String", }, }, }, }, + maxAge: { + serializedName: "maxAge", + type: { + name: "Number", + }, + }, + allowCredentials: { + serializedName: "allowCredentials", + type: { + name: "Boolean", + }, + }, }, - }; + }, +}; -export const ConnectedEnvironmentStorageProperties: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ConnectedEnvironmentStorageProperties", - modelProperties: { - azureFile: { - serializedName: "azureFile", - type: { - name: "Composite", - className: "AzureFileProperties", - }, +export const IngressPortMapping: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IngressPortMapping", + modelProperties: { + external: { + serializedName: "external", + required: true, + type: { + name: "Boolean", }, - smb: { - serializedName: "smb", - type: { - name: "Composite", - className: "SmbStorage", - }, + }, + targetPort: { + serializedName: "targetPort", + required: true, + type: { + name: "Number", + }, + }, + exposedPort: { + serializedName: "exposedPort", + type: { + name: "Number", }, }, }, - }; + }, +}; -export const AzureFileProperties: coreClient.CompositeMapper = { +export const RegistryCredentials: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureFileProperties", + className: "RegistryCredentials", modelProperties: { - accountName: { - serializedName: "accountName", + server: { + serializedName: "server", type: { name: "String", }, }, - accountKey: { - serializedName: "accountKey", + username: { + serializedName: "username", type: { name: "String", }, }, - accessMode: { - serializedName: "accessMode", + passwordSecretRef: { + serializedName: "passwordSecretRef", type: { name: "String", }, }, - shareName: { - serializedName: "shareName", + identity: { + serializedName: "identity", type: { name: "String", }, @@ -2729,174 +2557,180 @@ export const AzureFileProperties: coreClient.CompositeMapper = { }, }; -export const SmbStorage: coreClient.CompositeMapper = { +export const Dapr: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SmbStorage", + className: "Dapr", modelProperties: { - host: { - serializedName: "host", + enabled: { + defaultValue: false, + serializedName: "enabled", type: { - name: "String", + name: "Boolean", }, }, - shareName: { - serializedName: "shareName", + appId: { + serializedName: "appId", type: { name: "String", }, }, - username: { - serializedName: "username", + appProtocol: { + defaultValue: "http", + serializedName: "appProtocol", type: { name: "String", }, }, - domain: { - serializedName: "domain", + appPort: { + serializedName: "appPort", type: { - name: "String", + name: "Number", }, }, - password: { - serializedName: "password", + httpReadBufferSize: { + serializedName: "httpReadBufferSize", type: { - name: "String", + name: "Number", }, }, - accessMode: { - serializedName: "accessMode", + httpMaxRequestSize: { + serializedName: "httpMaxRequestSize", + type: { + name: "Number", + }, + }, + logLevel: { + serializedName: "logLevel", type: { name: "String", }, }, + enableApiLogging: { + serializedName: "enableApiLogging", + type: { + name: "Boolean", + }, + }, }, }, }; -export const ContainerAppCollection: coreClient.CompositeMapper = { +export const Runtime: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppCollection", + className: "Runtime", modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerApp", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + java: { + serializedName: "java", type: { - name: "String", + name: "Composite", + className: "RuntimeJava", }, }, }, }, }; -export const ContainerAppPropertiesPatchingConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ContainerAppPropertiesPatchingConfiguration", - modelProperties: { - patchingMode: { - serializedName: "patchingMode", - type: { - name: "String", - }, +export const RuntimeJava: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "RuntimeJava", + modelProperties: { + enableMetrics: { + serializedName: "enableMetrics", + type: { + name: "Boolean", }, }, }, - }; + }, +}; -export const Configuration: coreClient.CompositeMapper = { +export const Service: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Configuration", + className: "Service", modelProperties: { - secrets: { - serializedName: "secrets", + type: { + serializedName: "type", + required: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Secret", - }, - }, + name: "String", }, }, - activeRevisionsMode: { - defaultValue: "Single", - serializedName: "activeRevisionsMode", + }, + }, +}; + +export const Template: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Template", + modelProperties: { + revisionSuffix: { + serializedName: "revisionSuffix", type: { name: "String", }, }, - ingress: { - serializedName: "ingress", + terminationGracePeriodSeconds: { + serializedName: "terminationGracePeriodSeconds", type: { - name: "Composite", - className: "Ingress", + name: "Number", }, }, - registries: { - serializedName: "registries", + initContainers: { + serializedName: "initContainers", type: { name: "Sequence", element: { type: { name: "Composite", - className: "RegistryCredentials", + className: "InitContainer", }, }, }, }, - dapr: { - serializedName: "dapr", - type: { - name: "Composite", - className: "Dapr", - }, - }, - runtime: { - serializedName: "runtime", - type: { - name: "Composite", - className: "Runtime", - }, - }, - maxInactiveRevisions: { - serializedName: "maxInactiveRevisions", + containers: { + serializedName: "containers", type: { - name: "Number", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Container", + }, + }, }, }, - service: { - serializedName: "service", + scale: { + serializedName: "scale", type: { name: "Composite", - className: "Service", + className: "Scale", }, }, - identitySettings: { - serializedName: "identitySettings", + volumes: { + serializedName: "volumes", type: { name: "Sequence", element: { type: { name: "Composite", - className: "IdentitySettings", + className: "Volume", + }, + }, + }, + }, + serviceBinds: { + serializedName: "serviceBinds", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ServiceBind", }, }, }, @@ -2905,155 +2739,99 @@ export const Configuration: coreClient.CompositeMapper = { }, }; -export const Ingress: coreClient.CompositeMapper = { +export const BaseContainer: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Ingress", + className: "BaseContainer", modelProperties: { - fqdn: { - serializedName: "fqdn", - readOnly: true, + image: { + serializedName: "image", type: { name: "String", }, }, - external: { - defaultValue: false, - serializedName: "external", - type: { - name: "Boolean", - }, - }, - targetPort: { - serializedName: "targetPort", - type: { - name: "Number", - }, - }, - exposedPort: { - serializedName: "exposedPort", - type: { - name: "Number", - }, - }, - transport: { - defaultValue: "auto", - serializedName: "transport", + name: { + serializedName: "name", type: { name: "String", }, }, - traffic: { - serializedName: "traffic", + command: { + serializedName: "command", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "TrafficWeight", + name: "String", }, }, }, }, - customDomains: { - serializedName: "customDomains", + args: { + serializedName: "args", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "CustomDomain", + name: "String", }, }, }, }, - allowInsecure: { - defaultValue: false, - serializedName: "allowInsecure", - type: { - name: "Boolean", - }, - }, - ipSecurityRestrictions: { - serializedName: "ipSecurityRestrictions", + env: { + serializedName: "env", type: { name: "Sequence", element: { type: { name: "Composite", - className: "IpSecurityRestrictionRule", + className: "EnvironmentVar", }, }, }, }, - stickySessions: { - serializedName: "stickySessions", - type: { - name: "Composite", - className: "IngressStickySessions", - }, - }, - clientCertificateMode: { - serializedName: "clientCertificateMode", - type: { - name: "String", - }, - }, - corsPolicy: { - serializedName: "corsPolicy", + resources: { + serializedName: "resources", type: { name: "Composite", - className: "CorsPolicy", + className: "ContainerResources", }, }, - additionalPortMappings: { - serializedName: "additionalPortMappings", + volumeMounts: { + serializedName: "volumeMounts", type: { name: "Sequence", element: { type: { name: "Composite", - className: "IngressPortMapping", + className: "VolumeMount", }, }, }, }, - targetPortHttpScheme: { - serializedName: "targetPortHttpScheme", - type: { - name: "String", - }, - }, }, }, }; -export const TrafficWeight: coreClient.CompositeMapper = { +export const EnvironmentVar: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TrafficWeight", + className: "EnvironmentVar", modelProperties: { - revisionName: { - serializedName: "revisionName", + name: { + serializedName: "name", type: { name: "String", }, }, - weight: { - serializedName: "weight", - type: { - name: "Number", - }, - }, - latestRevision: { - defaultValue: false, - serializedName: "latestRevision", + value: { + serializedName: "value", type: { - name: "Boolean", + name: "String", }, }, - label: { - serializedName: "label", + secretRef: { + serializedName: "secretRef", type: { name: "String", }, @@ -3062,26 +2840,26 @@ export const TrafficWeight: coreClient.CompositeMapper = { }, }; -export const CustomDomain: coreClient.CompositeMapper = { +export const ContainerResources: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomDomain", + className: "ContainerResources", modelProperties: { - name: { - serializedName: "name", - required: true, + cpu: { + serializedName: "cpu", type: { - name: "String", + name: "Number", }, }, - bindingType: { - serializedName: "bindingType", + memory: { + serializedName: "memory", type: { name: "String", }, }, - certificateId: { - serializedName: "certificateId", + ephemeralStorage: { + serializedName: "ephemeralStorage", + readOnly: true, type: { name: "String", }, @@ -3090,34 +2868,25 @@ export const CustomDomain: coreClient.CompositeMapper = { }, }; -export const IpSecurityRestrictionRule: coreClient.CompositeMapper = { +export const VolumeMount: coreClient.CompositeMapper = { type: { name: "Composite", - className: "IpSecurityRestrictionRule", + className: "VolumeMount", modelProperties: { - name: { - serializedName: "name", - required: true, - type: { - name: "String", - }, - }, - description: { - serializedName: "description", + volumeName: { + serializedName: "volumeName", type: { name: "String", }, }, - ipAddressRange: { - serializedName: "ipAddressRange", - required: true, + mountPath: { + serializedName: "mountPath", type: { name: "String", }, }, - action: { - serializedName: "action", - required: true, + subPath: { + serializedName: "subPath", type: { name: "String", }, @@ -3126,13 +2895,63 @@ export const IpSecurityRestrictionRule: coreClient.CompositeMapper = { }, }; -export const IngressStickySessions: coreClient.CompositeMapper = { +export const ContainerAppProbe: coreClient.CompositeMapper = { type: { name: "Composite", - className: "IngressStickySessions", + className: "ContainerAppProbe", modelProperties: { - affinity: { - serializedName: "affinity", + failureThreshold: { + serializedName: "failureThreshold", + type: { + name: "Number", + }, + }, + httpGet: { + serializedName: "httpGet", + type: { + name: "Composite", + className: "ContainerAppProbeHttpGet", + }, + }, + initialDelaySeconds: { + serializedName: "initialDelaySeconds", + type: { + name: "Number", + }, + }, + periodSeconds: { + serializedName: "periodSeconds", + type: { + name: "Number", + }, + }, + successThreshold: { + serializedName: "successThreshold", + type: { + name: "Number", + }, + }, + tcpSocket: { + serializedName: "tcpSocket", + type: { + name: "Composite", + className: "ContainerAppProbeTcpSocket", + }, + }, + terminationGracePeriodSeconds: { + serializedName: "terminationGracePeriodSeconds", + type: { + name: "Number", + }, + }, + timeoutSeconds: { + serializedName: "timeoutSeconds", + type: { + name: "Number", + }, + }, + type: { + serializedName: "type", type: { name: "String", }, @@ -3141,296 +2960,245 @@ export const IngressStickySessions: coreClient.CompositeMapper = { }, }; -export const CorsPolicy: coreClient.CompositeMapper = { +export const ContainerAppProbeHttpGet: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CorsPolicy", + className: "ContainerAppProbeHttpGet", modelProperties: { - allowedOrigins: { - serializedName: "allowedOrigins", - required: true, + host: { + serializedName: "host", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - allowedMethods: { - serializedName: "allowedMethods", + httpHeaders: { + serializedName: "httpHeaders", type: { name: "Sequence", element: { type: { - name: "String", + name: "Composite", + className: "ContainerAppProbeHttpGetHttpHeadersItem", }, }, }, }, - allowedHeaders: { - serializedName: "allowedHeaders", + path: { + serializedName: "path", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - exposeHeaders: { - serializedName: "exposeHeaders", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - maxAge: { - serializedName: "maxAge", + port: { + serializedName: "port", + required: true, type: { name: "Number", }, }, - allowCredentials: { - serializedName: "allowCredentials", + scheme: { + serializedName: "scheme", type: { - name: "Boolean", + name: "String", }, }, }, }, }; -export const IngressPortMapping: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "IngressPortMapping", - modelProperties: { - external: { - serializedName: "external", - required: true, - type: { - name: "Boolean", - }, - }, - targetPort: { - serializedName: "targetPort", - required: true, - type: { - name: "Number", +export const ContainerAppProbeHttpGetHttpHeadersItem: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ContainerAppProbeHttpGetHttpHeadersItem", + modelProperties: { + name: { + serializedName: "name", + required: true, + type: { + name: "String", + }, }, - }, - exposedPort: { - serializedName: "exposedPort", - type: { - name: "Number", + value: { + serializedName: "value", + required: true, + type: { + name: "String", + }, }, }, }, - }, -}; + }; -export const RegistryCredentials: coreClient.CompositeMapper = { +export const ContainerAppProbeTcpSocket: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RegistryCredentials", + className: "ContainerAppProbeTcpSocket", modelProperties: { - server: { - serializedName: "server", - type: { - name: "String", - }, - }, - username: { - serializedName: "username", - type: { - name: "String", - }, - }, - passwordSecretRef: { - serializedName: "passwordSecretRef", + host: { + serializedName: "host", type: { name: "String", }, }, - identity: { - serializedName: "identity", + port: { + serializedName: "port", + required: true, type: { - name: "String", + name: "Number", }, }, }, }, }; -export const Dapr: coreClient.CompositeMapper = { +export const Scale: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Dapr", + className: "Scale", modelProperties: { - enabled: { - defaultValue: false, - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - appId: { - serializedName: "appId", - type: { - name: "String", - }, - }, - appProtocol: { - defaultValue: "http", - serializedName: "appProtocol", - type: { - name: "String", - }, - }, - appPort: { - serializedName: "appPort", + minReplicas: { + serializedName: "minReplicas", type: { name: "Number", }, }, - httpReadBufferSize: { - serializedName: "httpReadBufferSize", + maxReplicas: { + defaultValue: 10, + serializedName: "maxReplicas", type: { name: "Number", }, }, - httpMaxRequestSize: { - serializedName: "httpMaxRequestSize", + cooldownPeriod: { + serializedName: "cooldownPeriod", type: { name: "Number", }, }, - logLevel: { - serializedName: "logLevel", + pollingInterval: { + serializedName: "pollingInterval", type: { - name: "String", + name: "Number", }, }, - enableApiLogging: { - serializedName: "enableApiLogging", + rules: { + serializedName: "rules", type: { - name: "Boolean", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ScaleRule", + }, + }, }, }, }, }, }; -export const Runtime: coreClient.CompositeMapper = { +export const ScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Runtime", + className: "ScaleRule", modelProperties: { - java: { - serializedName: "java", + name: { + serializedName: "name", + type: { + name: "String", + }, + }, + azureQueue: { + serializedName: "azureQueue", type: { name: "Composite", - className: "RuntimeJava", + className: "QueueScaleRule", }, }, - dotnet: { - serializedName: "dotnet", + custom: { + serializedName: "custom", type: { name: "Composite", - className: "RuntimeDotnet", + className: "CustomScaleRule", }, }, - }, - }, -}; - -export const RuntimeJava: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RuntimeJava", - modelProperties: { - enableMetrics: { - serializedName: "enableMetrics", + http: { + serializedName: "http", type: { - name: "Boolean", + name: "Composite", + className: "HttpScaleRule", }, }, - javaAgent: { - serializedName: "javaAgent", + tcp: { + serializedName: "tcp", type: { name: "Composite", - className: "RuntimeJavaAgent", + className: "TcpScaleRule", }, }, }, }, }; -export const RuntimeJavaAgent: coreClient.CompositeMapper = { +export const QueueScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RuntimeJavaAgent", + className: "QueueScaleRule", modelProperties: { - enabled: { - serializedName: "enabled", + accountName: { + serializedName: "accountName", type: { - name: "Boolean", + name: "String", }, }, - logging: { - serializedName: "logging", + queueName: { + serializedName: "queueName", type: { - name: "Composite", - className: "RuntimeJavaAgentLogging", + name: "String", }, }, - }, - }, -}; - -export const RuntimeJavaAgentLogging: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RuntimeJavaAgentLogging", - modelProperties: { - loggerSettings: { - serializedName: "loggerSettings", + queueLength: { + serializedName: "queueLength", + type: { + name: "Number", + }, + }, + auth: { + serializedName: "auth", type: { name: "Sequence", element: { type: { name: "Composite", - className: "LoggerSetting", + className: "ScaleRuleAuth", }, }, }, }, + identity: { + serializedName: "identity", + type: { + name: "String", + }, + }, }, }, }; -export const LoggerSetting: coreClient.CompositeMapper = { +export const ScaleRuleAuth: coreClient.CompositeMapper = { type: { name: "Composite", - className: "LoggerSetting", + className: "ScaleRuleAuth", modelProperties: { - logger: { - serializedName: "logger", - required: true, + secretRef: { + serializedName: "secretRef", type: { name: "String", }, }, - level: { - serializedName: "level", - required: true, + triggerParameter: { + serializedName: "triggerParameter", type: { name: "String", }, @@ -3439,52 +3207,38 @@ export const LoggerSetting: coreClient.CompositeMapper = { }, }; -export const RuntimeDotnet: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RuntimeDotnet", - modelProperties: { - autoConfigureDataProtection: { - serializedName: "autoConfigureDataProtection", - type: { - name: "Boolean", - }, - }, - }, - }, -}; - -export const Service: coreClient.CompositeMapper = { +export const CustomScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Service", + className: "CustomScaleRule", modelProperties: { type: { serializedName: "type", - required: true, type: { name: "String", }, }, - }, - }, -}; - -export const IdentitySettings: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "IdentitySettings", - modelProperties: { - identity: { - serializedName: "identity", - required: true, + metadata: { + serializedName: "metadata", type: { - name: "String", + name: "Dictionary", + value: { type: { name: "String" } }, }, }, - lifecycle: { - defaultValue: "All", - serializedName: "lifecycle", + auth: { + serializedName: "auth", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ScaleRuleAuth", + }, + }, + }, + }, + identity: { + serializedName: "identity", type: { name: "String", }, @@ -3493,181 +3247,132 @@ export const IdentitySettings: coreClient.CompositeMapper = { }, }; -export const Template: coreClient.CompositeMapper = { +export const HttpScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Template", + className: "HttpScaleRule", modelProperties: { - revisionSuffix: { - serializedName: "revisionSuffix", - type: { - name: "String", - }, - }, - terminationGracePeriodSeconds: { - serializedName: "terminationGracePeriodSeconds", + metadata: { + serializedName: "metadata", type: { - name: "Number", + name: "Dictionary", + value: { type: { name: "String" } }, }, }, - initContainers: { - serializedName: "initContainers", + auth: { + serializedName: "auth", type: { name: "Sequence", element: { type: { name: "Composite", - className: "InitContainer", + className: "ScaleRuleAuth", }, }, }, }, - containers: { - serializedName: "containers", + identity: { + serializedName: "identity", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Container", - }, - }, + name: "String", }, }, - scale: { - serializedName: "scale", + }, + }, +}; + +export const TcpScaleRule: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TcpScaleRule", + modelProperties: { + metadata: { + serializedName: "metadata", type: { - name: "Composite", - className: "Scale", + name: "Dictionary", + value: { type: { name: "String" } }, }, }, - volumes: { - serializedName: "volumes", + auth: { + serializedName: "auth", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Volume", + className: "ScaleRuleAuth", }, }, }, }, - serviceBinds: { - serializedName: "serviceBinds", + identity: { + serializedName: "identity", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ServiceBind", - }, - }, + name: "String", }, }, }, }, }; -export const BaseContainer: coreClient.CompositeMapper = { +export const Volume: coreClient.CompositeMapper = { type: { name: "Composite", - className: "BaseContainer", + className: "Volume", modelProperties: { - image: { - serializedName: "image", - type: { - name: "String", - }, - }, - imageType: { - serializedName: "imageType", - type: { - name: "String", - }, - }, name: { serializedName: "name", type: { name: "String", }, }, - command: { - serializedName: "command", + storageType: { + serializedName: "storageType", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - args: { - serializedName: "args", + storageName: { + serializedName: "storageName", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - env: { - serializedName: "env", + secrets: { + serializedName: "secrets", type: { name: "Sequence", element: { type: { name: "Composite", - className: "EnvironmentVar", + className: "SecretVolumeItem", }, }, }, }, - resources: { - serializedName: "resources", - type: { - name: "Composite", - className: "ContainerResources", - }, - }, - volumeMounts: { - serializedName: "volumeMounts", + mountOptions: { + serializedName: "mountOptions", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "VolumeMount", - }, - }, + name: "String", }, }, }, }, }; -export const EnvironmentVar: coreClient.CompositeMapper = { +export const SecretVolumeItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "EnvironmentVar", + className: "SecretVolumeItem", modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - value: { - serializedName: "value", + secretRef: { + serializedName: "secretRef", type: { name: "String", }, }, - secretRef: { - serializedName: "secretRef", + path: { + serializedName: "path", type: { name: "String", }, @@ -3676,26 +3381,19 @@ export const EnvironmentVar: coreClient.CompositeMapper = { }, }; -export const ContainerResources: coreClient.CompositeMapper = { +export const ServiceBind: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerResources", + className: "ServiceBind", modelProperties: { - cpu: { - serializedName: "cpu", - type: { - name: "Number", - }, - }, - memory: { - serializedName: "memory", + serviceId: { + serializedName: "serviceId", type: { name: "String", }, }, - ephemeralStorage: { - serializedName: "ephemeralStorage", - readOnly: true, + name: { + serializedName: "name", type: { name: "String", }, @@ -3704,228 +3402,212 @@ export const ContainerResources: coreClient.CompositeMapper = { }, }; -export const VolumeMount: coreClient.CompositeMapper = { +export const CustomHostnameAnalysisResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "VolumeMount", + className: "CustomHostnameAnalysisResult", modelProperties: { - volumeName: { - serializedName: "volumeName", + hostName: { + serializedName: "hostName", + readOnly: true, type: { name: "String", }, }, - mountPath: { - serializedName: "mountPath", + isHostnameAlreadyVerified: { + serializedName: "isHostnameAlreadyVerified", + readOnly: true, type: { - name: "String", + name: "Boolean", }, }, - subPath: { - serializedName: "subPath", + customDomainVerificationTest: { + serializedName: "customDomainVerificationTest", + readOnly: true, type: { - name: "String", + name: "Enum", + allowedValues: ["Passed", "Failed", "Skipped"], }, }, - }, - }, -}; - -export const ContainerAppProbe: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppProbe", - modelProperties: { - failureThreshold: { - serializedName: "failureThreshold", + customDomainVerificationFailureInfo: { + serializedName: "customDomainVerificationFailureInfo", type: { - name: "Number", + name: "Composite", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo", }, }, - httpGet: { - serializedName: "httpGet", + hasConflictOnManagedEnvironment: { + serializedName: "hasConflictOnManagedEnvironment", + readOnly: true, type: { - name: "Composite", - className: "ContainerAppProbeHttpGet", + name: "Boolean", }, }, - initialDelaySeconds: { - serializedName: "initialDelaySeconds", + conflictWithEnvironmentCustomDomain: { + serializedName: "conflictWithEnvironmentCustomDomain", + readOnly: true, type: { - name: "Number", + name: "Boolean", }, }, - periodSeconds: { - serializedName: "periodSeconds", + conflictingContainerAppResourceId: { + serializedName: "conflictingContainerAppResourceId", + readOnly: true, type: { - name: "Number", + name: "String", }, }, - successThreshold: { - serializedName: "successThreshold", - type: { - name: "Number", - }, - }, - tcpSocket: { - serializedName: "tcpSocket", - type: { - name: "Composite", - className: "ContainerAppProbeTcpSocket", - }, - }, - terminationGracePeriodSeconds: { - serializedName: "terminationGracePeriodSeconds", - type: { - name: "Number", - }, - }, - timeoutSeconds: { - serializedName: "timeoutSeconds", - type: { - name: "Number", - }, - }, - type: { - serializedName: "type", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppProbeHttpGet: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppProbeHttpGet", - modelProperties: { - host: { - serializedName: "host", + cNameRecords: { + serializedName: "cNameRecords", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - httpHeaders: { - serializedName: "httpHeaders", + txtRecords: { + serializedName: "txtRecords", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "ContainerAppProbeHttpGetHttpHeadersItem", + name: "String", }, }, }, }, - path: { - serializedName: "path", + aRecords: { + serializedName: "aRecords", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - port: { - serializedName: "port", - required: true, + alternateCNameRecords: { + serializedName: "alternateCNameRecords", type: { - name: "Number", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, - scheme: { - serializedName: "scheme", + alternateTxtRecords: { + serializedName: "alternateTxtRecords", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "String", + }, + }, }, }, }, }, }; -export const ContainerAppProbeHttpGetHttpHeadersItem: coreClient.CompositeMapper = +export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppProbeHttpGetHttpHeadersItem", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo", modelProperties: { - name: { - serializedName: "name", - required: true, + code: { + serializedName: "code", + readOnly: true, type: { name: "String", }, }, - value: { - serializedName: "value", - required: true, + message: { + serializedName: "message", + readOnly: true, + type: { + name: "String", + }, + }, + target: { + serializedName: "target", + readOnly: true, type: { name: "String", }, }, + details: { + serializedName: "details", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem", + }, + }, + }, + }, }, }, }; -export const ContainerAppProbeTcpSocket: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppProbeTcpSocket", - modelProperties: { - host: { - serializedName: "host", - type: { - name: "String", +export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem", + modelProperties: { + code: { + serializedName: "code", + readOnly: true, + type: { + name: "String", + }, }, - }, - port: { - serializedName: "port", - required: true, - type: { - name: "Number", + message: { + serializedName: "message", + readOnly: true, + type: { + name: "String", + }, + }, + target: { + serializedName: "target", + readOnly: true, + type: { + name: "String", + }, }, }, }, - }, -}; + }; -export const Scale: coreClient.CompositeMapper = { +export const SecretsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Scale", + className: "SecretsCollection", modelProperties: { - minReplicas: { - serializedName: "minReplicas", - type: { - name: "Number", - }, - }, - maxReplicas: { - defaultValue: 10, - serializedName: "maxReplicas", - type: { - name: "Number", - }, - }, - cooldownPeriod: { - serializedName: "cooldownPeriod", - type: { - name: "Number", - }, - }, - pollingInterval: { - serializedName: "pollingInterval", - type: { - name: "Number", - }, - }, - rules: { - serializedName: "rules", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ScaleRule", + className: "ContainerAppSecret", }, }, }, @@ -3934,1874 +3616,182 @@ export const Scale: coreClient.CompositeMapper = { }, }; -export const ScaleRule: coreClient.CompositeMapper = { +export const ContainerAppSecret: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ScaleRule", + className: "ContainerAppSecret", modelProperties: { name: { serializedName: "name", + readOnly: true, type: { name: "String", }, }, - azureQueue: { - serializedName: "azureQueue", - type: { - name: "Composite", - className: "QueueScaleRule", - }, - }, - custom: { - serializedName: "custom", - type: { - name: "Composite", - className: "CustomScaleRule", - }, - }, - http: { - serializedName: "http", - type: { - name: "Composite", - className: "HttpScaleRule", - }, - }, - tcp: { - serializedName: "tcp", - type: { - name: "Composite", - className: "TcpScaleRule", - }, - }, - }, - }, -}; - -export const QueueScaleRule: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "QueueScaleRule", - modelProperties: { - accountName: { - serializedName: "accountName", + value: { + serializedName: "value", + readOnly: true, type: { name: "String", }, }, - queueName: { - serializedName: "queueName", - type: { - name: "String", - }, - }, - queueLength: { - serializedName: "queueLength", - type: { - name: "Number", - }, - }, - auth: { - serializedName: "auth", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth", - }, - }, - }, - }, - identity: { - serializedName: "identity", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ScaleRuleAuth: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ScaleRuleAuth", - modelProperties: { - secretRef: { - serializedName: "secretRef", - type: { - name: "String", - }, - }, - triggerParameter: { - serializedName: "triggerParameter", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const CustomScaleRule: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CustomScaleRule", - modelProperties: { - type: { - serializedName: "type", - type: { - name: "String", - }, - }, - metadata: { - serializedName: "metadata", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - auth: { - serializedName: "auth", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth", - }, - }, - }, - }, - identity: { - serializedName: "identity", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const HttpScaleRule: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "HttpScaleRule", - modelProperties: { - metadata: { - serializedName: "metadata", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - auth: { - serializedName: "auth", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth", - }, - }, - }, - }, - identity: { - serializedName: "identity", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const TcpScaleRule: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TcpScaleRule", - modelProperties: { - metadata: { - serializedName: "metadata", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - auth: { - serializedName: "auth", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth", - }, - }, - }, - }, identity: { serializedName: "identity", + readOnly: true, type: { - name: "String", - }, - }, - }, - }, -}; - -export const Volume: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Volume", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - storageType: { - serializedName: "storageType", - type: { - name: "String", - }, - }, - storageName: { - serializedName: "storageName", - type: { - name: "String", - }, - }, - secrets: { - serializedName: "secrets", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SecretVolumeItem", - }, - }, - }, - }, - mountOptions: { - serializedName: "mountOptions", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const SecretVolumeItem: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SecretVolumeItem", - modelProperties: { - secretRef: { - serializedName: "secretRef", - type: { - name: "String", - }, - }, - path: { - serializedName: "path", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ServiceBind: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ServiceBind", - modelProperties: { - serviceId: { - serializedName: "serviceId", - type: { - name: "String", - }, - }, - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - clientType: { - serializedName: "clientType", - type: { - name: "String", - }, - }, - customizedKeys: { - serializedName: "customizedKeys", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - }, - }, -}; - -export const CustomHostnameAnalysisResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CustomHostnameAnalysisResult", - modelProperties: { - hostName: { - serializedName: "hostName", - readOnly: true, - type: { - name: "String", - }, - }, - isHostnameAlreadyVerified: { - serializedName: "isHostnameAlreadyVerified", - readOnly: true, - type: { - name: "Boolean", - }, - }, - customDomainVerificationTest: { - serializedName: "customDomainVerificationTest", - readOnly: true, - type: { - name: "Enum", - allowedValues: ["Passed", "Failed", "Skipped"], - }, - }, - customDomainVerificationFailureInfo: { - serializedName: "customDomainVerificationFailureInfo", - type: { - name: "Composite", - className: - "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo", - }, - }, - hasConflictOnManagedEnvironment: { - serializedName: "hasConflictOnManagedEnvironment", - readOnly: true, - type: { - name: "Boolean", - }, - }, - conflictWithEnvironmentCustomDomain: { - serializedName: "conflictWithEnvironmentCustomDomain", - readOnly: true, - type: { - name: "Boolean", - }, - }, - conflictingContainerAppResourceId: { - serializedName: "conflictingContainerAppResourceId", - readOnly: true, - type: { - name: "String", - }, - }, - cNameRecords: { - serializedName: "cNameRecords", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - txtRecords: { - serializedName: "txtRecords", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - aRecords: { - serializedName: "aRecords", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - alternateCNameRecords: { - serializedName: "alternateCNameRecords", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - alternateTxtRecords: { - serializedName: "alternateTxtRecords", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - }, - }, -}; - -export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: - "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo", - modelProperties: { - code: { - serializedName: "code", - readOnly: true, - type: { - name: "String", - }, - }, - message: { - serializedName: "message", - readOnly: true, - type: { - name: "String", - }, - }, - target: { - serializedName: "target", - readOnly: true, - type: { - name: "String", - }, - }, - details: { - serializedName: "details", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: - "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem", - }, - }, - }, - }, - }, - }, - }; - -export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: - "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem", - modelProperties: { - code: { - serializedName: "code", - readOnly: true, - type: { - name: "String", - }, - }, - message: { - serializedName: "message", - readOnly: true, - type: { - name: "String", - }, - }, - target: { - serializedName: "target", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, - }; - -export const SecretsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SecretsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppSecret", - }, - }, - }, - }, - }, - }, -}; - -export const ContainerAppSecret: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppSecret", - modelProperties: { - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String", - }, - }, - value: { - serializedName: "value", - readOnly: true, - type: { - name: "String", - }, - }, - identity: { - serializedName: "identity", - readOnly: true, - type: { - name: "String", - }, - }, - keyVaultUrl: { - serializedName: "keyVaultUrl", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppsBuildCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsBuildCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppsBuildResource", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppsBuildConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsBuildConfiguration", - modelProperties: { - baseOs: { - serializedName: "baseOs", - readOnly: true, - type: { - name: "String", - }, - }, - platform: { - serializedName: "platform", - readOnly: true, - type: { - name: "String", - }, - }, - platformVersion: { - serializedName: "platformVersion", - readOnly: true, - type: { - name: "String", - }, - }, - environmentVariables: { - serializedName: "environmentVariables", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "EnvironmentVariable", - }, - }, - }, - }, - preBuildSteps: { - serializedName: "preBuildSteps", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PreBuildStep", - }, - }, - }, - }, - }, - }, -}; - -export const PatchCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppsPatchResource", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const PatchProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchProperties", - modelProperties: { - targetEnvironmentId: { - serializedName: "targetEnvironmentId", - type: { - name: "String", - }, - }, - targetContainerAppId: { - serializedName: "targetContainerAppId", - type: { - name: "String", - }, - }, - targetRevisionId: { - serializedName: "targetRevisionId", - type: { - name: "String", - }, - }, - patchApplyStatus: { - serializedName: "patchApplyStatus", - readOnly: true, - type: { - name: "String", - }, - }, - createdAt: { - serializedName: "createdAt", - readOnly: true, - type: { - name: "DateTime", - }, - }, - lastModifiedAt: { - serializedName: "lastModifiedAt", - readOnly: true, - type: { - name: "DateTime", - }, - }, - patchDetails: { - serializedName: "patchDetails", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PatchDetails", - }, - }, - }, - }, - }, - }, -}; - -export const PatchDetails: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchDetails", - modelProperties: { - targetContainerName: { - serializedName: "targetContainerName", - required: true, - readOnly: true, - type: { - name: "String", - }, - }, - targetImage: { - serializedName: "targetImage", - required: true, - readOnly: true, - type: { - name: "String", - }, - }, - lastDetectionTime: { - serializedName: "lastDetectionTime", - required: true, - readOnly: true, - type: { - name: "DateTime", - }, - }, - detectionStatus: { - serializedName: "detectionStatus", - required: true, - readOnly: true, - type: { - name: "String", - }, - }, - newImageName: { - serializedName: "newImageName", - readOnly: true, - type: { - name: "String", - }, - }, - newLayer: { - serializedName: "newLayer", - type: { - name: "Composite", - className: "PatchDetailsNewLayer", - }, - }, - oldLayer: { - serializedName: "oldLayer", - type: { - name: "Composite", - className: "PatchDetailsOldLayer", - }, - }, - patchType: { - serializedName: "patchType", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const PatchDetailsNewLayer: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchDetailsNewLayer", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - frameworkAndVersion: { - serializedName: "frameworkAndVersion", - type: { - name: "String", - }, - }, - osAndVersion: { - serializedName: "osAndVersion", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const PatchDetailsOldLayer: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchDetailsOldLayer", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - frameworkAndVersion: { - serializedName: "frameworkAndVersion", - type: { - name: "String", - }, - }, - osAndVersion: { - serializedName: "osAndVersion", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const PatchSkipConfig: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PatchSkipConfig", - modelProperties: { - skip: { - serializedName: "skip", - type: { - name: "Boolean", - }, - }, - }, - }, -}; - -export const RevisionCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RevisionCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Revision", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ReplicaContainer: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ReplicaContainer", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - containerId: { - serializedName: "containerId", - type: { - name: "String", - }, - }, - ready: { - serializedName: "ready", - type: { - name: "Boolean", - }, - }, - started: { - serializedName: "started", - type: { - name: "Boolean", - }, - }, - restartCount: { - serializedName: "restartCount", - type: { - name: "Number", - }, - }, - runningState: { - serializedName: "runningState", - readOnly: true, - type: { - name: "String", - }, - }, - runningStateDetails: { - serializedName: "runningStateDetails", - readOnly: true, - type: { - name: "String", - }, - }, - logStreamEndpoint: { - serializedName: "logStreamEndpoint", - readOnly: true, - type: { - name: "String", - }, - }, - execEndpoint: { - serializedName: "execEndpoint", - readOnly: true, - type: { - name: "String", - }, - }, - debugEndpoint: { - serializedName: "debugEndpoint", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ReplicaCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ReplicaCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Replica", - }, - }, - }, - }, - }, - }, -}; - -export const DiagnosticsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Diagnostics", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const DiagnosticsProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticsProperties", - modelProperties: { - metadata: { - serializedName: "metadata", - type: { - name: "Composite", - className: "DiagnosticsDefinition", - }, - }, - dataset: { - serializedName: "dataset", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DiagnosticsDataApiResponse", - }, - }, - }, - }, - status: { - serializedName: "status", - type: { - name: "Composite", - className: "DiagnosticsStatus", - }, - }, - dataProviderMetadata: { - serializedName: "dataProviderMetadata", - type: { - name: "Composite", - className: "DiagnosticDataProviderMetadata", - }, - }, - }, - }, -}; - -export const DiagnosticsDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticsDefinition", - modelProperties: { - id: { - serializedName: "id", - readOnly: true, - type: { - name: "String", - }, - }, - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String", - }, - }, - description: { - serializedName: "description", - readOnly: true, - type: { - name: "String", - }, - }, - author: { - serializedName: "author", - readOnly: true, - type: { - name: "String", - }, - }, - category: { - serializedName: "category", - readOnly: true, - type: { - name: "String", - }, - }, - supportTopicList: { - serializedName: "supportTopicList", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DiagnosticSupportTopic", - }, - }, - }, - }, - analysisTypes: { - serializedName: "analysisTypes", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - type: { - serializedName: "type", - readOnly: true, - type: { - name: "String", - }, - }, - score: { - serializedName: "score", - readOnly: true, - type: { - name: "Number", - }, - }, - }, - }, -}; - -export const DiagnosticSupportTopic: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticSupportTopic", - modelProperties: { - id: { - serializedName: "id", - readOnly: true, - type: { - name: "String", - }, - }, - pesId: { - serializedName: "pesId", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const DiagnosticsDataApiResponse: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticsDataApiResponse", - modelProperties: { - table: { - serializedName: "table", - type: { - name: "Composite", - className: "DiagnosticDataTableResponseObject", - }, - }, - renderingProperties: { - serializedName: "renderingProperties", - type: { - name: "Composite", - className: "DiagnosticRendering", - }, - }, - }, - }, -}; - -export const DiagnosticDataTableResponseObject: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticDataTableResponseObject", - modelProperties: { - tableName: { - serializedName: "tableName", - type: { - name: "String", - }, - }, - columns: { - serializedName: "columns", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DiagnosticDataTableResponseColumn", - }, - }, - }, - }, - rows: { - serializedName: "rows", - type: { - name: "Sequence", - element: { - type: { - name: "Dictionary", - value: { type: { name: "any" } }, - }, - }, - }, - }, - }, - }, -}; - -export const DiagnosticDataTableResponseColumn: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticDataTableResponseColumn", - modelProperties: { - columnName: { - serializedName: "columnName", - type: { - name: "String", - }, - }, - dataType: { - serializedName: "dataType", - type: { - name: "String", - }, - }, - columnType: { - serializedName: "columnType", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const DiagnosticRendering: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticRendering", - modelProperties: { - type: { - serializedName: "type", - type: { - name: "Number", - }, - }, - title: { - serializedName: "title", - type: { - name: "String", - }, - }, - description: { - serializedName: "description", - type: { - name: "String", - }, - }, - isVisible: { - serializedName: "isVisible", - type: { - name: "Boolean", - }, - }, - }, - }, -}; - -export const DiagnosticsStatus: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticsStatus", - modelProperties: { - message: { - serializedName: "message", - type: { - name: "String", - }, - }, - statusId: { - serializedName: "statusId", - type: { - name: "Number", - }, - }, - }, - }, -}; - -export const DiagnosticDataProviderMetadata: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticDataProviderMetadata", - modelProperties: { - providerName: { - serializedName: "providerName", - type: { - name: "String", - }, - }, - propertyBag: { - serializedName: "propertyBag", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DiagnosticDataProviderMetadataPropertyBagItem", - }, - }, - }, - }, - }, - }, -}; - -export const DiagnosticDataProviderMetadataPropertyBagItem: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DiagnosticDataProviderMetadataPropertyBagItem", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - value: { - serializedName: "value", - type: { - name: "String", - }, - }, - }, - }, - }; - -export const VnetConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "VnetConfiguration", - modelProperties: { - internal: { - serializedName: "internal", - type: { - name: "Boolean", - }, - }, - infrastructureSubnetId: { - serializedName: "infrastructureSubnetId", - type: { - name: "String", - }, - }, - dockerBridgeCidr: { - serializedName: "dockerBridgeCidr", - type: { - name: "String", - }, - }, - platformReservedCidr: { - serializedName: "platformReservedCidr", - type: { - name: "String", - }, - }, - platformReservedDnsIP: { - serializedName: "platformReservedDnsIP", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const AppLogsConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AppLogsConfiguration", - modelProperties: { - destination: { - serializedName: "destination", - type: { - name: "String", - }, - }, - logAnalyticsConfiguration: { - serializedName: "logAnalyticsConfiguration", - type: { - name: "Composite", - className: "LogAnalyticsConfiguration", - }, - }, - }, - }, -}; - -export const LogAnalyticsConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "LogAnalyticsConfiguration", - modelProperties: { - customerId: { - serializedName: "customerId", - type: { - name: "String", - }, - }, - sharedKey: { - serializedName: "sharedKey", - type: { - name: "String", - }, - }, - dynamicJsonColumns: { - serializedName: "dynamicJsonColumns", - type: { - name: "Boolean", - }, - }, - }, - }, -}; - -export const AppInsightsConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AppInsightsConfiguration", - modelProperties: { - connectionString: { - serializedName: "connectionString", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const OpenTelemetryConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "OpenTelemetryConfiguration", - modelProperties: { - destinationsConfiguration: { - serializedName: "destinationsConfiguration", - type: { - name: "Composite", - className: "DestinationsConfiguration", - }, - }, - tracesConfiguration: { - serializedName: "tracesConfiguration", - type: { - name: "Composite", - className: "TracesConfiguration", - }, - }, - logsConfiguration: { - serializedName: "logsConfiguration", - type: { - name: "Composite", - className: "LogsConfiguration", - }, - }, - metricsConfiguration: { - serializedName: "metricsConfiguration", - type: { - name: "Composite", - className: "MetricsConfiguration", - }, - }, - }, - }, -}; - -export const DestinationsConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DestinationsConfiguration", - modelProperties: { - dataDogConfiguration: { - serializedName: "dataDogConfiguration", - type: { - name: "Composite", - className: "DataDogConfiguration", - }, - }, - otlpConfigurations: { - serializedName: "otlpConfigurations", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "OtlpConfiguration", - }, - }, - }, - }, - }, - }, -}; - -export const DataDogConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataDogConfiguration", - modelProperties: { - site: { - serializedName: "site", - type: { - name: "String", - }, - }, - key: { - serializedName: "key", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const OtlpConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "OtlpConfiguration", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String", - }, - }, - endpoint: { - serializedName: "endpoint", - type: { - name: "String", - }, - }, - insecure: { - serializedName: "insecure", - type: { - name: "Boolean", - }, - }, - headers: { - serializedName: "headers", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Header", - }, - }, - }, - }, - }, - }, -}; - -export const Header: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Header", - modelProperties: { - key: { - serializedName: "key", - type: { - name: "String", - }, - }, - value: { - serializedName: "value", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const TracesConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TracesConfiguration", - modelProperties: { - includeDapr: { - serializedName: "includeDapr", - type: { - name: "Boolean", + name: "String", }, }, - destinations: { - serializedName: "destinations", + keyVaultUrl: { + serializedName: "keyVaultUrl", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, }, }, }; -export const LogsConfiguration: coreClient.CompositeMapper = { +export const RevisionCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "LogsConfiguration", + className: "RevisionCollection", modelProperties: { - destinations: { - serializedName: "destinations", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { - name: "String", + name: "Composite", + className: "Revision", }, }, }, }, - }, - }, -}; - -export const MetricsConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MetricsConfiguration", - modelProperties: { - includeKeda: { - serializedName: "includeKeda", - type: { - name: "Boolean", - }, - }, - destinations: { - serializedName: "destinations", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, }, }, }; -export const WorkloadProfile: coreClient.CompositeMapper = { +export const ReplicaContainer: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkloadProfile", + className: "ReplicaContainer", modelProperties: { name: { serializedName: "name", - required: true, type: { name: "String", }, }, - enableFips: { - defaultValue: false, - serializedName: "enableFips", + containerId: { + serializedName: "containerId", type: { - name: "Boolean", + name: "String", }, }, - workloadProfileType: { - serializedName: "workloadProfileType", - required: true, + ready: { + serializedName: "ready", type: { - name: "String", + name: "Boolean", }, }, - minimumCount: { - serializedName: "minimumCount", + started: { + serializedName: "started", type: { - name: "Number", + name: "Boolean", }, }, - maximumCount: { - serializedName: "maximumCount", + restartCount: { + serializedName: "restartCount", type: { name: "Number", }, }, - }, - }, -}; - -export const KedaConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "KedaConfiguration", - modelProperties: { - version: { - serializedName: "version", + runningState: { + serializedName: "runningState", readOnly: true, type: { name: "String", }, }, - }, - }, -}; - -export const DaprConfiguration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprConfiguration", - modelProperties: { - version: { - serializedName: "version", + runningStateDetails: { + serializedName: "runningStateDetails", readOnly: true, type: { name: "String", }, }, - }, - }, -}; - -export const ManagedEnvironmentPropertiesPeerAuthentication: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ManagedEnvironmentPropertiesPeerAuthentication", - modelProperties: { - mtls: { - serializedName: "mtls", - type: { - name: "Composite", - className: "Mtls", - }, + logStreamEndpoint: { + serializedName: "logStreamEndpoint", + readOnly: true, + type: { + name: "String", }, }, - }, - }; - -export const Mtls: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Mtls", - modelProperties: { - enabled: { - serializedName: "enabled", + execEndpoint: { + serializedName: "execEndpoint", + readOnly: true, type: { - name: "Boolean", + name: "String", }, }, }, }, }; -export const ManagedEnvironmentPropertiesPeerTrafficConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ManagedEnvironmentPropertiesPeerTrafficConfiguration", - modelProperties: { - encryption: { - serializedName: "encryption", - type: { - name: "Composite", - className: - "ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption", - }, - }, - }, - }, - }; - -export const ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: - "ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - }, - }, - }; - -export const PrivateEndpoint: coreClient.CompositeMapper = { +export const ReplicaCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateEndpoint", + className: "ReplicaCollection", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + value: { + serializedName: "value", + required: true, type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Replica", + }, + }, }, }, }, }, }; -export const PrivateLinkServiceConnectionState: coreClient.CompositeMapper = { +export const DiagnosticsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateLinkServiceConnectionState", + className: "DiagnosticsCollection", modelProperties: { - status: { - serializedName: "status", - type: { - name: "String", - }, - }, - description: { - serializedName: "description", + value: { + serializedName: "value", + required: true, type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Diagnostics", + }, + }, }, }, - actionsRequired: { - serializedName: "actionsRequired", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String", }, @@ -5810,204 +3800,206 @@ export const PrivateLinkServiceConnectionState: coreClient.CompositeMapper = { }, }; -export const JobConfiguration: coreClient.CompositeMapper = { +export const DiagnosticsProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobConfiguration", + className: "DiagnosticsProperties", modelProperties: { - secrets: { - serializedName: "secrets", + metadata: { + serializedName: "metadata", + type: { + name: "Composite", + className: "DiagnosticsDefinition", + }, + }, + dataset: { + serializedName: "dataset", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Secret", + className: "DiagnosticsDataApiResponse", }, }, }, }, - triggerType: { - defaultValue: "Manual", - serializedName: "triggerType", - required: true, + status: { + serializedName: "status", type: { - name: "String", + name: "Composite", + className: "DiagnosticsStatus", }, }, - replicaTimeout: { - serializedName: "replicaTimeout", - required: true, + dataProviderMetadata: { + serializedName: "dataProviderMetadata", type: { - name: "Number", + name: "Composite", + className: "DiagnosticDataProviderMetadata", }, }, - replicaRetryLimit: { - serializedName: "replicaRetryLimit", + }, + }, +}; + +export const DiagnosticsDefinition: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DiagnosticsDefinition", + modelProperties: { + id: { + serializedName: "id", + readOnly: true, + type: { + name: "String", + }, + }, + name: { + serializedName: "name", + readOnly: true, type: { - name: "Number", + name: "String", }, }, - manualTriggerConfig: { - serializedName: "manualTriggerConfig", + description: { + serializedName: "description", + readOnly: true, type: { - name: "Composite", - className: "JobConfigurationManualTriggerConfig", + name: "String", }, }, - scheduleTriggerConfig: { - serializedName: "scheduleTriggerConfig", + author: { + serializedName: "author", + readOnly: true, type: { - name: "Composite", - className: "JobConfigurationScheduleTriggerConfig", + name: "String", }, }, - eventTriggerConfig: { - serializedName: "eventTriggerConfig", + category: { + serializedName: "category", + readOnly: true, type: { - name: "Composite", - className: "JobConfigurationEventTriggerConfig", + name: "String", }, }, - registries: { - serializedName: "registries", + supportTopicList: { + serializedName: "supportTopicList", type: { name: "Sequence", element: { type: { name: "Composite", - className: "RegistryCredentials", + className: "DiagnosticSupportTopic", }, }, }, }, - identitySettings: { - serializedName: "identitySettings", + analysisTypes: { + serializedName: "analysisTypes", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "IdentitySettings", + name: "String", }, }, }, }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String", + }, + }, + score: { + serializedName: "score", + readOnly: true, + type: { + name: "Number", + }, + }, }, }, }; -export const JobConfigurationManualTriggerConfig: coreClient.CompositeMapper = { +export const DiagnosticSupportTopic: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobConfigurationManualTriggerConfig", + className: "DiagnosticSupportTopic", modelProperties: { - replicaCompletionCount: { - serializedName: "replicaCompletionCount", + id: { + serializedName: "id", + readOnly: true, type: { - name: "Number", + name: "String", }, }, - parallelism: { - serializedName: "parallelism", + pesId: { + serializedName: "pesId", + readOnly: true, type: { - name: "Number", + name: "String", }, }, }, }, }; -export const JobConfigurationScheduleTriggerConfig: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "JobConfigurationScheduleTriggerConfig", - modelProperties: { - replicaCompletionCount: { - serializedName: "replicaCompletionCount", - type: { - name: "Number", - }, - }, - cronExpression: { - serializedName: "cronExpression", - required: true, - type: { - name: "String", - }, - }, - parallelism: { - serializedName: "parallelism", - type: { - name: "Number", - }, - }, - }, - }, - }; - -export const JobConfigurationEventTriggerConfig: coreClient.CompositeMapper = { +export const DiagnosticsDataApiResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobConfigurationEventTriggerConfig", + className: "DiagnosticsDataApiResponse", modelProperties: { - replicaCompletionCount: { - serializedName: "replicaCompletionCount", - type: { - name: "Number", - }, - }, - parallelism: { - serializedName: "parallelism", + table: { + serializedName: "table", type: { - name: "Number", + name: "Composite", + className: "DiagnosticDataTableResponseObject", }, }, - scale: { - serializedName: "scale", + renderingProperties: { + serializedName: "renderingProperties", type: { name: "Composite", - className: "JobScale", + className: "DiagnosticRendering", }, }, }, }, }; -export const JobScale: coreClient.CompositeMapper = { +export const DiagnosticDataTableResponseObject: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobScale", + className: "DiagnosticDataTableResponseObject", modelProperties: { - pollingInterval: { - serializedName: "pollingInterval", - type: { - name: "Number", - }, - }, - minExecutions: { - defaultValue: 0, - serializedName: "minExecutions", + tableName: { + serializedName: "tableName", type: { - name: "Number", + name: "String", }, }, - maxExecutions: { - defaultValue: 100, - serializedName: "maxExecutions", + columns: { + serializedName: "columns", type: { - name: "Number", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DiagnosticDataTableResponseColumn", + }, + }, }, }, - rules: { - serializedName: "rules", + rows: { + serializedName: "rows", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "JobScaleRule", + name: "Dictionary", + value: { type: { name: "any" } }, }, }, }, @@ -6016,134 +4008,122 @@ export const JobScale: coreClient.CompositeMapper = { }, }; -export const JobScaleRule: coreClient.CompositeMapper = { +export const DiagnosticDataTableResponseColumn: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobScaleRule", + className: "DiagnosticDataTableResponseColumn", modelProperties: { - name: { - serializedName: "name", + columnName: { + serializedName: "columnName", type: { name: "String", }, }, - type: { - serializedName: "type", + dataType: { + serializedName: "dataType", type: { name: "String", }, }, - metadata: { - serializedName: "metadata", + columnType: { + serializedName: "columnType", type: { - name: "Dictionary", - value: { type: { name: "any" } }, + name: "String", }, }, - auth: { - serializedName: "auth", + }, + }, +}; + +export const DiagnosticRendering: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DiagnosticRendering", + modelProperties: { + type: { + serializedName: "type", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth", - }, - }, + name: "Number", }, }, - identity: { - serializedName: "identity", + title: { + serializedName: "title", + type: { + name: "String", + }, + }, + description: { + serializedName: "description", type: { name: "String", }, }, + isVisible: { + serializedName: "isVisible", + type: { + name: "Boolean", + }, + }, }, }, }; -export const JobTemplate: coreClient.CompositeMapper = { +export const DiagnosticsStatus: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobTemplate", + className: "DiagnosticsStatus", modelProperties: { - initContainers: { - serializedName: "initContainers", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "InitContainer", - }, - }, - }, - }, - containers: { - serializedName: "containers", + message: { + serializedName: "message", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Container", - }, - }, + name: "String", }, }, - volumes: { - serializedName: "volumes", + statusId: { + serializedName: "statusId", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Volume", - }, - }, + name: "Number", }, }, }, }, }; -export const DotNetComponentsCollection: coreClient.CompositeMapper = { +export const DiagnosticDataProviderMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DotNetComponentsCollection", + className: "DiagnosticDataProviderMetadata", modelProperties: { - value: { - serializedName: "value", - required: true, + providerName: { + serializedName: "providerName", + type: { + name: "String", + }, + }, + propertyBag: { + serializedName: "propertyBag", type: { name: "Sequence", element: { type: { name: "Composite", - className: "DotNetComponent", + className: "DiagnosticDataProviderMetadataPropertyBagItem", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, }, }, }; -export const DotNetComponentConfigurationProperty: coreClient.CompositeMapper = +export const DiagnosticDataProviderMetadataPropertyBagItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DotNetComponentConfigurationProperty", + className: "DiagnosticDataProviderMetadataPropertyBagItem", modelProperties: { - propertyName: { - serializedName: "propertyName", + name: { + serializedName: "name", type: { name: "String", }, @@ -6158,46 +4138,37 @@ export const DotNetComponentConfigurationProperty: coreClient.CompositeMapper = }, }; -export const DotNetComponentServiceBind: coreClient.CompositeMapper = { +export const VnetConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DotNetComponentServiceBind", + className: "VnetConfiguration", modelProperties: { - name: { - serializedName: "name", + internal: { + serializedName: "internal", + type: { + name: "Boolean", + }, + }, + infrastructureSubnetId: { + serializedName: "infrastructureSubnetId", type: { name: "String", }, }, - serviceId: { - serializedName: "serviceId", + dockerBridgeCidr: { + serializedName: "dockerBridgeCidr", type: { name: "String", }, }, - }, - }, -}; - -export const AvailableOperations: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AvailableOperations", - modelProperties: { - value: { - serializedName: "value", + platformReservedCidr: { + serializedName: "platformReservedCidr", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "OperationDetail", - }, - }, + name: "String", }, }, - nextLink: { - serializedName: "nextLink", + platformReservedDnsIP: { + serializedName: "platformReservedDnsIP", type: { name: "String", }, @@ -6206,32 +4177,41 @@ export const AvailableOperations: coreClient.CompositeMapper = { }, }; -export const OperationDetail: coreClient.CompositeMapper = { +export const AppLogsConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OperationDetail", + className: "AppLogsConfiguration", modelProperties: { - name: { - serializedName: "name", + destination: { + serializedName: "destination", type: { name: "String", }, }, - isDataAction: { - serializedName: "isDataAction", + logAnalyticsConfiguration: { + serializedName: "logAnalyticsConfiguration", type: { - name: "Boolean", + name: "Composite", + className: "LogAnalyticsConfiguration", }, }, - display: { - serializedName: "display", + }, + }, +}; + +export const LogAnalyticsConfiguration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "LogAnalyticsConfiguration", + modelProperties: { + customerId: { + serializedName: "customerId", type: { - name: "Composite", - className: "OperationDisplay", + name: "String", }, }, - origin: { - serializedName: "origin", + sharedKey: { + serializedName: "sharedKey", type: { name: "String", }, @@ -6240,59 +4220,48 @@ export const OperationDetail: coreClient.CompositeMapper = { }, }; -export const OperationDisplay: coreClient.CompositeMapper = { +export const WorkloadProfile: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OperationDisplay", + className: "WorkloadProfile", modelProperties: { - provider: { - serializedName: "provider", + name: { + serializedName: "name", + required: true, type: { name: "String", }, }, - resource: { - serializedName: "resource", + workloadProfileType: { + serializedName: "workloadProfileType", + required: true, type: { name: "String", }, }, - operation: { - serializedName: "operation", + minimumCount: { + serializedName: "minimumCount", type: { - name: "String", + name: "Number", }, }, - description: { - serializedName: "description", + maximumCount: { + serializedName: "maximumCount", type: { - name: "String", + name: "Number", }, }, }, }, }; -export const JavaComponentsCollection: coreClient.CompositeMapper = { +export const KedaConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JavaComponentsCollection", + className: "KedaConfiguration", modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JavaComponent", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", + version: { + serializedName: "version", readOnly: true, type: { name: "String", @@ -6302,265 +4271,275 @@ export const JavaComponentsCollection: coreClient.CompositeMapper = { }, }; -export const JavaComponentProperties: coreClient.CompositeMapper = { +export const DaprConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JavaComponentProperties", - uberParent: "JavaComponentProperties", - polymorphicDiscriminator: { - serializedName: "componentType", - clientName: "componentType", - }, + className: "DaprConfiguration", modelProperties: { - componentType: { - serializedName: "componentType", - required: true, + version: { + serializedName: "version", + readOnly: true, type: { name: "String", }, }, - provisioningState: { - serializedName: "provisioningState", - readOnly: true, - type: { - name: "String", + }, + }, +}; + +export const ManagedEnvironmentPropertiesPeerAuthentication: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ManagedEnvironmentPropertiesPeerAuthentication", + modelProperties: { + mtls: { + serializedName: "mtls", + type: { + name: "Composite", + className: "Mtls", + }, }, }, - configurations: { - serializedName: "configurations", + }, + }; + +export const Mtls: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Mtls", + modelProperties: { + enabled: { + serializedName: "enabled", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JavaComponentConfigurationProperty", - }, + name: "Boolean", + }, + }, + }, + }, +}; + +export const ManagedEnvironmentPropertiesPeerTrafficConfiguration: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ManagedEnvironmentPropertiesPeerTrafficConfiguration", + modelProperties: { + encryption: { + serializedName: "encryption", + type: { + name: "Composite", + className: + "ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption", }, }, }, - scale: { - serializedName: "scale", - type: { - name: "Composite", - className: "JavaComponentPropertiesScale", + }, + }; + +export const ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: + "ManagedEnvironmentPropertiesPeerTrafficConfigurationEncryption", + modelProperties: { + enabled: { + serializedName: "enabled", + type: { + name: "Boolean", + }, }, }, - serviceBinds: { - serializedName: "serviceBinds", + }, + }; + +export const JobConfiguration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "JobConfiguration", + modelProperties: { + secrets: { + serializedName: "secrets", type: { name: "Sequence", element: { type: { name: "Composite", - className: "JavaComponentServiceBind", + className: "Secret", }, }, }, }, - }, - }, -}; - -export const JavaComponentConfigurationProperty: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JavaComponentConfigurationProperty", - modelProperties: { - propertyName: { - serializedName: "propertyName", + triggerType: { + defaultValue: "Manual", + serializedName: "triggerType", + required: true, type: { name: "String", }, }, - value: { - serializedName: "value", + replicaTimeout: { + serializedName: "replicaTimeout", + required: true, type: { - name: "String", + name: "Number", }, }, - }, - }, -}; - -export const JavaComponentPropertiesScale: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JavaComponentPropertiesScale", - modelProperties: { - minReplicas: { - serializedName: "minReplicas", + replicaRetryLimit: { + serializedName: "replicaRetryLimit", type: { name: "Number", }, }, - maxReplicas: { - serializedName: "maxReplicas", + manualTriggerConfig: { + serializedName: "manualTriggerConfig", type: { - name: "Number", + name: "Composite", + className: "JobConfigurationManualTriggerConfig", }, }, - }, - }, -}; - -export const JavaComponentServiceBind: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JavaComponentServiceBind", - modelProperties: { - name: { - serializedName: "name", + scheduleTriggerConfig: { + serializedName: "scheduleTriggerConfig", type: { - name: "String", + name: "Composite", + className: "JobConfigurationScheduleTriggerConfig", }, }, - serviceId: { - serializedName: "serviceId", + eventTriggerConfig: { + serializedName: "eventTriggerConfig", type: { - name: "String", + name: "Composite", + className: "JobConfigurationEventTriggerConfig", }, }, - }, - }, -}; - -export const JobsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JobsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + registries: { + serializedName: "registries", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Job", + className: "RegistryCredentials", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, }, }, }; -export const JobPatchProperties: coreClient.CompositeMapper = { +export const JobConfigurationManualTriggerConfig: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobPatchProperties", + className: "JobConfigurationManualTriggerConfig", modelProperties: { - extendedLocation: { - serializedName: "extendedLocation", + replicaCompletionCount: { + serializedName: "replicaCompletionCount", type: { - name: "Composite", - className: "ExtendedLocation", + name: "Number", }, }, - identity: { - serializedName: "identity", + parallelism: { + serializedName: "parallelism", type: { - name: "Composite", - className: "ManagedServiceIdentity", + name: "Number", }, }, - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, + }, + }, +}; + +export const JobConfigurationScheduleTriggerConfig: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "JobConfigurationScheduleTriggerConfig", + modelProperties: { + replicaCompletionCount: { + serializedName: "replicaCompletionCount", + type: { + name: "Number", + }, }, - }, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "JobPatchPropertiesProperties", + cronExpression: { + serializedName: "cronExpression", + required: true, + type: { + name: "String", + }, + }, + parallelism: { + serializedName: "parallelism", + type: { + name: "Number", + }, }, }, }, - }, -}; + }; -export const JobPatchPropertiesProperties: coreClient.CompositeMapper = { +export const JobConfigurationEventTriggerConfig: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobPatchPropertiesProperties", + className: "JobConfigurationEventTriggerConfig", modelProperties: { - environmentId: { - serializedName: "environmentId", + replicaCompletionCount: { + serializedName: "replicaCompletionCount", type: { - name: "String", + name: "Number", }, }, - configuration: { - serializedName: "configuration", + parallelism: { + serializedName: "parallelism", type: { - name: "Composite", - className: "JobConfiguration", + name: "Number", }, }, - template: { - serializedName: "template", + scale: { + serializedName: "scale", type: { name: "Composite", - className: "JobTemplate", - }, - }, - outboundIpAddresses: { - serializedName: "outboundIpAddresses", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - eventStreamEndpoint: { - serializedName: "eventStreamEndpoint", - type: { - name: "String", + className: "JobScale", }, }, }, }, }; -export const JobExecutionTemplate: coreClient.CompositeMapper = { +export const JobScale: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobExecutionTemplate", + className: "JobScale", modelProperties: { - containers: { - serializedName: "containers", + pollingInterval: { + serializedName: "pollingInterval", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JobExecutionContainer", - }, - }, + name: "Number", }, }, - initContainers: { - serializedName: "initContainers", + minExecutions: { + defaultValue: 0, + serializedName: "minExecutions", + type: { + name: "Number", + }, + }, + maxExecutions: { + defaultValue: 100, + serializedName: "maxExecutions", + type: { + name: "Number", + }, + }, + rules: { + serializedName: "rules", type: { name: "Sequence", element: { type: { name: "Composite", - className: "JobExecutionContainer", + className: "JobScaleRule", }, }, }, @@ -6569,110 +4548,116 @@ export const JobExecutionTemplate: coreClient.CompositeMapper = { }, }; -export const JobExecutionContainer: coreClient.CompositeMapper = { +export const JobScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobExecutionContainer", + className: "JobScaleRule", modelProperties: { - image: { - serializedName: "image", - type: { - name: "String", - }, - }, name: { serializedName: "name", type: { name: "String", }, }, - command: { - serializedName: "command", + type: { + serializedName: "type", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "String", }, }, - args: { - serializedName: "args", + metadata: { + serializedName: "metadata", type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, + name: "Dictionary", + value: { type: { name: "any" } }, }, }, - env: { - serializedName: "env", + auth: { + serializedName: "auth", type: { name: "Sequence", element: { type: { name: "Composite", - className: "EnvironmentVar", + className: "ScaleRuleAuth", }, }, }, }, - resources: { - serializedName: "resources", + identity: { + serializedName: "identity", type: { - name: "Composite", - className: "ContainerResources", + name: "String", }, }, }, }, }; -export const JobExecutionBase: coreClient.CompositeMapper = { +export const JobTemplate: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobExecutionBase", + className: "JobTemplate", modelProperties: { - name: { - serializedName: "name", + initContainers: { + serializedName: "initContainers", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "InitContainer", + }, + }, }, }, - id: { - serializedName: "id", + containers: { + serializedName: "containers", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Container", + }, + }, + }, + }, + volumes: { + serializedName: "volumes", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Volume", + }, + }, }, }, }, }, }; -export const ContainerAppJobExecutions: coreClient.CompositeMapper = { +export const AvailableOperations: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppJobExecutions", + className: "AvailableOperations", modelProperties: { value: { serializedName: "value", - required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "JobExecution", + className: "OperationDetail", }, }, }, }, nextLink: { serializedName: "nextLink", - readOnly: true, type: { name: "String", }, @@ -6681,10 +4666,10 @@ export const ContainerAppJobExecutions: coreClient.CompositeMapper = { }, }; -export const JobExecution: coreClient.CompositeMapper = { +export const OperationDetail: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JobExecution", + className: "OperationDetail", modelProperties: { name: { serializedName: "name", @@ -6692,150 +4677,142 @@ export const JobExecution: coreClient.CompositeMapper = { name: "String", }, }, - id: { - serializedName: "id", + isDataAction: { + serializedName: "isDataAction", type: { - name: "String", + name: "Boolean", }, }, - type: { - serializedName: "type", + display: { + serializedName: "display", type: { - name: "String", + name: "Composite", + className: "OperationDisplay", }, }, - status: { - serializedName: "properties.status", - readOnly: true, + origin: { + serializedName: "origin", type: { name: "String", }, }, - startTime: { - serializedName: "properties.startTime", + }, + }, +}; + +export const OperationDisplay: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OperationDisplay", + modelProperties: { + provider: { + serializedName: "provider", type: { - name: "DateTime", + name: "String", }, }, - endTime: { - serializedName: "properties.endTime", + resource: { + serializedName: "resource", type: { - name: "DateTime", + name: "String", }, }, - template: { - serializedName: "properties.template", + operation: { + serializedName: "operation", type: { - name: "Composite", - className: "JobExecutionTemplate", + name: "String", }, }, - detailedStatus: { - serializedName: "properties.detailedStatus", + description: { + serializedName: "description", type: { - name: "Composite", - className: "ExecutionStatus", + name: "String", }, }, }, }, }; -export const ExecutionStatus: coreClient.CompositeMapper = { +export const JavaComponentsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ExecutionStatus", + className: "JavaComponentsCollection", modelProperties: { - replicas: { - serializedName: "replicas", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ReplicaExecutionStatus", + className: "JavaComponent", }, }, }, }, - }, - }, -}; - -export const ReplicaExecutionStatus: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ReplicaExecutionStatus", - modelProperties: { - name: { - serializedName: "name", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String", }, }, - containers: { - serializedName: "containers", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerExecutionStatus", - }, - }, - }, - }, }, }, }; -export const ContainerExecutionStatus: coreClient.CompositeMapper = { +export const JavaComponentProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerExecutionStatus", + className: "JavaComponentProperties", + uberParent: "JavaComponentProperties", + polymorphicDiscriminator: { + serializedName: "componentType", + clientName: "componentType", + }, modelProperties: { - name: { - serializedName: "name", + componentType: { + serializedName: "componentType", + required: true, type: { name: "String", }, }, - code: { - serializedName: "code", + provisioningState: { + serializedName: "provisioningState", + readOnly: true, type: { - name: "Number", + name: "String", }, }, - additionalInformation: { - serializedName: "additionalInformation", + configurations: { + serializedName: "configurations", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "JavaComponentConfigurationProperty", + }, + }, }, }, - status: { - serializedName: "status", + scale: { + serializedName: "scale", type: { - name: "String", + name: "Composite", + className: "JavaComponentPropertiesScale", }, }, - }, - }, -}; - -export const JobSecretsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JobSecretsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + serviceBinds: { + serializedName: "serviceBinds", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Secret", + className: "JavaComponentServiceBind", }, }, }, @@ -6844,27 +4821,19 @@ export const JobSecretsCollection: coreClient.CompositeMapper = { }, }; -export const WorkflowEnvelopeCollection: coreClient.CompositeMapper = { +export const JavaComponentConfigurationProperty: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkflowEnvelopeCollection", + className: "JavaComponentConfigurationProperty", modelProperties: { - value: { - serializedName: "value", - required: true, + propertyName: { + serializedName: "propertyName", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "WorkflowEnvelope", - }, - }, + name: "String", }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + value: { + serializedName: "value", type: { name: "String", }, @@ -6873,127 +4842,134 @@ export const WorkflowEnvelopeCollection: coreClient.CompositeMapper = { }, }; -export const WorkflowEnvelope: coreClient.CompositeMapper = { +export const JavaComponentPropertiesScale: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkflowEnvelope", + className: "JavaComponentPropertiesScale", modelProperties: { - id: { - serializedName: "id", - readOnly: true, - type: { - name: "String", - }, - }, - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String", - }, - }, - type: { - serializedName: "type", - readOnly: true, + minReplicas: { + serializedName: "minReplicas", type: { - name: "String", + name: "Number", }, }, - kind: { - serializedName: "kind", + maxReplicas: { + serializedName: "maxReplicas", type: { - name: "String", + name: "Number", }, }, - location: { - serializedName: "location", + }, + }, +}; + +export const JavaComponentServiceBind: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "JavaComponentServiceBind", + modelProperties: { + name: { + serializedName: "name", type: { name: "String", }, }, - properties: { - serializedName: "properties", + serviceId: { + serializedName: "serviceId", type: { - name: "Composite", - className: "WorkflowEnvelopeProperties", + name: "String", }, }, }, }, }; -export const WorkflowEnvelopeProperties: coreClient.CompositeMapper = { +export const JobsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkflowEnvelopeProperties", + className: "JobsCollection", modelProperties: { - files: { - serializedName: "files", + value: { + serializedName: "value", + required: true, type: { - name: "Dictionary", - value: { type: { name: "any" } }, + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Job", + }, + }, }, }, - flowState: { - serializedName: "flowState", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String", }, }, - health: { - serializedName: "health", - type: { - name: "Composite", - className: "WorkflowHealth", - }, - }, }, }, }; -export const WorkflowHealth: coreClient.CompositeMapper = { +export const JobPatchProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkflowHealth", + className: "JobPatchProperties", modelProperties: { - state: { - serializedName: "state", - required: true, + identity: { + serializedName: "identity", type: { - name: "Enum", - allowedValues: ["NotSpecified", "Healthy", "Unhealthy", "Unknown"], + name: "Composite", + className: "ManagedServiceIdentity", }, }, - error: { - serializedName: "error", + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } }, + }, + }, + properties: { + serializedName: "properties", type: { name: "Composite", - className: "ErrorEntity", + className: "JobPatchPropertiesProperties", }, }, }, }, }; -export const ErrorEntity: coreClient.CompositeMapper = { +export const JobPatchPropertiesProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorEntity", + className: "JobPatchPropertiesProperties", modelProperties: { - extendedCode: { - serializedName: "extendedCode", + environmentId: { + serializedName: "environmentId", type: { name: "String", }, }, - messageTemplate: { - serializedName: "messageTemplate", + configuration: { + serializedName: "configuration", type: { - name: "String", + name: "Composite", + className: "JobConfiguration", + }, + }, + template: { + serializedName: "template", + type: { + name: "Composite", + className: "JobTemplate", }, }, - parameters: { - serializedName: "parameters", + outboundIpAddresses: { + serializedName: "outboundIpAddresses", type: { name: "Sequence", element: { @@ -7003,73 +4979,68 @@ export const ErrorEntity: coreClient.CompositeMapper = { }, }, }, - innerErrors: { - serializedName: "innerErrors", + eventStreamEndpoint: { + serializedName: "eventStreamEndpoint", + type: { + name: "String", + }, + }, + }, + }, +}; + +export const JobExecutionTemplate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "JobExecutionTemplate", + modelProperties: { + containers: { + serializedName: "containers", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorEntity", + className: "JobExecutionContainer", }, }, }, }, - details: { - serializedName: "details", + initContainers: { + serializedName: "initContainers", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorEntity", + className: "JobExecutionContainer", }, }, }, }, - target: { - serializedName: "target", - type: { - name: "String", - }, - }, - code: { - serializedName: "code", - type: { - name: "String", - }, - }, - message: { - serializedName: "message", - type: { - name: "String", - }, - }, }, }, }; -export const WorkflowArtifacts: coreClient.CompositeMapper = { +export const JobExecutionContainer: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkflowArtifacts", + className: "JobExecutionContainer", modelProperties: { - appSettings: { - serializedName: "appSettings", + image: { + serializedName: "image", type: { - name: "Dictionary", - value: { type: { name: "any" } }, + name: "String", }, }, - files: { - serializedName: "files", + name: { + serializedName: "name", type: { - name: "Dictionary", - value: { type: { name: "any" } }, + name: "String", }, }, - filesToDelete: { - serializedName: "filesToDelete", + command: { + serializedName: "command", type: { name: "Sequence", element: { @@ -7079,73 +5050,53 @@ export const WorkflowArtifacts: coreClient.CompositeMapper = { }, }, }, - }, - }, -}; - -export const ManagedEnvironmentsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ManagedEnvironmentsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + args: { + serializedName: "args", + type: { + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + env: { + serializedName: "env", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ManagedEnvironment", + className: "EnvironmentVar", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + resources: { + serializedName: "resources", type: { - name: "String", + name: "Composite", + className: "ContainerResources", }, }, }, }, }; -export const ManagedCertificateProperties: coreClient.CompositeMapper = { +export const JobExecutionBase: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedCertificateProperties", + className: "JobExecutionBase", modelProperties: { - provisioningState: { - serializedName: "provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - subjectName: { - serializedName: "subjectName", - type: { - name: "String", - }, - }, - error: { - serializedName: "error", - readOnly: true, - type: { - name: "String", - }, - }, - domainControlValidation: { - serializedName: "domainControlValidation", + name: { + serializedName: "name", type: { name: "String", }, }, - validationToken: { - serializedName: "validationToken", - readOnly: true, + id: { + serializedName: "id", type: { name: "String", }, @@ -7154,26 +5105,10 @@ export const ManagedCertificateProperties: coreClient.CompositeMapper = { }, }; -export const ManagedCertificatePatch: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ManagedCertificatePatch", - modelProperties: { - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - }, - }, -}; - -export const ManagedCertificateCollection: coreClient.CompositeMapper = { +export const ContainerAppJobExecutions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedCertificateCollection", + className: "ContainerAppJobExecutions", modelProperties: { value: { serializedName: "value", @@ -7183,7 +5118,7 @@ export const ManagedCertificateCollection: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ManagedCertificate", + className: "JobExecution", }, }, }, @@ -7199,103 +5134,95 @@ export const ManagedCertificateCollection: coreClient.CompositeMapper = { }, }; -export const WorkloadProfileStatesCollection: coreClient.CompositeMapper = { +export const JobExecution: coreClient.CompositeMapper = { type: { name: "Composite", - className: "WorkloadProfileStatesCollection", + className: "JobExecution", modelProperties: { - value: { - serializedName: "value", - required: true, + name: { + serializedName: "name", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "WorkloadProfileStates", - }, - }, + name: "String", }, }, - nextLink: { - serializedName: "nextLink", + id: { + serializedName: "id", + type: { + name: "String", + }, + }, + type: { + serializedName: "type", + type: { + name: "String", + }, + }, + status: { + serializedName: "properties.status", readOnly: true, type: { name: "String", }, }, - }, - }, -}; - -export const WorkloadProfileStatesProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "WorkloadProfileStatesProperties", - modelProperties: { - minimumCount: { - serializedName: "minimumCount", + startTime: { + serializedName: "properties.startTime", type: { - name: "Number", + name: "DateTime", }, }, - maximumCount: { - serializedName: "maximumCount", + endTime: { + serializedName: "properties.endTime", type: { - name: "Number", + name: "DateTime", }, }, - currentCount: { - serializedName: "currentCount", + template: { + serializedName: "properties.template", type: { - name: "Number", + name: "Composite", + className: "JobExecutionTemplate", }, }, }, }, }; -export const PrivateEndpointConnectionListResult: coreClient.CompositeMapper = { +export const JobSecretsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateEndpointConnectionListResult", + className: "JobSecretsCollection", modelProperties: { value: { serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "PrivateEndpointConnection", + className: "Secret", }, }, }, }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, - }, }, }, }; -export const PrivateLinkResourceListResult: coreClient.CompositeMapper = { +export const ManagedEnvironmentsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateLinkResourceListResult", + className: "ManagedEnvironmentsCollection", modelProperties: { value: { serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "PrivateLinkResource", + className: "ManagedEnvironment", }, }, }, @@ -7311,165 +5238,68 @@ export const PrivateLinkResourceListResult: coreClient.CompositeMapper = { }, }; -export const DaprComponentResiliencyPoliciesCollection: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprComponentResiliencyPoliciesCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicy", - }, - }, - }, - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String", - }, +export const ManagedCertificateProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ManagedCertificateProperties", + modelProperties: { + provisioningState: { + serializedName: "provisioningState", + readOnly: true, + type: { + name: "String", }, }, - }, - }; - -export const DaprComponentResiliencyPolicyConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyConfiguration", - modelProperties: { - httpRetryPolicy: { - serializedName: "httpRetryPolicy", - type: { - name: "Composite", - className: - "DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration", - }, - }, - timeoutPolicy: { - serializedName: "timeoutPolicy", - type: { - name: "Composite", - className: - "DaprComponentResiliencyPolicyTimeoutPolicyConfiguration", - }, - }, - circuitBreakerPolicy: { - serializedName: "circuitBreakerPolicy", - type: { - name: "Composite", - className: - "DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration", - }, + subjectName: { + serializedName: "subjectName", + type: { + name: "String", }, }, - }, - }; - -export const DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyHttpRetryPolicyConfiguration", - modelProperties: { - maxRetries: { - serializedName: "maxRetries", - type: { - name: "Number", - }, - }, - retryBackOff: { - serializedName: "retryBackOff", - type: { - name: "Composite", - className: - "DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration", - }, + error: { + serializedName: "error", + readOnly: true, + type: { + name: "String", }, }, - }, - }; - -export const DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyHttpRetryBackOffConfiguration", - modelProperties: { - initialDelayInMilliseconds: { - serializedName: "initialDelayInMilliseconds", - type: { - name: "Number", - }, - }, - maxIntervalInMilliseconds: { - serializedName: "maxIntervalInMilliseconds", - type: { - name: "Number", - }, + domainControlValidation: { + serializedName: "domainControlValidation", + type: { + name: "String", }, }, - }, - }; - -export const DaprComponentResiliencyPolicyTimeoutPolicyConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyTimeoutPolicyConfiguration", - modelProperties: { - responseTimeoutInSeconds: { - serializedName: "responseTimeoutInSeconds", - type: { - name: "Number", - }, + validationToken: { + serializedName: "validationToken", + readOnly: true, + type: { + name: "String", }, }, }, - }; + }, +}; -export const DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: - "DaprComponentResiliencyPolicyCircuitBreakerPolicyConfiguration", - modelProperties: { - consecutiveErrors: { - serializedName: "consecutiveErrors", - type: { - name: "Number", - }, - }, - timeoutInSeconds: { - serializedName: "timeoutInSeconds", - type: { - name: "Number", - }, - }, - intervalInSeconds: { - serializedName: "intervalInSeconds", - type: { - name: "Number", - }, +export const ManagedCertificatePatch: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ManagedCertificatePatch", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } }, }, }, }, - }; + }, +}; -export const DaprSubscriptionsCollection: coreClient.CompositeMapper = { +export const ManagedCertificateCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprSubscriptionsCollection", + className: "ManagedCertificateCollection", modelProperties: { value: { serializedName: "value", @@ -7479,7 +5309,7 @@ export const DaprSubscriptionsCollection: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "DaprSubscription", + className: "ManagedCertificate", }, }, }, @@ -7495,25 +5325,27 @@ export const DaprSubscriptionsCollection: coreClient.CompositeMapper = { }, }; -export const DaprSubscriptionRoutes: coreClient.CompositeMapper = { +export const WorkloadProfileStatesCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprSubscriptionRoutes", + className: "WorkloadProfileStatesCollection", modelProperties: { - rules: { - serializedName: "rules", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "DaprSubscriptionRouteRule", + className: "WorkloadProfileStates", }, }, }, }, - default: { - serializedName: "default", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String", }, @@ -7522,55 +5354,32 @@ export const DaprSubscriptionRoutes: coreClient.CompositeMapper = { }, }; -export const DaprSubscriptionRouteRule: coreClient.CompositeMapper = { +export const WorkloadProfileStatesProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprSubscriptionRouteRule", + className: "WorkloadProfileStatesProperties", modelProperties: { - match: { - serializedName: "match", + minimumCount: { + serializedName: "minimumCount", type: { - name: "String", + name: "Number", }, }, - path: { - serializedName: "path", + maximumCount: { + serializedName: "maximumCount", type: { - name: "String", + name: "Number", }, }, - }, - }, -}; - -export const DaprSubscriptionBulkSubscribeOptions: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "DaprSubscriptionBulkSubscribeOptions", - modelProperties: { - enabled: { - defaultValue: false, - serializedName: "enabled", - type: { - name: "Boolean", - }, - }, - maxMessagesCount: { - serializedName: "maxMessagesCount", - type: { - name: "Number", - }, - }, - maxAwaitDurationMs: { - serializedName: "maxAwaitDurationMs", - type: { - name: "Number", - }, + currentCount: { + serializedName: "currentCount", + type: { + name: "Number", }, }, }, - }; + }, +}; export const ManagedEnvironmentStoragesCollection: coreClient.CompositeMapper = { @@ -7721,8 +5530,24 @@ export const DynamicPoolConfiguration: coreClient.CompositeMapper = { name: "Composite", className: "DynamicPoolConfiguration", modelProperties: { - executionType: { - serializedName: "executionType", + lifecycleConfiguration: { + serializedName: "lifecycleConfiguration", + type: { + name: "Composite", + className: "LifecycleConfiguration", + }, + }, + }, + }, +}; + +export const LifecycleConfiguration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "LifecycleConfiguration", + modelProperties: { + lifecycleType: { + serializedName: "lifecycleType", type: { name: "String", }, @@ -7733,6 +5558,12 @@ export const DynamicPoolConfiguration: coreClient.CompositeMapper = { name: "Number", }, }, + maxAlivePeriodInSeconds: { + serializedName: "maxAlivePeriodInSeconds", + type: { + name: "Number", + }, + }, }, }, }; @@ -7893,23 +5724,46 @@ export const SessionIngress: coreClient.CompositeMapper = { name: "Composite", className: "SessionIngress", modelProperties: { - targetPort: { - serializedName: "targetPort", + targetPort: { + serializedName: "targetPort", + type: { + name: "Number", + }, + }, + }, + }, +}; + +export const SessionNetworkConfiguration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SessionNetworkConfiguration", + modelProperties: { + status: { + serializedName: "status", type: { - name: "Number", + name: "String", }, }, }, }, }; -export const SessionNetworkConfiguration: coreClient.CompositeMapper = { +export const ManagedIdentitySetting: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SessionNetworkConfiguration", + className: "ManagedIdentitySetting", modelProperties: { - status: { - serializedName: "status", + identity: { + serializedName: "identity", + required: true, + type: { + name: "String", + }, + }, + lifecycle: { + defaultValue: "None", + serializedName: "lifecycle", type: { name: "String", }, @@ -7923,6 +5777,20 @@ export const SessionPoolUpdatableProperties: coreClient.CompositeMapper = { name: "Composite", className: "SessionPoolUpdatableProperties", modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } }, + }, + }, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ManagedServiceIdentity", + }, + }, scaleConfiguration: { serializedName: "properties.scaleConfiguration", type: { @@ -8021,12 +5889,6 @@ export const GithubActionConfiguration: coreClient.CompositeMapper = { name: "String", }, }, - dockerfilePath: { - serializedName: "dockerfilePath", - type: { - name: "String", - }, - }, githubPersonalAccessToken: { serializedName: "githubPersonalAccessToken", type: { @@ -8063,18 +5925,6 @@ export const GithubActionConfiguration: coreClient.CompositeMapper = { name: "String", }, }, - buildEnvironmentVariables: { - serializedName: "buildEnvironmentVariables", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "EnvironmentVariable", - }, - }, - }, - }, }, }, }; @@ -8231,57 +6081,6 @@ export const UsageName: coreClient.CompositeMapper = { }, }; -export const ScgRoute: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ScgRoute", - modelProperties: { - id: { - serializedName: "id", - required: true, - type: { - name: "String", - }, - }, - uri: { - serializedName: "uri", - required: true, - type: { - name: "String", - }, - }, - predicates: { - serializedName: "predicates", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - filters: { - serializedName: "filters", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - order: { - serializedName: "order", - type: { - name: "Number", - }, - }, - }, - }, -}; - export const JavaComponentIngress: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8354,89 +6153,6 @@ export const TrackedResource: coreClient.CompositeMapper = { }, }; -export const PrivateEndpointConnection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PrivateEndpointConnection", - modelProperties: { - ...Resource.type.modelProperties, - groupIds: { - serializedName: "properties.groupIds", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - privateEndpoint: { - serializedName: "properties.privateEndpoint", - type: { - name: "Composite", - className: "PrivateEndpoint", - }, - }, - privateLinkServiceConnectionState: { - serializedName: "properties.privateLinkServiceConnectionState", - type: { - name: "Composite", - className: "PrivateLinkServiceConnectionState", - }, - }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const PrivateLinkResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PrivateLinkResource", - modelProperties: { - ...Resource.type.modelProperties, - groupId: { - serializedName: "properties.groupId", - readOnly: true, - type: { - name: "String", - }, - }, - requiredMembers: { - serializedName: "properties.requiredMembers", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - requiredZoneNames: { - serializedName: "properties.requiredZoneNames", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - }, - }, -}; - export const InitContainer: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8469,39 +6185,6 @@ export const Container: coreClient.CompositeMapper = { }, }; -export const SpringCloudGatewayComponent: coreClient.CompositeMapper = { - serializedName: "SpringCloudGateway", - type: { - name: "Composite", - className: "SpringCloudGatewayComponent", - uberParent: "JavaComponentProperties", - polymorphicDiscriminator: - JavaComponentProperties.type.polymorphicDiscriminator, - modelProperties: { - ...JavaComponentProperties.type.modelProperties, - ingress: { - serializedName: "ingress", - type: { - name: "Composite", - className: "JavaComponentIngress", - }, - }, - springCloudGatewayRoutes: { - serializedName: "springCloudGatewayRoutes", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScgRoute", - }, - }, - }, - }, - }, - }, -}; - export const SpringBootAdminComponent: coreClient.CompositeMapper = { serializedName: "SpringBootAdmin", type: { @@ -8523,27 +6206,6 @@ export const SpringBootAdminComponent: coreClient.CompositeMapper = { }, }; -export const NacosComponent: coreClient.CompositeMapper = { - serializedName: "Nacos", - type: { - name: "Composite", - className: "NacosComponent", - uberParent: "JavaComponentProperties", - polymorphicDiscriminator: - JavaComponentProperties.type.polymorphicDiscriminator, - modelProperties: { - ...JavaComponentProperties.type.modelProperties, - ingress: { - serializedName: "ingress", - type: { - name: "Composite", - className: "JavaComponentIngress", - }, - }, - }, - }, -}; - export const SpringCloudEurekaComponent: coreClient.CompositeMapper = { serializedName: "SpringCloudEureka", type: { @@ -8579,58 +6241,6 @@ export const SpringCloudConfigComponent: coreClient.CompositeMapper = { }, }; -export const AppResiliency: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AppResiliency", - modelProperties: { - ...ProxyResource.type.modelProperties, - timeoutPolicy: { - serializedName: "properties.timeoutPolicy", - type: { - name: "Composite", - className: "TimeoutPolicy", - }, - }, - httpRetryPolicy: { - serializedName: "properties.httpRetryPolicy", - type: { - name: "Composite", - className: "HttpRetryPolicy", - }, - }, - tcpRetryPolicy: { - serializedName: "properties.tcpRetryPolicy", - type: { - name: "Composite", - className: "TcpRetryPolicy", - }, - }, - circuitBreakerPolicy: { - serializedName: "properties.circuitBreakerPolicy", - type: { - name: "Composite", - className: "CircuitBreakerPolicy", - }, - }, - httpConnectionPool: { - serializedName: "properties.httpConnectionPool", - type: { - name: "Composite", - className: "HttpConnectionPool", - }, - }, - tcpConnectionPool: { - serializedName: "properties.tcpConnectionPool", - type: { - name: "Composite", - className: "TcpConnectionPool", - }, - }, - }, - }, -}; - export const AuthConfig: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8695,70 +6305,34 @@ export const AvailableWorkloadProfile: coreClient.CompositeMapper = { name: "String", }, }, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "AvailableWorkloadProfileProperties", - }, - }, - }, - }, -}; - -export const BuildResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildResource", - modelProperties: { - ...ProxyResource.type.modelProperties, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - buildStatus: { - serializedName: "properties.buildStatus", - readOnly: true, - type: { - name: "String", - }, - }, - destinationContainerRegistry: { - serializedName: "properties.destinationContainerRegistry", - type: { - name: "Composite", - className: "ContainerRegistryWithCustomImage", - }, - }, - configuration: { - serializedName: "properties.configuration", + properties: { + serializedName: "properties", type: { name: "Composite", - className: "BuildConfiguration", - }, - }, - uploadEndpoint: { - serializedName: "properties.uploadEndpoint", - readOnly: true, - type: { - name: "String", + className: "AvailableWorkloadProfileProperties", }, }, - logStreamEndpoint: { - serializedName: "properties.logStreamEndpoint", - readOnly: true, + }, + }, +}; + +export const BillingMeter: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BillingMeter", + modelProperties: { + ...ProxyResource.type.modelProperties, + location: { + serializedName: "location", type: { name: "String", }, }, - tokenEndpoint: { - serializedName: "properties.tokenEndpoint", - readOnly: true, + properties: { + serializedName: "properties", type: { - name: "String", + name: "Composite", + className: "BillingMeterProperties", }, }, }, @@ -8837,18 +6411,6 @@ export const DaprComponent: coreClient.CompositeMapper = { }, }, }, - serviceComponentBind: { - serializedName: "properties.serviceComponentBind", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DaprComponentServiceBinding", - }, - }, - }, - }, }, }, }; @@ -8870,68 +6432,6 @@ export const ConnectedEnvironmentStorage: coreClient.CompositeMapper = { }, }; -export const ContainerAppsBuildResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsBuildResource", - modelProperties: { - ...ProxyResource.type.modelProperties, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - buildStatus: { - serializedName: "properties.buildStatus", - readOnly: true, - type: { - name: "String", - }, - }, - destinationContainerRegistry: { - serializedName: "properties.destinationContainerRegistry", - type: { - name: "Composite", - className: "ContainerRegistryWithCustomImage", - }, - }, - configuration: { - serializedName: "properties.configuration", - type: { - name: "Composite", - className: "ContainerAppsBuildConfiguration", - }, - }, - logStreamEndpoint: { - serializedName: "properties.logStreamEndpoint", - readOnly: true, - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppsPatchResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsPatchResource", - modelProperties: { - ...ProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "PatchProperties", - }, - }, - }, - }, -}; - export const Revision: coreClient.CompositeMapper = { type: { name: "Composite", @@ -9091,53 +6591,6 @@ export const Diagnostics: coreClient.CompositeMapper = { }, }; -export const DotNetComponent: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DotNetComponent", - modelProperties: { - ...ProxyResource.type.modelProperties, - componentType: { - serializedName: "properties.componentType", - type: { - name: "String", - }, - }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - configurations: { - serializedName: "properties.configurations", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DotNetComponentConfigurationProperty", - }, - }, - }, - }, - serviceBinds: { - serializedName: "properties.serviceBinds", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DotNetComponentServiceBind", - }, - }, - }, - }, - }, - }, -}; - export const JavaComponent: coreClient.CompositeMapper = { type: { name: "Composite", @@ -9155,23 +6608,6 @@ export const JavaComponent: coreClient.CompositeMapper = { }, }; -export const LogicApp: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "LogicApp", - modelProperties: { - ...ProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Dictionary", - value: { type: { name: "any" } }, - }, - }, - }, - }, -}; - export const WorkloadProfileStates: coreClient.CompositeMapper = { type: { name: "Composite", @@ -9189,90 +6625,6 @@ export const WorkloadProfileStates: coreClient.CompositeMapper = { }, }; -export const DaprComponentResiliencyPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicy", - modelProperties: { - ...ProxyResource.type.modelProperties, - inboundPolicy: { - serializedName: "properties.inboundPolicy", - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyConfiguration", - }, - }, - outboundPolicy: { - serializedName: "properties.outboundPolicy", - type: { - name: "Composite", - className: "DaprComponentResiliencyPolicyConfiguration", - }, - }, - }, - }, -}; - -export const DaprSubscription: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprSubscription", - modelProperties: { - ...ProxyResource.type.modelProperties, - pubsubName: { - serializedName: "properties.pubsubName", - type: { - name: "String", - }, - }, - topic: { - serializedName: "properties.topic", - type: { - name: "String", - }, - }, - deadLetterTopic: { - serializedName: "properties.deadLetterTopic", - type: { - name: "String", - }, - }, - routes: { - serializedName: "properties.routes", - type: { - name: "Composite", - className: "DaprSubscriptionRoutes", - }, - }, - scopes: { - serializedName: "properties.scopes", - type: { - name: "Sequence", - element: { - type: { - name: "String", - }, - }, - }, - }, - metadata: { - serializedName: "properties.metadata", - type: { - name: "Dictionary", - value: { type: { name: "String" } }, - }, - }, - bulkSubscribe: { - serializedName: "properties.bulkSubscribe", - type: { - name: "Composite", - className: "DaprSubscriptionBulkSubscribeOptions", - }, - }, - }, - }, -}; - export const ManagedEnvironmentStorage: coreClient.CompositeMapper = { type: { name: "Composite", @@ -9314,54 +6666,12 @@ export const SourceControl: coreClient.CompositeMapper = { type: { name: "String", }, - }, - githubActionConfiguration: { - serializedName: "properties.githubActionConfiguration", - type: { - name: "Composite", - className: "GithubActionConfiguration", - }, - }, - }, - }, -}; - -export const BuilderResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuilderResource", - modelProperties: { - ...TrackedResource.type.modelProperties, - identity: { - serializedName: "identity", - type: { - name: "Composite", - className: "ManagedServiceIdentity", - }, - }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String", - }, - }, - environmentId: { - serializedName: "properties.environmentId", - type: { - name: "String", - }, - }, - containerRegistries: { - serializedName: "properties.containerRegistries", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerRegistry", - }, - }, + }, + githubActionConfiguration: { + serializedName: "properties.githubActionConfiguration", + type: { + name: "Composite", + className: "GithubActionConfiguration", }, }, }, @@ -9468,12 +6778,6 @@ export const ContainerApp: coreClient.CompositeMapper = { name: "String", }, }, - kind: { - serializedName: "kind", - type: { - name: "String", - }, - }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, @@ -9481,8 +6785,8 @@ export const ContainerApp: coreClient.CompositeMapper = { name: "String", }, }, - deploymentErrors: { - serializedName: "properties.deploymentErrors", + runningStatus: { + serializedName: "properties.runningStatus", readOnly: true, type: { name: "String", @@ -9506,13 +6810,6 @@ export const ContainerApp: coreClient.CompositeMapper = { name: "String", }, }, - patchingConfiguration: { - serializedName: "properties.patchingConfiguration", - type: { - name: "Composite", - className: "ContainerAppPropertiesPatchingConfiguration", - }, - }, latestRevisionName: { serializedName: "properties.latestRevisionName", readOnly: true, @@ -9675,20 +6972,6 @@ export const ManagedEnvironment: coreClient.CompositeMapper = { className: "AppLogsConfiguration", }, }, - appInsightsConfiguration: { - serializedName: "properties.appInsightsConfiguration", - type: { - name: "Composite", - className: "AppInsightsConfiguration", - }, - }, - openTelemetryConfiguration: { - serializedName: "properties.openTelemetryConfiguration", - type: { - name: "Composite", - className: "OpenTelemetryConfiguration", - }, - }, zoneRedundant: { serializedName: "properties.zoneRedundant", type: { @@ -9755,25 +7038,6 @@ export const ManagedEnvironment: coreClient.CompositeMapper = { className: "ManagedEnvironmentPropertiesPeerTrafficConfiguration", }, }, - privateEndpointConnections: { - serializedName: "properties.privateEndpointConnections", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PrivateEndpointConnection", - }, - }, - }, - }, - publicNetworkAccess: { - serializedName: "properties.publicNetworkAccess", - type: { - name: "String", - }, - }, }, }, }; @@ -9784,13 +7048,6 @@ export const Job: coreClient.CompositeMapper = { className: "Job", modelProperties: { ...TrackedResource.type.modelProperties, - extendedLocation: { - serializedName: "extendedLocation", - type: { - name: "Composite", - className: "ExtendedLocation", - }, - }, identity: { serializedName: "identity", type: { @@ -9805,13 +7062,6 @@ export const Job: coreClient.CompositeMapper = { name: "String", }, }, - runningState: { - serializedName: "properties.runningState", - readOnly: true, - type: { - name: "String", - }, - }, environmentId: { serializedName: "properties.environmentId", type: { @@ -9908,6 +7158,13 @@ export const SessionPool: coreClient.CompositeMapper = { className: "SessionPool", modelProperties: { ...TrackedResource.type.modelProperties, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ManagedServiceIdentity", + }, + }, environmentId: { serializedName: "properties.environmentId", type: { @@ -9987,79 +7244,16 @@ export const SessionPool: coreClient.CompositeMapper = { name: "String", }, }, - }, - }, -}; - -export const BuildersCreateOrUpdateHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildersCreateOrUpdateHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const BuildersUpdateHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildersUpdateHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const BuildersDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildersDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const BuildsCreateOrUpdateHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildsCreateOrUpdateHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const BuildsDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BuildsDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", + managedIdentitySettings: { + serializedName: "properties.managedIdentitySettings", type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ManagedIdentitySetting", + }, + }, }, }, }, @@ -10141,73 +7335,6 @@ export const ContainerAppsStopHeaders: coreClient.CompositeMapper = { }, }; -export const ContainerAppsBuildsDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsBuildsDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppsPatchesDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsPatchesDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const ContainerAppsPatchesSkipConfigureHeaders: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ContainerAppsPatchesSkipConfigureHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, - }; - -export const ContainerAppsPatchesApplyHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppsPatchesApplyHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String", - }, - }, - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - export const JobsDeleteHeaders: coreClient.CompositeMapper = { type: { name: "Composite", @@ -10283,78 +7410,6 @@ export const JobsStopMultipleExecutionsHeaders: coreClient.CompositeMapper = { }, }; -export const JobsResumeHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JobsResumeHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String", - }, - }, - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const JobsSuspendHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JobsSuspendHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String", - }, - }, - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const DotNetComponentsUpdateHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DotNetComponentsUpdateHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - -export const DotNetComponentsDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DotNetComponentsDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, -}; - export const JavaComponentsUpdateHeaders: coreClient.CompositeMapper = { type: { name: "Composite", @@ -10385,22 +7440,6 @@ export const JavaComponentsDeleteHeaders: coreClient.CompositeMapper = { }, }; -export const ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders: coreClient.CompositeMapper = - { - type: { - name: "Composite", - className: "ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String", - }, - }, - }, - }, - }; - export const ContainerAppsSessionPoolsUpdateHeaders: coreClient.CompositeMapper = { type: { @@ -10435,9 +7474,7 @@ export const ContainerAppsSessionPoolsDeleteHeaders: coreClient.CompositeMapper export let discriminators = { JavaComponentProperties: JavaComponentProperties, - "JavaComponentProperties.SpringCloudGateway": SpringCloudGatewayComponent, "JavaComponentProperties.SpringBootAdmin": SpringBootAdminComponent, - "JavaComponentProperties.Nacos": NacosComponent, "JavaComponentProperties.SpringCloudEureka": SpringCloudEurekaComponent, "JavaComponentProperties.SpringCloudConfig": SpringCloudConfigComponent, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/models/parameters.ts b/sdk/appcontainers/arm-appcontainers/src/models/parameters.ts index b2ca7cc67a9c..a9f57bc673ff 100644 --- a/sdk/appcontainers/arm-appcontainers/src/models/parameters.ts +++ b/sdk/appcontainers/arm-appcontainers/src/models/parameters.ts @@ -12,11 +12,7 @@ import { OperationQueryParameter, } from "@azure/core-client"; import { - AppResiliency as AppResiliencyMapper, AuthConfig as AuthConfigMapper, - BuilderResource as BuilderResourceMapper, - BuilderResourceUpdate as BuilderResourceUpdateMapper, - BuildResource as BuildResourceMapper, ConnectedEnvironment as ConnectedEnvironmentMapper, CheckNameAvailabilityRequest as CheckNameAvailabilityRequestMapper, Certificate as CertificateMapper, @@ -24,43 +20,19 @@ import { DaprComponent as DaprComponentMapper, ConnectedEnvironmentStorage as ConnectedEnvironmentStorageMapper, ContainerApp as ContainerAppMapper, - PatchSkipConfig as PatchSkipConfigMapper, Job as JobMapper, JobPatchProperties as JobPatchPropertiesMapper, JobExecutionTemplate as JobExecutionTemplateMapper, - DotNetComponent as DotNetComponentMapper, JavaComponent as JavaComponentMapper, - LogicApp as LogicAppMapper, - WorkflowArtifacts as WorkflowArtifactsMapper, ManagedEnvironment as ManagedEnvironmentMapper, ManagedCertificate as ManagedCertificateMapper, ManagedCertificatePatch as ManagedCertificatePatchMapper, - PrivateEndpointConnection as PrivateEndpointConnectionMapper, - DaprComponentResiliencyPolicy as DaprComponentResiliencyPolicyMapper, - DaprSubscription as DaprSubscriptionMapper, ManagedEnvironmentStorage as ManagedEnvironmentStorageMapper, SessionPool as SessionPoolMapper, SessionPoolUpdatableProperties as SessionPoolUpdatablePropertiesMapper, SourceControl as SourceControlMapper, } from "../models/mappers.js"; -export const contentType: OperationParameter = { - parameterPath: ["options", "contentType"], - mapper: { - defaultValue: "application/json", - isConstant: true, - serializedName: "Content-Type", - type: { - name: "String", - }, - }, -}; - -export const resiliencyEnvelope: OperationParameter = { - parameterPath: "resiliencyEnvelope", - mapper: AppResiliencyMapper, -}; - export const accept: OperationParameter = { parameterPath: "accept", mapper: { @@ -88,10 +60,13 @@ export const $host: OperationURLParameter = { export const subscriptionId: OperationURLParameter = { parameterPath: "subscriptionId", mapper: { + constraints: { + MinLength: 1, + }, serializedName: "subscriptionId", required: true, type: { - name: "Uuid", + name: "String", }, }, }; @@ -111,27 +86,10 @@ export const resourceGroupName: OperationURLParameter = { }, }; -export const appName: OperationURLParameter = { - parameterPath: "appName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - }, - serializedName: "appName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const name: OperationURLParameter = { - parameterPath: "name", +export const containerAppName: OperationURLParameter = { + parameterPath: "containerAppName", mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - }, - serializedName: "name", + serializedName: "containerAppName", required: true, type: { name: "String", @@ -142,7 +100,7 @@ export const name: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2024-08-02-preview", + defaultValue: "2025-01-01", isConstant: true, serializedName: "api-version", type: { @@ -151,22 +109,10 @@ export const apiVersion: OperationQueryParameter = { }, }; -export const nextLink: OperationURLParameter = { - parameterPath: "nextLink", - mapper: { - serializedName: "nextLink", - required: true, - type: { - name: "String", - }, - }, - skipEncoding: true, -}; - -export const containerAppName: OperationURLParameter = { - parameterPath: "containerAppName", +export const authConfigName: OperationURLParameter = { + parameterPath: "authConfigName", mapper: { - serializedName: "containerAppName", + serializedName: "authConfigName", required: true, type: { name: "String", @@ -174,11 +120,12 @@ export const containerAppName: OperationURLParameter = { }, }; -export const authConfigName: OperationURLParameter = { - parameterPath: "authConfigName", +export const contentType: OperationParameter = { + parameterPath: ["options", "contentType"], mapper: { - serializedName: "authConfigName", - required: true, + defaultValue: "application/json", + isConstant: true, + serializedName: "Content-Type", type: { name: "String", }, @@ -190,55 +137,25 @@ export const authConfigEnvelope: OperationParameter = { mapper: AuthConfigMapper, }; -export const location: OperationURLParameter = { - parameterPath: "location", - mapper: { - constraints: { - MinLength: 1, - }, - serializedName: "location", - required: true, - type: { - name: "String", - }, - }, -}; - -export const builderName: OperationURLParameter = { - parameterPath: "builderName", +export const nextLink: OperationURLParameter = { + parameterPath: "nextLink", mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - MaxLength: 32, - MinLength: 2, - }, - serializedName: "builderName", + serializedName: "nextLink", required: true, type: { name: "String", }, }, + skipEncoding: true, }; -export const builderEnvelope: OperationParameter = { - parameterPath: "builderEnvelope", - mapper: BuilderResourceMapper, -}; - -export const builderEnvelope1: OperationParameter = { - parameterPath: "builderEnvelope", - mapper: BuilderResourceUpdateMapper, -}; - -export const buildName: OperationURLParameter = { - parameterPath: "buildName", +export const location: OperationURLParameter = { + parameterPath: "location", mapper: { constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - MaxLength: 64, - MinLength: 2, + MinLength: 1, }, - serializedName: "buildName", + serializedName: "location", required: true, type: { name: "String", @@ -246,11 +163,6 @@ export const buildName: OperationURLParameter = { }, }; -export const buildEnvelope: OperationParameter = { - parameterPath: "buildEnvelope", - mapper: BuildResourceMapper, -}; - export const connectedEnvironmentName: OperationURLParameter = { parameterPath: "connectedEnvironmentName", mapper: { @@ -364,27 +276,6 @@ export const filter: OperationQueryParameter = { }, }; -export const patchName: OperationURLParameter = { - parameterPath: "patchName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - MaxLength: 64, - MinLength: 2, - }, - serializedName: "patchName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const patchSkipConfig: OperationParameter = { - parameterPath: "patchSkipConfig", - mapper: PatchSkipConfigMapper, -}; - export const revisionName: OperationURLParameter = { parameterPath: "revisionName", mapper: { @@ -514,32 +405,13 @@ export const environmentName1: OperationURLParameter = { }, }; -export const dotNetComponentEnvelope: OperationParameter = { - parameterPath: "dotNetComponentEnvelope", - mapper: DotNetComponentMapper, -}; - -export const revisionName1: OperationURLParameter = { - parameterPath: "revisionName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - }, - serializedName: "revisionName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const functionAppName: OperationURLParameter = { - parameterPath: "functionAppName", +export const name: OperationURLParameter = { + parameterPath: "name", mapper: { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), }, - serializedName: "functionAppName", + serializedName: "name", required: true, type: { name: "String", @@ -552,68 +424,6 @@ export const javaComponentEnvelope: OperationParameter = { mapper: JavaComponentMapper, }; -export const logicAppName: OperationURLParameter = { - parameterPath: "logicAppName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - }, - serializedName: "logicAppName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const resource: OperationParameter = { - parameterPath: "resource", - mapper: LogicAppMapper, -}; - -export const workflowName: OperationURLParameter = { - parameterPath: "workflowName", - mapper: { - constraints: { - Pattern: new RegExp("^[a-z][a-z0-9]*$"), - MaxLength: 63, - MinLength: 3, - }, - serializedName: "workflowName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const workflowArtifacts: OperationParameter = { - parameterPath: ["options", "workflowArtifacts"], - mapper: WorkflowArtifactsMapper, -}; - -export const xMsLogicAppsProxyPath: OperationParameter = { - parameterPath: "xMsLogicAppsProxyPath", - mapper: { - serializedName: "x-ms-logicApps-proxy-path", - required: true, - type: { - name: "String", - }, - }, -}; - -export const xMsLogicAppsProxyMethod: OperationParameter = { - parameterPath: "xMsLogicAppsProxyMethod", - mapper: { - serializedName: "x-ms-logicApps-proxy-method", - required: true, - type: { - name: "String", - }, - }, -}; - export const environmentEnvelope1: OperationParameter = { parameterPath: "environmentEnvelope", mapper: ManagedEnvironmentMapper, @@ -640,57 +450,6 @@ export const managedCertificateEnvelope1: OperationParameter = { mapper: ManagedCertificatePatchMapper, }; -export const privateEndpointConnectionName: OperationURLParameter = { - parameterPath: "privateEndpointConnectionName", - mapper: { - serializedName: "privateEndpointConnectionName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const privateEndpointConnectionEnvelope: OperationParameter = { - parameterPath: "privateEndpointConnectionEnvelope", - mapper: PrivateEndpointConnectionMapper, -}; - -export const componentName1: OperationURLParameter = { - parameterPath: "componentName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - }, - serializedName: "componentName", - required: true, - type: { - name: "String", - }, - }, -}; - -export const name1: OperationURLParameter = { - parameterPath: "name", - mapper: { - serializedName: "name", - required: true, - type: { - name: "String", - }, - }, -}; - -export const daprComponentResiliencyPolicyEnvelope: OperationParameter = { - parameterPath: "daprComponentResiliencyPolicyEnvelope", - mapper: DaprComponentResiliencyPolicyMapper, -}; - -export const daprSubscriptionEnvelope: OperationParameter = { - parameterPath: "daprSubscriptionEnvelope", - mapper: DaprSubscriptionMapper, -}; - export const storageEnvelope1: OperationParameter = { parameterPath: "storageEnvelope", mapper: ManagedEnvironmentStorageMapper, @@ -738,36 +497,6 @@ export const sourceControlEnvelope: OperationParameter = { mapper: SourceControlMapper, }; -export const xMsGithubAuxiliary: OperationParameter = { - parameterPath: ["options", "xMsGithubAuxiliary"], - mapper: { - serializedName: "x-ms-github-auxiliary", - type: { - name: "String", - }, - }, -}; - -export const ignoreWorkflowDeletionFailure: OperationQueryParameter = { - parameterPath: ["options", "ignoreWorkflowDeletionFailure"], - mapper: { - serializedName: "ignoreWorkflowDeletionFailure", - type: { - name: "Boolean", - }, - }, -}; - -export const deleteWorkflow: OperationQueryParameter = { - parameterPath: ["options", "deleteWorkflow"], - mapper: { - serializedName: "deleteWorkflow", - type: { - name: "Boolean", - }, - }, -}; - export const location1: OperationURLParameter = { parameterPath: "location", mapper: { diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/appResiliencyOperations.ts b/sdk/appcontainers/arm-appcontainers/src/operations/appResiliencyOperations.ts deleted file mode 100644 index f9a4b90b2bb1..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/appResiliencyOperations.ts +++ /dev/null @@ -1,374 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { AppResiliencyOperations } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - AppResiliency, - AppResiliencyListNextOptionalParams, - AppResiliencyListOptionalParams, - AppResiliencyListResponse, - AppResiliencyCreateOrUpdateOptionalParams, - AppResiliencyCreateOrUpdateResponse, - AppResiliencyUpdateOptionalParams, - AppResiliencyUpdateResponse, - AppResiliencyDeleteOptionalParams, - AppResiliencyGetOptionalParams, - AppResiliencyGetResponse, - AppResiliencyListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing AppResiliencyOperations operations. */ -export class AppResiliencyOperationsImpl implements AppResiliencyOperations { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class AppResiliencyOperations class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List container app resiliency policies. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - appName: string, - options?: AppResiliencyListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll(resourceGroupName, appName, 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.listPagingPage( - resourceGroupName, - appName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - appName: string, - options?: AppResiliencyListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: AppResiliencyListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, appName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - appName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - appName: string, - options?: AppResiliencyListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - appName, - options, - )) { - yield* page; - } - } - - /** - * Create or update container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param resiliencyEnvelope The resiliency policy to create or update. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - appName: string, - name: string, - resiliencyEnvelope: AppResiliency, - options?: AppResiliencyCreateOrUpdateOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, name, resiliencyEnvelope, options }, - createOrUpdateOperationSpec, - ); - } - - /** - * Update container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param resiliencyEnvelope The resiliency policy to update. - * @param options The options parameters. - */ - update( - resourceGroupName: string, - appName: string, - name: string, - resiliencyEnvelope: AppResiliency, - options?: AppResiliencyUpdateOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, name, resiliencyEnvelope, options }, - updateOperationSpec, - ); - } - - /** - * Delete container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - appName: string, - name: string, - options?: AppResiliencyDeleteOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, name, options }, - deleteOperationSpec, - ); - } - - /** - * Get container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - appName: string, - name: string, - options?: AppResiliencyGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, name, options }, - getOperationSpec, - ); - } - - /** - * List container app resiliency policies. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - appName: string, - options?: AppResiliencyListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, options }, - listOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - appName: string, - nextLink: string, - options?: AppResiliencyListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, appName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{appName}/resiliencyPolicies/{name}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.AppResiliency, - }, - 201: { - bodyMapper: Mappers.AppResiliency, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.resiliencyEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - Parameters.name, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{appName}/resiliencyPolicies/{name}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.AppResiliency, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.resiliencyEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - Parameters.name, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{appName}/resiliencyPolicies/{name}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - Parameters.name, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{appName}/resiliencyPolicies/{name}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.AppResiliency, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - Parameters.name, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{appName}/resiliencyPolicies", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.AppResiliencyCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.AppResiliencyCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.appName, - Parameters.nextLink, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/buildAuthToken.ts b/sdk/appcontainers/arm-appcontainers/src/operations/buildAuthToken.ts deleted file mode 100644 index 32642103a800..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/buildAuthToken.ts +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { BuildAuthToken } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - BuildAuthTokenListOptionalParams, - BuildAuthTokenListResponse, -} from "../models/index.js"; - -/** Class containing BuildAuthToken operations. */ -export class BuildAuthTokenImpl implements BuildAuthToken { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class BuildAuthToken class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildAuthTokenListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, builderName, buildName, options }, - listOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}/builds/{buildName}/listAuthToken", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.BuildToken, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - Parameters.buildName, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/builders.ts b/sdk/appcontainers/arm-appcontainers/src/operations/builders.ts deleted file mode 100644 index 22ade9ed93a2..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/builders.ts +++ /dev/null @@ -1,728 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { Builders } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - BuilderResource, - BuildersListBySubscriptionNextOptionalParams, - BuildersListBySubscriptionOptionalParams, - BuildersListBySubscriptionResponse, - BuildersListByResourceGroupNextOptionalParams, - BuildersListByResourceGroupOptionalParams, - BuildersListByResourceGroupResponse, - BuildersGetOptionalParams, - BuildersGetResponse, - BuildersCreateOrUpdateOptionalParams, - BuildersCreateOrUpdateResponse, - BuilderResourceUpdate, - BuildersUpdateOptionalParams, - BuildersUpdateResponse, - BuildersDeleteOptionalParams, - BuildersDeleteResponse, - BuildersListBySubscriptionNextResponse, - BuildersListByResourceGroupNextResponse, -} from "../models/index.js"; - -/// -/** Class containing Builders operations. */ -export class BuildersImpl implements Builders { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class Builders class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List BuilderResource resources by subscription ID - * @param options The options parameters. - */ - public listBySubscription( - options?: BuildersListBySubscriptionOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listBySubscriptionPagingAll(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.listBySubscriptionPagingPage(options, settings); - }, - }; - } - - private async *listBySubscriptionPagingPage( - options?: BuildersListBySubscriptionOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: BuildersListBySubscriptionResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listBySubscription(options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listBySubscriptionNext(continuationToken, options); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listBySubscriptionPagingAll( - options?: BuildersListBySubscriptionOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listBySubscriptionPagingPage(options)) { - yield* page; - } - } - - /** - * List BuilderResource resources by resource group - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - public listByResourceGroup( - resourceGroupName: string, - options?: BuildersListByResourceGroupOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listByResourceGroupPagingAll(resourceGroupName, 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.listByResourceGroupPagingPage( - resourceGroupName, - options, - settings, - ); - }, - }; - } - - private async *listByResourceGroupPagingPage( - resourceGroupName: string, - options?: BuildersListByResourceGroupOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: BuildersListByResourceGroupResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listByResourceGroup(resourceGroupName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listByResourceGroupNext( - resourceGroupName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listByResourceGroupPagingAll( - resourceGroupName: string, - options?: BuildersListByResourceGroupOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listByResourceGroupPagingPage( - resourceGroupName, - options, - )) { - yield* page; - } - } - - /** - * List BuilderResource resources by subscription ID - * @param options The options parameters. - */ - private _listBySubscription( - options?: BuildersListBySubscriptionOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { options }, - listBySubscriptionOperationSpec, - ); - } - - /** - * List BuilderResource resources by resource group - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - private _listByResourceGroup( - resourceGroupName: string, - options?: BuildersListByResourceGroupOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, options }, - listByResourceGroupOperationSpec, - ); - } - - /** - * Get a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - builderName: string, - options?: BuildersGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, builderName, options }, - getOperationSpec, - ); - } - - /** - * Create or update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope Resource create parameters. - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResource, - options?: BuildersCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, builderName, builderEnvelope, options }, - spec: createOrUpdateOperationSpec, - }); - const poller = await createHttpPoller< - BuildersCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Create or update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope Resource create parameters. - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResource, - options?: BuildersCreateOrUpdateOptionalParams, - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - builderName, - builderEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope The resource properties to be updated. - * @param options The options parameters. - */ - async beginUpdate( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResourceUpdate, - options?: BuildersUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, builderName, builderEnvelope, options }, - spec: updateOperationSpec, - }); - const poller = await createHttpPoller< - BuildersUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope The resource properties to be updated. - * @param options The options parameters. - */ - async beginUpdateAndWait( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResourceUpdate, - options?: BuildersUpdateOptionalParams, - ): Promise { - const poller = await this.beginUpdate( - resourceGroupName, - builderName, - builderEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Delete a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - builderName: string, - options?: BuildersDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, builderName, options }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - BuildersDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Delete a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - builderName: string, - options?: BuildersDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - builderName, - options, - ); - return poller.pollUntilDone(); - } - - /** - * ListBySubscriptionNext - * @param nextLink The nextLink from the previous successful call to the ListBySubscription method. - * @param options The options parameters. - */ - private _listBySubscriptionNext( - nextLink: string, - options?: BuildersListBySubscriptionNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { nextLink, options }, - listBySubscriptionNextOperationSpec, - ); - } - - /** - * ListByResourceGroupNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method. - * @param options The options parameters. - */ - private _listByResourceGroupNext( - resourceGroupName: string, - nextLink: string, - options?: BuildersListByResourceGroupNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/providers/Microsoft.App/builders", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuilderCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.subscriptionId], - headerParameters: [Parameters.accept], - serializer, -}; -const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuilderCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuilderResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.BuilderResource, - }, - 201: { - bodyMapper: Mappers.BuilderResource, - }, - 202: { - bodyMapper: Mappers.BuilderResource, - }, - 204: { - bodyMapper: Mappers.BuilderResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.builderEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.BuilderResource, - }, - 201: { - bodyMapper: Mappers.BuilderResource, - }, - 202: { - bodyMapper: Mappers.BuilderResource, - }, - 204: { - bodyMapper: Mappers.BuilderResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.builderEnvelope1, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.BuildersDeleteHeaders, - }, - 201: { - headersMapper: Mappers.BuildersDeleteHeaders, - }, - 202: { - headersMapper: Mappers.BuildersDeleteHeaders, - }, - 204: { - headersMapper: Mappers.BuildersDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuilderCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.nextLink, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuilderCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/builds.ts b/sdk/appcontainers/arm-appcontainers/src/operations/builds.ts deleted file mode 100644 index 6859f1b9c582..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/builds.ts +++ /dev/null @@ -1,347 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { Builds } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - BuildsGetOptionalParams, - BuildsGetResponse, - BuildResource, - BuildsCreateOrUpdateOptionalParams, - BuildsCreateOrUpdateResponse, - BuildsDeleteOptionalParams, - BuildsDeleteResponse, -} from "../models/index.js"; - -/** Class containing Builds operations. */ -export class BuildsImpl implements Builds { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class Builds class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Get a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, builderName, buildName, options }, - getOperationSpec, - ); - } - - /** - * Create a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param buildEnvelope Resource create or update parameters. - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - builderName: string, - buildName: string, - buildEnvelope: BuildResource, - options?: BuildsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildsCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - builderName, - buildName, - buildEnvelope, - options, - }, - spec: createOrUpdateOperationSpec, - }); - const poller = await createHttpPoller< - BuildsCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Create a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param buildEnvelope Resource create or update parameters. - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - builderName: string, - buildName: string, - buildEnvelope: BuildResource, - options?: BuildsCreateOrUpdateOptionalParams, - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - builderName, - buildName, - buildEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Delete a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsDeleteOptionalParams, - ): Promise< - SimplePollerLike, BuildsDeleteResponse> - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, builderName, buildName, options }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - BuildsDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Delete a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - builderName, - buildName, - options, - ); - return poller.pollUntilDone(); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}/builds/{buildName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuildResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - Parameters.buildName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}/builds/{buildName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.BuildResource, - }, - 201: { - bodyMapper: Mappers.BuildResource, - }, - 202: { - bodyMapper: Mappers.BuildResource, - }, - 204: { - bodyMapper: Mappers.BuildResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.buildEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - Parameters.buildName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}/builds/{buildName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.BuildsDeleteHeaders, - }, - 201: { - headersMapper: Mappers.BuildsDeleteHeaders, - }, - 202: { - headersMapper: Mappers.BuildsDeleteHeaders, - }, - 204: { - headersMapper: Mappers.BuildsDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - Parameters.buildName, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/buildsByBuilderResource.ts b/sdk/appcontainers/arm-appcontainers/src/operations/buildsByBuilderResource.ts deleted file mode 100644 index a8fee9418158..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/buildsByBuilderResource.ts +++ /dev/null @@ -1,193 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { BuildsByBuilderResource } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - BuildResource, - BuildsByBuilderResourceListNextOptionalParams, - BuildsByBuilderResourceListOptionalParams, - BuildsByBuilderResourceListResponse, - BuildsByBuilderResourceListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing BuildsByBuilderResource operations. */ -export class BuildsByBuilderResourceImpl implements BuildsByBuilderResource { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class BuildsByBuilderResource class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List BuildResource resources by BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - builderName: string, - options?: BuildsByBuilderResourceListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll(resourceGroupName, builderName, 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.listPagingPage( - resourceGroupName, - builderName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - builderName: string, - options?: BuildsByBuilderResourceListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: BuildsByBuilderResourceListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, builderName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - builderName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - builderName: string, - options?: BuildsByBuilderResourceListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - builderName, - options, - )) { - yield* page; - } - } - - /** - * List BuildResource resources by BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - builderName: string, - options?: BuildsByBuilderResourceListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, builderName, options }, - listOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - builderName: string, - nextLink: string, - options?: BuildsByBuilderResourceListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, builderName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}/builds", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuildCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.builderName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BuildCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.builderName, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/certificates.ts b/sdk/appcontainers/arm-appcontainers/src/operations/certificates.ts index fd96a92c921c..fc60d2e97862 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/certificates.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/certificates.ts @@ -308,7 +308,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.certificateName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -353,7 +353,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.certificateName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironments.ts b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironments.ts index 72fd3bc75444..eaa345cdf9e4 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironments.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironments.ts @@ -565,7 +565,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.connectedEnvironmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -631,7 +631,7 @@ const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.connectedEnvironmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsCertificates.ts b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsCertificates.ts index 9a0c85d72086..41c7f23619af 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsCertificates.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsCertificates.ts @@ -301,6 +301,9 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { 200: { bodyMapper: Mappers.Certificate, }, + 201: { + bodyMapper: Mappers.Certificate, + }, default: { bodyMapper: Mappers.DefaultErrorResponse, }, @@ -314,7 +317,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.connectedEnvironmentName, Parameters.certificateName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -359,7 +362,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.connectedEnvironmentName, Parameters.certificateName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsDaprComponents.ts b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsDaprComponents.ts index 8a50faebf2ae..11c190556c07 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsDaprComponents.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsDaprComponents.ts @@ -300,6 +300,9 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { 200: { bodyMapper: Mappers.DaprComponent, }, + 201: { + bodyMapper: Mappers.DaprComponent, + }, default: { bodyMapper: Mappers.DefaultErrorResponse, }, @@ -313,7 +316,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.connectedEnvironmentName, Parameters.componentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsStorages.ts b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsStorages.ts index af80c88ab92b..d1f59ebf61ca 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsStorages.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/connectedEnvironmentsStorages.ts @@ -171,6 +171,9 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { 200: { bodyMapper: Mappers.ConnectedEnvironmentStorage, }, + 201: { + bodyMapper: Mappers.ConnectedEnvironmentStorage, + }, default: { bodyMapper: Mappers.DefaultErrorResponse, }, @@ -184,7 +187,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.connectedEnvironmentName, Parameters.storageName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerApps.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerApps.ts index c0c8bde6a46e..57531baabc50 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerApps.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerApps.ts @@ -864,7 +864,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.containerAppName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -918,7 +918,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.containerAppName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsAuthConfigs.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsAuthConfigs.ts index 6b9c66ec7d05..b485e4ada4bd 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsAuthConfigs.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsAuthConfigs.ts @@ -290,7 +290,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.containerAppName, Parameters.authConfigName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -330,8 +330,8 @@ const listByContainerAppNextOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink, Parameters.containerAppName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], serializer, diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuilds.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuilds.ts deleted file mode 100644 index 22dab3ae3340..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuilds.ts +++ /dev/null @@ -1,208 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { ContainerAppsBuilds } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - ContainerAppsBuildsGetOptionalParams, - ContainerAppsBuildsGetResponse, - ContainerAppsBuildsDeleteOptionalParams, - ContainerAppsBuildsDeleteResponse, -} from "../models/index.js"; - -/** Class containing ContainerAppsBuilds operations. */ -export class ContainerAppsBuildsImpl implements ContainerAppsBuilds { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class ContainerAppsBuilds class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Get a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, buildName, options }, - getOperationSpec, - ); - } - - /** - * Delete a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsBuildsDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, containerAppName, buildName, options }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - ContainerAppsBuildsDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Delete a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - containerAppName, - buildName, - options, - ); - return poller.pollUntilDone(); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/builds/{buildName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ContainerAppsBuildResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.buildName, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/builds/{buildName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.ContainerAppsBuildsDeleteHeaders, - }, - 201: { - headersMapper: Mappers.ContainerAppsBuildsDeleteHeaders, - }, - 202: { - headersMapper: Mappers.ContainerAppsBuildsDeleteHeaders, - }, - 204: { - headersMapper: Mappers.ContainerAppsBuildsDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.buildName, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuildsByContainerApp.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuildsByContainerApp.ts deleted file mode 100644 index 84078badaabc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsBuildsByContainerApp.ts +++ /dev/null @@ -1,199 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { ContainerAppsBuildsByContainerApp } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - ContainerAppsBuildResource, - ContainerAppsBuildsByContainerAppListNextOptionalParams, - ContainerAppsBuildsByContainerAppListOptionalParams, - ContainerAppsBuildsByContainerAppListResponse, - ContainerAppsBuildsByContainerAppListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing ContainerAppsBuildsByContainerApp operations. */ -export class ContainerAppsBuildsByContainerAppImpl - implements ContainerAppsBuildsByContainerApp -{ - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class ContainerAppsBuildsByContainerApp class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List Container Apps Build resources by Container App - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsBuildsByContainerAppListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - containerAppName, - 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.listPagingPage( - resourceGroupName, - containerAppName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsBuildsByContainerAppListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: ContainerAppsBuildsByContainerAppListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, containerAppName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - containerAppName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsBuildsByContainerAppListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - containerAppName, - options, - )) { - yield* page; - } - } - - /** - * List Container Apps Build resources by Container App - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsBuildsByContainerAppListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, options }, - listOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - containerAppName: string, - nextLink: string, - options?: ContainerAppsBuildsByContainerAppListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/builds", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ContainerAppsBuildCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ContainerAppsBuildCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsDiagnostics.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsDiagnostics.ts index e86bfea88806..458b4795af7e 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsDiagnostics.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsDiagnostics.ts @@ -468,8 +468,8 @@ const listDetectorsNextOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink, Parameters.containerAppName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], serializer, @@ -489,8 +489,8 @@ const listRevisionsNextOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink, Parameters.containerAppName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], serializer, diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsPatches.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsPatches.ts deleted file mode 100644 index aa4a5d368624..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsPatches.ts +++ /dev/null @@ -1,648 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { ContainerAppsPatches } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - ContainerAppsPatchResource, - ContainerAppsPatchesListByContainerAppNextOptionalParams, - ContainerAppsPatchesListByContainerAppOptionalParams, - ContainerAppsPatchesListByContainerAppResponse, - ContainerAppsPatchesGetOptionalParams, - ContainerAppsPatchesGetResponse, - ContainerAppsPatchesDeleteOptionalParams, - ContainerAppsPatchesDeleteResponse, - PatchSkipConfig, - ContainerAppsPatchesSkipConfigureOptionalParams, - ContainerAppsPatchesSkipConfigureResponse, - ContainerAppsPatchesApplyOptionalParams, - ContainerAppsPatchesApplyResponse, - ContainerAppsPatchesListByContainerAppNextResponse, -} from "../models/index.js"; - -/// -/** Class containing ContainerAppsPatches operations. */ -export class ContainerAppsPatchesImpl implements ContainerAppsPatches { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class ContainerAppsPatches class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List Container Apps Patch resources by ContainerApp. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param options The options parameters. - */ - public listByContainerApp( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsPatchesListByContainerAppOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listByContainerAppPagingAll( - resourceGroupName, - containerAppName, - 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.listByContainerAppPagingPage( - resourceGroupName, - containerAppName, - options, - settings, - ); - }, - }; - } - - private async *listByContainerAppPagingPage( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsPatchesListByContainerAppOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: ContainerAppsPatchesListByContainerAppResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listByContainerApp( - resourceGroupName, - containerAppName, - options, - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listByContainerAppNext( - resourceGroupName, - containerAppName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listByContainerAppPagingAll( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsPatchesListByContainerAppOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listByContainerAppPagingPage( - resourceGroupName, - containerAppName, - options, - )) { - yield* page; - } - } - - /** - * List Container Apps Patch resources by ContainerApp. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param options The options parameters. - */ - private _listByContainerApp( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsPatchesListByContainerAppOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, options }, - listByContainerAppOperationSpec, - ); - } - - /** - * Get details for specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, patchName, options }, - getOperationSpec, - ); - } - - /** - * Delete specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, containerAppName, patchName, options }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - ContainerAppsPatchesDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Delete specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - containerAppName, - patchName, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Configure the Container Apps Patch skip option by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param patchSkipConfig Configure patcher to skip a patch or not. - * @param options The options parameters. - */ - async beginSkipConfigure( - resourceGroupName: string, - containerAppName: string, - patchName: string, - patchSkipConfig: PatchSkipConfig, - options?: ContainerAppsPatchesSkipConfigureOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesSkipConfigureResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - containerAppName, - patchName, - patchSkipConfig, - options, - }, - spec: skipConfigureOperationSpec, - }); - const poller = await createHttpPoller< - ContainerAppsPatchesSkipConfigureResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Configure the Container Apps Patch skip option by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param patchSkipConfig Configure patcher to skip a patch or not. - * @param options The options parameters. - */ - async beginSkipConfigureAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - patchSkipConfig: PatchSkipConfig, - options?: ContainerAppsPatchesSkipConfigureOptionalParams, - ): Promise { - const poller = await this.beginSkipConfigure( - resourceGroupName, - containerAppName, - patchName, - patchSkipConfig, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Apply a Container Apps Patch resource with patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - async beginApply( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesApplyOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesApplyResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, containerAppName, patchName, options }, - spec: applyOperationSpec, - }); - const poller = await createHttpPoller< - ContainerAppsPatchesApplyResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Apply a Container Apps Patch resource with patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - async beginApplyAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesApplyOptionalParams, - ): Promise { - const poller = await this.beginApply( - resourceGroupName, - containerAppName, - patchName, - options, - ); - return poller.pollUntilDone(); - } - - /** - * ListByContainerAppNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param nextLink The nextLink from the previous successful call to the ListByContainerApp method. - * @param options The options parameters. - */ - private _listByContainerAppNext( - resourceGroupName: string, - containerAppName: string, - nextLink: string, - options?: ContainerAppsPatchesListByContainerAppNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, nextLink, options }, - listByContainerAppNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listByContainerAppOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/patches", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PatchCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion, Parameters.filter], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/patches/{patchName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ContainerAppsPatchResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.patchName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/patches/{patchName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.ContainerAppsPatchesDeleteHeaders, - }, - 201: { - headersMapper: Mappers.ContainerAppsPatchesDeleteHeaders, - }, - 202: { - headersMapper: Mappers.ContainerAppsPatchesDeleteHeaders, - }, - 204: { - headersMapper: Mappers.ContainerAppsPatchesDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.patchName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const skipConfigureOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/patches/{patchName}/skipConfig", - httpMethod: "POST", - responses: { - 200: { - headersMapper: Mappers.ContainerAppsPatchesSkipConfigureHeaders, - }, - 201: { - headersMapper: Mappers.ContainerAppsPatchesSkipConfigureHeaders, - }, - 202: { - headersMapper: Mappers.ContainerAppsPatchesSkipConfigureHeaders, - }, - 204: { - headersMapper: Mappers.ContainerAppsPatchesSkipConfigureHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.patchSkipConfig, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.patchName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const applyOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/patches/{patchName}/apply", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.ContainerAppsPatchResource, - }, - 201: { - bodyMapper: Mappers.ContainerAppsPatchResource, - }, - 202: { - bodyMapper: Mappers.ContainerAppsPatchResource, - }, - 204: { - bodyMapper: Mappers.ContainerAppsPatchResource, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.patchName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listByContainerAppNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PatchCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.containerAppName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsRevisions.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsRevisions.ts index bbaf3823ef10..b8c74a70b47e 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsRevisions.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsRevisions.ts @@ -356,8 +356,8 @@ const listRevisionsNextOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink, Parameters.containerAppName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], serializer, diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSessionPools.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSessionPools.ts index d5b6c312be16..e1064953b6bb 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSessionPools.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSessionPools.ts @@ -633,7 +633,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.sessionPoolName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -665,7 +665,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.sessionPoolName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSourceControls.ts b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSourceControls.ts index f8474d618484..939201553c65 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSourceControls.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/containerAppsSourceControls.ts @@ -452,11 +452,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.containerAppName, Parameters.sourceControlName, ], - headerParameters: [ - Parameters.contentType, - Parameters.accept, - Parameters.xMsGithubAuxiliary, - ], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -472,11 +468,7 @@ const deleteOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse, }, }, - queryParameters: [ - Parameters.apiVersion, - Parameters.ignoreWorkflowDeletionFailure, - Parameters.deleteWorkflow, - ], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -484,7 +476,7 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.containerAppName, Parameters.sourceControlName, ], - headerParameters: [Parameters.accept, Parameters.xMsGithubAuxiliary], + headerParameters: [Parameters.accept], serializer, }; const listByContainerAppNextOperationSpec: coreClient.OperationSpec = { @@ -502,8 +494,8 @@ const listByContainerAppNextOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink, Parameters.containerAppName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], serializer, diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/daprComponentResiliencyPolicies.ts b/sdk/appcontainers/arm-appcontainers/src/operations/daprComponentResiliencyPolicies.ts deleted file mode 100644 index 68fc5927d359..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/daprComponentResiliencyPolicies.ts +++ /dev/null @@ -1,369 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { DaprComponentResiliencyPolicies } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - DaprComponentResiliencyPolicy, - DaprComponentResiliencyPoliciesListNextOptionalParams, - DaprComponentResiliencyPoliciesListOptionalParams, - DaprComponentResiliencyPoliciesListResponse, - DaprComponentResiliencyPoliciesGetOptionalParams, - DaprComponentResiliencyPoliciesGetResponse, - DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams, - DaprComponentResiliencyPoliciesCreateOrUpdateResponse, - DaprComponentResiliencyPoliciesDeleteOptionalParams, - DaprComponentResiliencyPoliciesListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing DaprComponentResiliencyPolicies operations. */ -export class DaprComponentResiliencyPoliciesImpl - implements DaprComponentResiliencyPolicies -{ - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class DaprComponentResiliencyPolicies class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Get the resiliency policies for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - environmentName: string, - componentName: string, - options?: DaprComponentResiliencyPoliciesListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - environmentName, - componentName, - 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.listPagingPage( - resourceGroupName, - environmentName, - componentName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - environmentName: string, - componentName: string, - options?: DaprComponentResiliencyPoliciesListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: DaprComponentResiliencyPoliciesListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list( - resourceGroupName, - environmentName, - componentName, - options, - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - environmentName, - componentName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - environmentName: string, - componentName: string, - options?: DaprComponentResiliencyPoliciesListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - environmentName, - componentName, - options, - )) { - yield* page; - } - } - - /** - * Get the resiliency policies for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - environmentName: string, - componentName: string, - options?: DaprComponentResiliencyPoliciesListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, componentName, options }, - listOperationSpec, - ); - } - - /** - * Get a Dapr component resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - options?: DaprComponentResiliencyPoliciesGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, componentName, name, options }, - getOperationSpec, - ); - } - - /** - * Creates or updates a resiliency policy for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param daprComponentResiliencyPolicyEnvelope Configuration details of the Dapr Component Resiliency - * Policy. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy, - options?: DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - environmentName, - componentName, - name, - daprComponentResiliencyPolicyEnvelope, - options, - }, - createOrUpdateOperationSpec, - ); - } - - /** - * Delete a resiliency policy for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - options?: DaprComponentResiliencyPoliciesDeleteOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, componentName, name, options }, - deleteOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - environmentName: string, - componentName: string, - nextLink: string, - options?: DaprComponentResiliencyPoliciesListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, componentName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}/resiliencyPolicies", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprComponentResiliencyPoliciesCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.componentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}/resiliencyPolicies/{name}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprComponentResiliencyPolicy, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.componentName1, - Parameters.name1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}/resiliencyPolicies/{name}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DaprComponentResiliencyPolicy, - }, - 201: { - bodyMapper: Mappers.DaprComponentResiliencyPolicy, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.daprComponentResiliencyPolicyEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.componentName1, - Parameters.name1, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}/resiliencyPolicies/{name}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.componentName1, - Parameters.name1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprComponentResiliencyPoliciesCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.environmentName1, - Parameters.componentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/daprComponents.ts b/sdk/appcontainers/arm-appcontainers/src/operations/daprComponents.ts index 6e073723fb61..0de2bae97870 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/daprComponents.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/daprComponents.ts @@ -307,7 +307,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.componentName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/daprSubscriptions.ts b/sdk/appcontainers/arm-appcontainers/src/operations/daprSubscriptions.ts deleted file mode 100644 index 89df257cd13d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/daprSubscriptions.ts +++ /dev/null @@ -1,337 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { DaprSubscriptions } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - DaprSubscription, - DaprSubscriptionsListNextOptionalParams, - DaprSubscriptionsListOptionalParams, - DaprSubscriptionsListResponse, - DaprSubscriptionsGetOptionalParams, - DaprSubscriptionsGetResponse, - DaprSubscriptionsCreateOrUpdateOptionalParams, - DaprSubscriptionsCreateOrUpdateResponse, - DaprSubscriptionsDeleteOptionalParams, - DaprSubscriptionsListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing DaprSubscriptions operations. */ -export class DaprSubscriptionsImpl implements DaprSubscriptions { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class DaprSubscriptions class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Get the Dapr subscriptions for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - environmentName: string, - options?: DaprSubscriptionsListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - 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.listPagingPage( - resourceGroupName, - environmentName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - environmentName: string, - options?: DaprSubscriptionsListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: DaprSubscriptionsListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, environmentName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - environmentName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - environmentName: string, - options?: DaprSubscriptionsListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - environmentName, - options, - )) { - yield* page; - } - } - - /** - * Get the Dapr subscriptions for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - environmentName: string, - options?: DaprSubscriptionsListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, options }, - listOperationSpec, - ); - } - - /** - * Get a dapr subscription. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DaprSubscriptionsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, name, options }, - getOperationSpec, - ); - } - - /** - * Creates or updates a Dapr subscription in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param daprSubscriptionEnvelope Configuration details of the Dapr subscription. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - daprSubscriptionEnvelope: DaprSubscription, - options?: DaprSubscriptionsCreateOrUpdateOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - environmentName, - name, - daprSubscriptionEnvelope, - options, - }, - createOrUpdateOperationSpec, - ); - } - - /** - * Delete a Dapr subscription from a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DaprSubscriptionsDeleteOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, name, options }, - deleteOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - environmentName: string, - nextLink: string, - options?: DaprSubscriptionsListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprSubscriptions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprSubscriptionsCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprSubscriptions/{name}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprSubscription, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.name1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprSubscriptions/{name}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DaprSubscription, - }, - 201: { - bodyMapper: Mappers.DaprSubscription, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.daprSubscriptionEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.name1, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprSubscriptions/{name}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.name1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DaprSubscriptionsCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/dotNetComponents.ts b/sdk/appcontainers/arm-appcontainers/src/operations/dotNetComponents.ts deleted file mode 100644 index 5404ff076d5b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/dotNetComponents.ts +++ /dev/null @@ -1,655 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { DotNetComponents } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - DotNetComponent, - DotNetComponentsListNextOptionalParams, - DotNetComponentsListOptionalParams, - DotNetComponentsListResponse, - DotNetComponentsGetOptionalParams, - DotNetComponentsGetResponse, - DotNetComponentsCreateOrUpdateOptionalParams, - DotNetComponentsCreateOrUpdateResponse, - DotNetComponentsUpdateOptionalParams, - DotNetComponentsUpdateResponse, - DotNetComponentsDeleteOptionalParams, - DotNetComponentsDeleteResponse, - DotNetComponentsListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing DotNetComponents operations. */ -export class DotNetComponentsImpl implements DotNetComponents { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class DotNetComponents class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Get the .NET Components for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - environmentName: string, - options?: DotNetComponentsListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - 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.listPagingPage( - resourceGroupName, - environmentName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - environmentName: string, - options?: DotNetComponentsListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: DotNetComponentsListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, environmentName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - environmentName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - environmentName: string, - options?: DotNetComponentsListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - environmentName, - options, - )) { - yield* page; - } - } - - /** - * Get the .NET Components for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - environmentName: string, - options?: DotNetComponentsListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, options }, - listOperationSpec, - ); - } - - /** - * Get a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, name, options }, - getOperationSpec, - ); - } - - /** - * Creates or updates a .NET Component in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - options, - }, - spec: createOrUpdateOperationSpec, - }); - const poller = await createHttpPoller< - DotNetComponentsCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Creates or updates a .NET Component in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsCreateOrUpdateOptionalParams, - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Patches a .NET Component using JSON Merge Patch - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - async beginUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - options, - }, - spec: updateOperationSpec, - }); - const poller = await createHttpPoller< - DotNetComponentsUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - }); - await poller.poll(); - return poller; - } - - /** - * Patches a .NET Component using JSON Merge Patch - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - async beginUpdateAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsUpdateOptionalParams, - ): Promise { - const poller = await this.beginUpdate( - resourceGroupName, - environmentName, - name, - dotNetComponentEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Delete a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, environmentName, name, options }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - DotNetComponentsDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location", - }); - await poller.poll(); - return poller; - } - - /** - * Delete a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - environmentName, - name, - options, - ); - return poller.pollUntilDone(); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - environmentName: string, - nextLink: string, - options?: DotNetComponentsListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/dotNetComponents", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DotNetComponentsCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/dotNetComponents/{name}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DotNetComponent, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/dotNetComponents/{name}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DotNetComponent, - }, - 201: { - bodyMapper: Mappers.DotNetComponent, - }, - 202: { - bodyMapper: Mappers.DotNetComponent, - }, - 204: { - bodyMapper: Mappers.DotNetComponent, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.dotNetComponentEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName1, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/dotNetComponents/{name}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.DotNetComponent, - }, - 201: { - bodyMapper: Mappers.DotNetComponent, - }, - 202: { - bodyMapper: Mappers.DotNetComponent, - }, - 204: { - bodyMapper: Mappers.DotNetComponent, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.dotNetComponentEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName1, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/dotNetComponents/{name}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.DotNetComponentsDeleteHeaders, - }, - 201: { - headersMapper: Mappers.DotNetComponentsDeleteHeaders, - }, - 202: { - headersMapper: Mappers.DotNetComponentsDeleteHeaders, - }, - 204: { - headersMapper: Mappers.DotNetComponentsDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DotNetComponentsCollection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/functionsExtension.ts b/sdk/appcontainers/arm-appcontainers/src/operations/functionsExtension.ts deleted file mode 100644 index 066ab32f70dc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/functionsExtension.ts +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { FunctionsExtension } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - FunctionsExtensionInvokeFunctionsHostOptionalParams, - FunctionsExtensionInvokeFunctionsHostResponse, -} from "../models/index.js"; - -/** Class containing FunctionsExtension operations. */ -export class FunctionsExtensionImpl implements FunctionsExtension { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class FunctionsExtension class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * Proxies a Functions host call to the function app backed by the container app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param revisionName Name of the Container App Revision, the parent resource. - * @param functionAppName Name of the Function App, the extension resource. - * @param options The options parameters. - */ - invokeFunctionsHost( - resourceGroupName: string, - containerAppName: string, - revisionName: string, - functionAppName: string, - options?: FunctionsExtensionInvokeFunctionsHostOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - containerAppName, - revisionName, - functionAppName, - options, - }, - invokeFunctionsHostOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const invokeFunctionsHostOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/providers/Microsoft.App/functions/{functionAppName}/invoke", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: { type: { name: "String" } }, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.revisionName1, - Parameters.functionAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/index.ts b/sdk/appcontainers/arm-appcontainers/src/operations/index.ts index 849c6cc8ba61..7092d07d3292 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/index.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/index.ts @@ -6,43 +6,28 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ -export * from "./appResiliencyOperations.js"; export * from "./containerAppsAuthConfigs.js"; export * from "./availableWorkloadProfiles.js"; export * from "./billingMeters.js"; -export * from "./builders.js"; -export * from "./buildsByBuilderResource.js"; -export * from "./builds.js"; -export * from "./buildAuthToken.js"; export * from "./connectedEnvironments.js"; export * from "./connectedEnvironmentsCertificates.js"; export * from "./connectedEnvironmentsDaprComponents.js"; export * from "./connectedEnvironmentsStorages.js"; export * from "./containerApps.js"; -export * from "./containerAppsBuildsByContainerApp.js"; -export * from "./containerAppsBuilds.js"; -export * from "./containerAppsPatches.js"; export * from "./containerAppsRevisions.js"; export * from "./containerAppsRevisionReplicas.js"; export * from "./containerAppsDiagnostics.js"; export * from "./managedEnvironmentDiagnostics.js"; export * from "./managedEnvironmentsDiagnostics.js"; export * from "./jobs.js"; -export * from "./dotNetComponents.js"; -export * from "./functionsExtension.js"; export * from "./operations.js"; export * from "./javaComponents.js"; export * from "./jobsExecutions.js"; -export * from "./logicApps.js"; export * from "./managedEnvironments.js"; export * from "./certificates.js"; export * from "./managedCertificates.js"; export * from "./namespaces.js"; -export * from "./managedEnvironmentPrivateEndpointConnections.js"; -export * from "./managedEnvironmentPrivateLinkResources.js"; -export * from "./daprComponentResiliencyPolicies.js"; export * from "./daprComponents.js"; -export * from "./daprSubscriptions.js"; export * from "./managedEnvironmentsStorages.js"; export * from "./containerAppsSessionPools.js"; export * from "./containerAppsSourceControls.js"; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/javaComponents.ts b/sdk/appcontainers/arm-appcontainers/src/operations/javaComponents.ts index 1f8c64264997..ea4b47f4a710 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/javaComponents.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/javaComponents.ts @@ -529,8 +529,8 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, Parameters.environmentName1, + Parameters.name, ], headerParameters: [Parameters.accept], serializer, @@ -561,10 +561,10 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, Parameters.environmentName1, + Parameters.name, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -594,10 +594,10 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, Parameters.environmentName1, + Parameters.name, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -626,8 +626,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, Parameters.environmentName1, + Parameters.name, ], headerParameters: [Parameters.accept], serializer, diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/jobs.ts b/sdk/appcontainers/arm-appcontainers/src/operations/jobs.ts index 72a41797ea5d..a5a4e595127f 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/jobs.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/jobs.ts @@ -50,10 +50,6 @@ import { JobsStopMultipleExecutionsResponse, JobsListSecretsOptionalParams, JobsListSecretsResponse, - JobsResumeOptionalParams, - JobsResumeResponse, - JobsSuspendOptionalParams, - JobsSuspendResponse, JobsListDetectorsNextResponse, JobsListBySubscriptionNextResponse, JobsListByResourceGroupNextResponse, @@ -916,172 +912,6 @@ export class JobsImpl implements Jobs { ); } - /** - * Resumes a suspended job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - async beginResume( - resourceGroupName: string, - jobName: string, - options?: JobsResumeOptionalParams, - ): Promise< - SimplePollerLike, JobsResumeResponse> - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, jobName, options }, - spec: resumeOperationSpec, - }); - const poller = await createHttpPoller< - JobsResumeResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Resumes a suspended job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - async beginResumeAndWait( - resourceGroupName: string, - jobName: string, - options?: JobsResumeOptionalParams, - ): Promise { - const poller = await this.beginResume(resourceGroupName, jobName, options); - return poller.pollUntilDone(); - } - - /** - * Suspends a job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - async beginSuspend( - resourceGroupName: string, - jobName: string, - options?: JobsSuspendOptionalParams, - ): Promise< - SimplePollerLike, JobsSuspendResponse> - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, jobName, options }, - spec: suspendOperationSpec, - }); - const poller = await createHttpPoller< - JobsSuspendResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation", - }); - await poller.poll(); - return poller; - } - - /** - * Suspends a job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - async beginSuspendAndWait( - resourceGroupName: string, - jobName: string, - options?: JobsSuspendOptionalParams, - ): Promise { - const poller = await this.beginSuspend(resourceGroupName, jobName, options); - return poller.pollUntilDone(); - } - /** * ListDetectorsNext * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -1286,7 +1116,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.jobName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -1340,7 +1170,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.jobName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -1372,7 +1202,7 @@ const startOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.jobName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -1450,66 +1280,6 @@ const listSecretsOperationSpec: coreClient.OperationSpec = { headerParameters: [Parameters.accept], serializer, }; -const resumeOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/jobs/{jobName}/resume", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.Job, - }, - 201: { - bodyMapper: Mappers.Job, - }, - 202: { - bodyMapper: Mappers.Job, - }, - 204: { - bodyMapper: Mappers.Job, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jobName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const suspendOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/jobs/{jobName}/suspend", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.Job, - }, - 201: { - bodyMapper: Mappers.Job, - }, - 202: { - bodyMapper: Mappers.Job, - }, - 204: { - bodyMapper: Mappers.Job, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jobName, - ], - headerParameters: [Parameters.accept], - serializer, -}; const listDetectorsNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/logicApps.ts b/sdk/appcontainers/arm-appcontainers/src/operations/logicApps.ts deleted file mode 100644 index 09e938a2509b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/logicApps.ts +++ /dev/null @@ -1,549 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { LogicApps } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - WorkflowEnvelope, - LogicAppsListWorkflowsNextOptionalParams, - LogicAppsListWorkflowsOptionalParams, - LogicAppsListWorkflowsResponse, - LogicAppsGetOptionalParams, - LogicAppsGetResponse, - LogicApp, - LogicAppsCreateOrUpdateOptionalParams, - LogicAppsCreateOrUpdateResponse, - LogicAppsDeleteOptionalParams, - LogicAppsGetWorkflowOptionalParams, - LogicAppsGetWorkflowResponse, - LogicAppsDeployWorkflowArtifactsOptionalParams, - LogicAppsListWorkflowsConnectionsOptionalParams, - LogicAppsListWorkflowsConnectionsResponse, - LogicAppsProxyMethod, - LogicAppsInvokeOptionalParams, - LogicAppsInvokeResponse, - LogicAppsListWorkflowsNextResponse, -} from "../models/index.js"; - -/// -/** Class containing LogicApps operations. */ -export class LogicAppsImpl implements LogicApps { - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class LogicApps class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List the workflows for a logic app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - public listWorkflows( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listWorkflowsPagingAll( - resourceGroupName, - containerAppName, - logicAppName, - 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, - containerAppName, - logicAppName, - options, - settings, - ); - }, - }; - } - - private async *listWorkflowsPagingPage( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: LogicAppsListWorkflowsResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listWorkflows( - resourceGroupName, - containerAppName, - logicAppName, - options, - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listWorkflowsNext( - resourceGroupName, - containerAppName, - logicAppName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listWorkflowsPagingAll( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listWorkflowsPagingPage( - resourceGroupName, - containerAppName, - logicAppName, - options, - )) { - yield* page; - } - } - - /** - * Gets a logic app extension resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, options }, - getOperationSpec, - ); - } - - /** - * Create or update a Logic App extension resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param resource Logic app resource properties. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - resource: LogicApp, - options?: LogicAppsCreateOrUpdateOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, resource, options }, - createOrUpdateOperationSpec, - ); - } - - /** - * Deletes a Logic App extension resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsDeleteOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, options }, - deleteOperationSpec, - ); - } - - /** - * List the workflows for a logic app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - private _listWorkflows( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, options }, - listWorkflowsOperationSpec, - ); - } - - /** - * Get workflow information by its name - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param workflowName Workflow name. - * @param options The options parameters. - */ - getWorkflow( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - workflowName: string, - options?: LogicAppsGetWorkflowOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - containerAppName, - logicAppName, - workflowName, - options, - }, - getWorkflowOperationSpec, - ); - } - - /** - * Creates or updates the artifacts for the logic app - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - deployWorkflowArtifacts( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsDeployWorkflowArtifactsOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, options }, - deployWorkflowArtifactsOperationSpec, - ); - } - - /** - * Gets logic app's connections. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - listWorkflowsConnections( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsConnectionsOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, options }, - listWorkflowsConnectionsOperationSpec, - ); - } - - /** - * Proxies a the API call to the logic app backed by the container app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the LogicApp App, the extension resource. - * @param xMsLogicAppsProxyPath The proxy path for the API call - * @param xMsLogicAppsProxyMethod The proxy method for the API call - * @param options The options parameters. - */ - invoke( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - xMsLogicAppsProxyPath: string, - xMsLogicAppsProxyMethod: LogicAppsProxyMethod, - options?: LogicAppsInvokeOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - containerAppName, - logicAppName, - xMsLogicAppsProxyPath, - xMsLogicAppsProxyMethod, - options, - }, - invokeOperationSpec, - ); - } - - /** - * ListWorkflowsNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param nextLink The nextLink from the previous successful call to the ListWorkflows method. - * @param options The options parameters. - */ - private _listWorkflowsNext( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - nextLink: string, - options?: LogicAppsListWorkflowsNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, logicAppName, nextLink, options }, - listWorkflowsNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.LogicApp, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.LogicApp, - }, - 201: { - bodyMapper: Mappers.LogicApp, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.resource, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listWorkflowsOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}/workflows", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.WorkflowEnvelopeCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getWorkflowOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}/workflows/{workflowName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.WorkflowEnvelope, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - Parameters.workflowName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const deployWorkflowArtifactsOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}/deployWorkflowArtifacts", - httpMethod: "POST", - responses: { - 200: {}, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - requestBody: Parameters.workflowArtifacts, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const listWorkflowsConnectionsOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}/listWorkflowsConnections", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.WorkflowEnvelope, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const invokeOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/providers/Microsoft.App/logicApps/{logicAppName}/invoke", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: { - type: { name: "Dictionary", value: { type: { name: "any" } } }, - }, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [ - Parameters.accept, - Parameters.xMsLogicAppsProxyPath, - Parameters.xMsLogicAppsProxyMethod, - ], - serializer, -}; -const listWorkflowsNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.WorkflowEnvelopeCollection, - }, - default: { - bodyMapper: Mappers.DefaultErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.containerAppName1, - Parameters.logicAppName, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/managedCertificates.ts b/sdk/appcontainers/arm-appcontainers/src/operations/managedCertificates.ts index 0673ecf24507..102edce0bdc0 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/managedCertificates.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/managedCertificates.ts @@ -386,7 +386,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.environmentName, Parameters.managedCertificateName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -431,7 +431,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.environmentName, Parameters.managedCertificateName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateEndpointConnections.ts b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateEndpointConnections.ts deleted file mode 100644 index 1160e2670a2c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateEndpointConnections.ts +++ /dev/null @@ -1,534 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { ManagedEnvironmentPrivateEndpointConnections } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - SimplePollerLike, - OperationState, - createHttpPoller, -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl.js"; -import { - PrivateEndpointConnection, - ManagedEnvironmentPrivateEndpointConnectionsListNextOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsListResponse, - ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsGetResponse, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse, - ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse, - ManagedEnvironmentPrivateEndpointConnectionsListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing ManagedEnvironmentPrivateEndpointConnections operations. */ -export class ManagedEnvironmentPrivateEndpointConnectionsImpl - implements ManagedEnvironmentPrivateEndpointConnections -{ - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class ManagedEnvironmentPrivateEndpointConnections class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List private endpoint connections for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - 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.listPagingPage( - resourceGroupName, - environmentName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: ManagedEnvironmentPrivateEndpointConnectionsListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, environmentName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - environmentName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - environmentName, - options, - )) { - yield* page; - } - } - - /** - * List private endpoint connections for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, options }, - listOperationSpec, - ); - } - - /** - * Get a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - environmentName, - privateEndpointConnectionName, - options, - }, - getOperationSpec, - ); - } - - /** - * Update the state of a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param privateEndpointConnectionEnvelope The resource of private endpoint and its properties - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - privateEndpointConnectionEnvelope: PrivateEndpointConnection, - options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - environmentName, - privateEndpointConnectionName, - privateEndpointConnectionEnvelope, - options, - }, - spec: createOrUpdateOperationSpec, - }); - const poller = await createHttpPoller< - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - }); - await poller.poll(); - return poller; - } - - /** - * Update the state of a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param privateEndpointConnectionEnvelope The resource of private endpoint and its properties - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - privateEndpointConnectionEnvelope: PrivateEndpointConnection, - options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - privateEndpointConnectionEnvelope, - options, - ); - return poller.pollUntilDone(); - } - - /** - * Delete a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec, - ) => { - let currentRawResponse: coreClient.FullOperationResponse | undefined = - undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown, - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback, - }, - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON(), - }, - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - environmentName, - privateEndpointConnectionName, - options, - }, - spec: deleteOperationSpec, - }); - const poller = await createHttpPoller< - ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - }); - await poller.poll(); - return poller; - } - - /** - * Delete a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - environmentName, - privateEndpointConnectionName, - options, - ); - return poller.pollUntilDone(); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - environmentName: string, - nextLink: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/privateEndpointConnections", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PrivateEndpointConnectionListResult, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const getOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/privateEndpointConnections/{privateEndpointConnectionName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PrivateEndpointConnection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.privateEndpointConnectionName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/privateEndpointConnections/{privateEndpointConnectionName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.PrivateEndpointConnection, - }, - 201: { - bodyMapper: Mappers.PrivateEndpointConnection, - }, - 202: { - bodyMapper: Mappers.PrivateEndpointConnection, - }, - 204: { - bodyMapper: Mappers.PrivateEndpointConnection, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - requestBody: Parameters.privateEndpointConnectionEnvelope, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.privateEndpointConnectionName, - ], - headerParameters: [Parameters.contentType, Parameters.accept], - mediaType: "json", - serializer, -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/privateEndpointConnections/{privateEndpointConnectionName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: - Mappers.ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders, - }, - 201: { - headersMapper: - Mappers.ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders, - }, - 202: { - headersMapper: - Mappers.ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders, - }, - 204: { - headersMapper: - Mappers.ManagedEnvironmentPrivateEndpointConnectionsDeleteHeaders, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - Parameters.privateEndpointConnectionName, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PrivateEndpointConnectionListResult, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateLinkResources.ts b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateLinkResources.ts deleted file mode 100644 index 78d2ed8cc12a..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentPrivateLinkResources.ts +++ /dev/null @@ -1,199 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper.js"; -import { ManagedEnvironmentPrivateLinkResources } from "../operationsInterfaces/index.js"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers.js"; -import * as Parameters from "../models/parameters.js"; -import { ContainerAppsAPIClient } from "../containerAppsAPIClient.js"; -import { - PrivateLinkResource, - ManagedEnvironmentPrivateLinkResourcesListNextOptionalParams, - ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - ManagedEnvironmentPrivateLinkResourcesListResponse, - ManagedEnvironmentPrivateLinkResourcesListNextResponse, -} from "../models/index.js"; - -/// -/** Class containing ManagedEnvironmentPrivateLinkResources operations. */ -export class ManagedEnvironmentPrivateLinkResourcesImpl - implements ManagedEnvironmentPrivateLinkResources -{ - private readonly client: ContainerAppsAPIClient; - - /** - * Initialize a new instance of the class ManagedEnvironmentPrivateLinkResources class. - * @param client Reference to the service client - */ - constructor(client: ContainerAppsAPIClient) { - this.client = client; - } - - /** - * List private link resources for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - public list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll( - resourceGroupName, - 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.listPagingPage( - resourceGroupName, - environmentName, - options, - settings, - ); - }, - }; - } - - private async *listPagingPage( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - settings?: PageSettings, - ): AsyncIterableIterator { - let result: ManagedEnvironmentPrivateLinkResourcesListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(resourceGroupName, environmentName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext( - resourceGroupName, - environmentName, - continuationToken, - options, - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - ): AsyncIterableIterator { - for await (const page of this.listPagingPage( - resourceGroupName, - environmentName, - options, - )) { - yield* page; - } - } - - /** - * List private link resources for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - private _list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, options }, - listOperationSpec, - ); - } - - /** - * ListNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - resourceGroupName: string, - environmentName: string, - nextLink: string, - options?: ManagedEnvironmentPrivateLinkResourcesListNextOptionalParams, - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, environmentName, nextLink, options }, - listNextOperationSpec, - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/privateLinkResources", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PrivateLinkResourceListResult, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PrivateLinkResourceListResult, - }, - default: { - bodyMapper: Mappers.ErrorResponse, - }, - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.environmentName1, - ], - headerParameters: [Parameters.accept], - serializer, -}; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironments.ts b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironments.ts index 9fa9aaaa481f..7552a7429e17 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironments.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironments.ts @@ -763,7 +763,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; @@ -817,7 +817,7 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentsStorages.ts b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentsStorages.ts index c271cd74c765..7ae0f3cc6808 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentsStorages.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/managedEnvironmentsStorages.ts @@ -184,7 +184,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.storageName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operations/namespaces.ts b/sdk/appcontainers/arm-appcontainers/src/operations/namespaces.ts index 8bb64803b747..45f4a0d81676 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operations/namespaces.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operations/namespaces.ts @@ -75,7 +75,7 @@ const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.environmentName, ], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/appResiliencyOperations.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/appResiliencyOperations.ts deleted file mode 100644 index 3e4158ebd7aa..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/appResiliencyOperations.ts +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - AppResiliency, - AppResiliencyListOptionalParams, - AppResiliencyCreateOrUpdateOptionalParams, - AppResiliencyCreateOrUpdateResponse, - AppResiliencyUpdateOptionalParams, - AppResiliencyUpdateResponse, - AppResiliencyDeleteOptionalParams, - AppResiliencyGetOptionalParams, - AppResiliencyGetResponse, -} from "../models/index.js"; - -/// -/** Interface representing a AppResiliencyOperations. */ -export interface AppResiliencyOperations { - /** - * List container app resiliency policies. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - appName: string, - options?: AppResiliencyListOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Create or update container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param resiliencyEnvelope The resiliency policy to create or update. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - appName: string, - name: string, - resiliencyEnvelope: AppResiliency, - options?: AppResiliencyCreateOrUpdateOptionalParams, - ): Promise; - /** - * Update container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param resiliencyEnvelope The resiliency policy to update. - * @param options The options parameters. - */ - update( - resourceGroupName: string, - appName: string, - name: string, - resiliencyEnvelope: AppResiliency, - options?: AppResiliencyUpdateOptionalParams, - ): Promise; - /** - * Delete container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - appName: string, - name: string, - options?: AppResiliencyDeleteOptionalParams, - ): Promise; - /** - * Get container app resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param appName Name of the Container App. - * @param name Name of the resiliency policy. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - appName: string, - name: string, - options?: AppResiliencyGetOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildAuthToken.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildAuthToken.ts deleted file mode 100644 index ab9589360638..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildAuthToken.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. - */ - -import { - BuildAuthTokenListOptionalParams, - BuildAuthTokenListResponse, -} from "../models/index.js"; - -/** Interface representing a BuildAuthToken. */ -export interface BuildAuthToken { - /** - * Gets the token used to connect to the endpoint where source code can be uploaded for a build. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildAuthTokenListOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builders.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builders.ts deleted file mode 100644 index d9855aa4cd26..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builders.ts +++ /dev/null @@ -1,145 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - BuilderResource, - BuildersListBySubscriptionOptionalParams, - BuildersListByResourceGroupOptionalParams, - BuildersGetOptionalParams, - BuildersGetResponse, - BuildersCreateOrUpdateOptionalParams, - BuildersCreateOrUpdateResponse, - BuilderResourceUpdate, - BuildersUpdateOptionalParams, - BuildersUpdateResponse, - BuildersDeleteOptionalParams, - BuildersDeleteResponse, -} from "../models/index.js"; - -/// -/** Interface representing a Builders. */ -export interface Builders { - /** - * List BuilderResource resources by subscription ID - * @param options The options parameters. - */ - listBySubscription( - options?: BuildersListBySubscriptionOptionalParams, - ): PagedAsyncIterableIterator; - /** - * List BuilderResource resources by resource group - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - listByResourceGroup( - resourceGroupName: string, - options?: BuildersListByResourceGroupOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - builderName: string, - options?: BuildersGetOptionalParams, - ): Promise; - /** - * Create or update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope Resource create parameters. - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResource, - options?: BuildersCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersCreateOrUpdateResponse - > - >; - /** - * Create or update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope Resource create parameters. - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResource, - options?: BuildersCreateOrUpdateOptionalParams, - ): Promise; - /** - * Update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope The resource properties to be updated. - * @param options The options parameters. - */ - beginUpdate( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResourceUpdate, - options?: BuildersUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersUpdateResponse - > - >; - /** - * Update a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param builderEnvelope The resource properties to be updated. - * @param options The options parameters. - */ - beginUpdateAndWait( - resourceGroupName: string, - builderName: string, - builderEnvelope: BuilderResourceUpdate, - options?: BuildersUpdateOptionalParams, - ): Promise; - /** - * Delete a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - builderName: string, - options?: BuildersDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildersDeleteResponse - > - >; - /** - * Delete a BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - builderName: string, - options?: BuildersDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builds.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builds.ts deleted file mode 100644 index c412e427e2b6..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/builds.ts +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - BuildsGetOptionalParams, - BuildsGetResponse, - BuildResource, - BuildsCreateOrUpdateOptionalParams, - BuildsCreateOrUpdateResponse, - BuildsDeleteOptionalParams, - BuildsDeleteResponse, -} from "../models/index.js"; - -/** Interface representing a Builds. */ -export interface Builds { - /** - * Get a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsGetOptionalParams, - ): Promise; - /** - * Create a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param buildEnvelope Resource create or update parameters. - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - builderName: string, - buildName: string, - buildEnvelope: BuildResource, - options?: BuildsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - BuildsCreateOrUpdateResponse - > - >; - /** - * Create a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param buildEnvelope Resource create or update parameters. - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - builderName: string, - buildName: string, - buildEnvelope: BuildResource, - options?: BuildsCreateOrUpdateOptionalParams, - ): Promise; - /** - * Delete a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsDeleteOptionalParams, - ): Promise< - SimplePollerLike, BuildsDeleteResponse> - >; - /** - * Delete a BuildResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param buildName The name of a build. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - builderName: string, - buildName: string, - options?: BuildsDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildsByBuilderResource.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildsByBuilderResource.ts deleted file mode 100644 index 52172642eb4d..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/buildsByBuilderResource.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. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - BuildResource, - BuildsByBuilderResourceListOptionalParams, -} from "../models/index.js"; - -/// -/** Interface representing a BuildsByBuilderResource. */ -export interface BuildsByBuilderResource { - /** - * List BuildResource resources by BuilderResource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param builderName The name of the builder. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - builderName: string, - options?: BuildsByBuilderResourceListOptionalParams, - ): PagedAsyncIterableIterator; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuilds.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuilds.ts deleted file mode 100644 index e75bab7ec11b..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuilds.ts +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - ContainerAppsBuildsGetOptionalParams, - ContainerAppsBuildsGetResponse, - ContainerAppsBuildsDeleteOptionalParams, - ContainerAppsBuildsDeleteResponse, -} from "../models/index.js"; - -/** Interface representing a ContainerAppsBuilds. */ -export interface ContainerAppsBuilds { - /** - * Get a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsGetOptionalParams, - ): Promise; - /** - * Delete a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsBuildsDeleteResponse - > - >; - /** - * Delete a Container Apps Build resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param buildName The name of a build. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - containerAppName: string, - buildName: string, - options?: ContainerAppsBuildsDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuildsByContainerApp.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuildsByContainerApp.ts deleted file mode 100644 index 9211820d0996..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsBuildsByContainerApp.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. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - ContainerAppsBuildResource, - ContainerAppsBuildsByContainerAppListOptionalParams, -} from "../models/index.js"; - -/// -/** Interface representing a ContainerAppsBuildsByContainerApp. */ -export interface ContainerAppsBuildsByContainerApp { - /** - * List Container Apps Build resources by Container App - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Build is associated. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsBuildsByContainerAppListOptionalParams, - ): PagedAsyncIterableIterator; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsPatches.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsPatches.ts deleted file mode 100644 index 9c7ec65860e3..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/containerAppsPatches.ts +++ /dev/null @@ -1,149 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - ContainerAppsPatchResource, - ContainerAppsPatchesListByContainerAppOptionalParams, - ContainerAppsPatchesGetOptionalParams, - ContainerAppsPatchesGetResponse, - ContainerAppsPatchesDeleteOptionalParams, - ContainerAppsPatchesDeleteResponse, - PatchSkipConfig, - ContainerAppsPatchesSkipConfigureOptionalParams, - ContainerAppsPatchesSkipConfigureResponse, - ContainerAppsPatchesApplyOptionalParams, - ContainerAppsPatchesApplyResponse, -} from "../models/index.js"; - -/// -/** Interface representing a ContainerAppsPatches. */ -export interface ContainerAppsPatches { - /** - * List Container Apps Patch resources by ContainerApp. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param options The options parameters. - */ - listByContainerApp( - resourceGroupName: string, - containerAppName: string, - options?: ContainerAppsPatchesListByContainerAppOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get details for specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesGetOptionalParams, - ): Promise; - /** - * Delete specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesDeleteResponse - > - >; - /** - * Delete specific Container Apps Patch by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesDeleteOptionalParams, - ): Promise; - /** - * Configure the Container Apps Patch skip option by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param patchSkipConfig Configure patcher to skip a patch or not. - * @param options The options parameters. - */ - beginSkipConfigure( - resourceGroupName: string, - containerAppName: string, - patchName: string, - patchSkipConfig: PatchSkipConfig, - options?: ContainerAppsPatchesSkipConfigureOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesSkipConfigureResponse - > - >; - /** - * Configure the Container Apps Patch skip option by patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param patchSkipConfig Configure patcher to skip a patch or not. - * @param options The options parameters. - */ - beginSkipConfigureAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - patchSkipConfig: PatchSkipConfig, - options?: ContainerAppsPatchesSkipConfigureOptionalParams, - ): Promise; - /** - * Apply a Container Apps Patch resource with patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - beginApply( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesApplyOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ContainerAppsPatchesApplyResponse - > - >; - /** - * Apply a Container Apps Patch resource with patch name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App the Patch is associated. - * @param patchName The name of the patch - * @param options The options parameters. - */ - beginApplyAndWait( - resourceGroupName: string, - containerAppName: string, - patchName: string, - options?: ContainerAppsPatchesApplyOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprComponentResiliencyPolicies.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprComponentResiliencyPolicies.ts deleted file mode 100644 index 223704be7678..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprComponentResiliencyPolicies.ts +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - DaprComponentResiliencyPolicy, - DaprComponentResiliencyPoliciesListOptionalParams, - DaprComponentResiliencyPoliciesGetOptionalParams, - DaprComponentResiliencyPoliciesGetResponse, - DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams, - DaprComponentResiliencyPoliciesCreateOrUpdateResponse, - DaprComponentResiliencyPoliciesDeleteOptionalParams, -} from "../models/index.js"; - -/// -/** Interface representing a DaprComponentResiliencyPolicies. */ -export interface DaprComponentResiliencyPolicies { - /** - * Get the resiliency policies for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - environmentName: string, - componentName: string, - options?: DaprComponentResiliencyPoliciesListOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get a Dapr component resiliency policy. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - options?: DaprComponentResiliencyPoliciesGetOptionalParams, - ): Promise; - /** - * Creates or updates a resiliency policy for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param daprComponentResiliencyPolicyEnvelope Configuration details of the Dapr Component Resiliency - * Policy. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - daprComponentResiliencyPolicyEnvelope: DaprComponentResiliencyPolicy, - options?: DaprComponentResiliencyPoliciesCreateOrUpdateOptionalParams, - ): Promise; - /** - * Delete a resiliency policy for a Dapr component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param componentName Name of the Dapr Component. - * @param name Name of the Dapr Component Resiliency Policy. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - environmentName: string, - componentName: string, - name: string, - options?: DaprComponentResiliencyPoliciesDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprSubscriptions.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprSubscriptions.ts deleted file mode 100644 index 2a850fcc768c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/daprSubscriptions.ts +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - DaprSubscription, - DaprSubscriptionsListOptionalParams, - DaprSubscriptionsGetOptionalParams, - DaprSubscriptionsGetResponse, - DaprSubscriptionsCreateOrUpdateOptionalParams, - DaprSubscriptionsCreateOrUpdateResponse, - DaprSubscriptionsDeleteOptionalParams, -} from "../models/index.js"; - -/// -/** Interface representing a DaprSubscriptions. */ -export interface DaprSubscriptions { - /** - * Get the Dapr subscriptions for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - environmentName: string, - options?: DaprSubscriptionsListOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get a dapr subscription. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DaprSubscriptionsGetOptionalParams, - ): Promise; - /** - * Creates or updates a Dapr subscription in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param daprSubscriptionEnvelope Configuration details of the Dapr subscription. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - daprSubscriptionEnvelope: DaprSubscription, - options?: DaprSubscriptionsCreateOrUpdateOptionalParams, - ): Promise; - /** - * Delete a Dapr subscription from a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the Dapr subscription. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DaprSubscriptionsDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/dotNetComponents.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/dotNetComponents.ts deleted file mode 100644 index 8d00067697cc..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/dotNetComponents.ts +++ /dev/null @@ -1,152 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - DotNetComponent, - DotNetComponentsListOptionalParams, - DotNetComponentsGetOptionalParams, - DotNetComponentsGetResponse, - DotNetComponentsCreateOrUpdateOptionalParams, - DotNetComponentsCreateOrUpdateResponse, - DotNetComponentsUpdateOptionalParams, - DotNetComponentsUpdateResponse, - DotNetComponentsDeleteOptionalParams, - DotNetComponentsDeleteResponse, -} from "../models/index.js"; - -/// -/** Interface representing a DotNetComponents. */ -export interface DotNetComponents { - /** - * Get the .NET Components for a managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - environmentName: string, - options?: DotNetComponentsListOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsGetOptionalParams, - ): Promise; - /** - * Creates or updates a .NET Component in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsCreateOrUpdateResponse - > - >; - /** - * Creates or updates a .NET Component in a Managed Environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsCreateOrUpdateOptionalParams, - ): Promise; - /** - * Patches a .NET Component using JSON Merge Patch - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - beginUpdate( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsUpdateResponse - > - >; - /** - * Patches a .NET Component using JSON Merge Patch - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param dotNetComponentEnvelope Configuration details of the .NET Component. - * @param options The options parameters. - */ - beginUpdateAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - dotNetComponentEnvelope: DotNetComponent, - options?: DotNetComponentsUpdateOptionalParams, - ): Promise; - /** - * Delete a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - DotNetComponentsDeleteResponse - > - >; - /** - * Delete a .NET Component. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param name Name of the .NET Component. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - environmentName: string, - name: string, - options?: DotNetComponentsDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/functionsExtension.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/functionsExtension.ts deleted file mode 100644 index a48c38de7bb7..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/functionsExtension.ts +++ /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. - */ - -import { - FunctionsExtensionInvokeFunctionsHostOptionalParams, - FunctionsExtensionInvokeFunctionsHostResponse, -} from "../models/index.js"; - -/** Interface representing a FunctionsExtension. */ -export interface FunctionsExtension { - /** - * Proxies a Functions host call to the function app backed by the container app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param revisionName Name of the Container App Revision, the parent resource. - * @param functionAppName Name of the Function App, the extension resource. - * @param options The options parameters. - */ - invokeFunctionsHost( - resourceGroupName: string, - containerAppName: string, - revisionName: string, - functionAppName: string, - options?: FunctionsExtensionInvokeFunctionsHostOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/index.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/index.ts index 849c6cc8ba61..7092d07d3292 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/index.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/index.ts @@ -6,43 +6,28 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ -export * from "./appResiliencyOperations.js"; export * from "./containerAppsAuthConfigs.js"; export * from "./availableWorkloadProfiles.js"; export * from "./billingMeters.js"; -export * from "./builders.js"; -export * from "./buildsByBuilderResource.js"; -export * from "./builds.js"; -export * from "./buildAuthToken.js"; export * from "./connectedEnvironments.js"; export * from "./connectedEnvironmentsCertificates.js"; export * from "./connectedEnvironmentsDaprComponents.js"; export * from "./connectedEnvironmentsStorages.js"; export * from "./containerApps.js"; -export * from "./containerAppsBuildsByContainerApp.js"; -export * from "./containerAppsBuilds.js"; -export * from "./containerAppsPatches.js"; export * from "./containerAppsRevisions.js"; export * from "./containerAppsRevisionReplicas.js"; export * from "./containerAppsDiagnostics.js"; export * from "./managedEnvironmentDiagnostics.js"; export * from "./managedEnvironmentsDiagnostics.js"; export * from "./jobs.js"; -export * from "./dotNetComponents.js"; -export * from "./functionsExtension.js"; export * from "./operations.js"; export * from "./javaComponents.js"; export * from "./jobsExecutions.js"; -export * from "./logicApps.js"; export * from "./managedEnvironments.js"; export * from "./certificates.js"; export * from "./managedCertificates.js"; export * from "./namespaces.js"; -export * from "./managedEnvironmentPrivateEndpointConnections.js"; -export * from "./managedEnvironmentPrivateLinkResources.js"; -export * from "./daprComponentResiliencyPolicies.js"; export * from "./daprComponents.js"; -export * from "./daprSubscriptions.js"; export * from "./managedEnvironmentsStorages.js"; export * from "./containerAppsSessionPools.js"; export * from "./containerAppsSourceControls.js"; diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/jobs.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/jobs.ts index a8e171db2aa8..0c17dafcace6 100644 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/jobs.ts +++ b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/jobs.ts @@ -33,10 +33,6 @@ import { JobsStopMultipleExecutionsResponse, JobsListSecretsOptionalParams, JobsListSecretsResponse, - JobsResumeOptionalParams, - JobsResumeResponse, - JobsSuspendOptionalParams, - JobsSuspendResponse, } from "../models/index.js"; /// @@ -275,52 +271,4 @@ export interface Jobs { jobName: string, options?: JobsListSecretsOptionalParams, ): Promise; - /** - * Resumes a suspended job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - beginResume( - resourceGroupName: string, - jobName: string, - options?: JobsResumeOptionalParams, - ): Promise< - SimplePollerLike, JobsResumeResponse> - >; - /** - * Resumes a suspended job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - beginResumeAndWait( - resourceGroupName: string, - jobName: string, - options?: JobsResumeOptionalParams, - ): Promise; - /** - * Suspends a job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - beginSuspend( - resourceGroupName: string, - jobName: string, - options?: JobsSuspendOptionalParams, - ): Promise< - SimplePollerLike, JobsSuspendResponse> - >; - /** - * Suspends a job - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jobName Name of the Job. - * @param options The options parameters. - */ - beginSuspendAndWait( - resourceGroupName: string, - jobName: string, - options?: JobsSuspendOptionalParams, - ): Promise; } diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/logicApps.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/logicApps.ts deleted file mode 100644 index 16666d7cca33..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/logicApps.ts +++ /dev/null @@ -1,144 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - WorkflowEnvelope, - LogicAppsListWorkflowsOptionalParams, - LogicAppsGetOptionalParams, - LogicAppsGetResponse, - LogicApp, - LogicAppsCreateOrUpdateOptionalParams, - LogicAppsCreateOrUpdateResponse, - LogicAppsDeleteOptionalParams, - LogicAppsGetWorkflowOptionalParams, - LogicAppsGetWorkflowResponse, - LogicAppsDeployWorkflowArtifactsOptionalParams, - LogicAppsListWorkflowsConnectionsOptionalParams, - LogicAppsListWorkflowsConnectionsResponse, - LogicAppsProxyMethod, - LogicAppsInvokeOptionalParams, - LogicAppsInvokeResponse, -} from "../models/index.js"; - -/// -/** Interface representing a LogicApps. */ -export interface LogicApps { - /** - * List the workflows for a logic app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - listWorkflows( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Gets a logic app extension resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsGetOptionalParams, - ): Promise; - /** - * Create or update a Logic App extension resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param resource Logic app resource properties. - * @param options The options parameters. - */ - createOrUpdate( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - resource: LogicApp, - options?: LogicAppsCreateOrUpdateOptionalParams, - ): Promise; - /** - * Deletes a Logic App extension resource - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsDeleteOptionalParams, - ): Promise; - /** - * Get workflow information by its name - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param workflowName Workflow name. - * @param options The options parameters. - */ - getWorkflow( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - workflowName: string, - options?: LogicAppsGetWorkflowOptionalParams, - ): Promise; - /** - * Creates or updates the artifacts for the logic app - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - deployWorkflowArtifacts( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsDeployWorkflowArtifactsOptionalParams, - ): Promise; - /** - * Gets logic app's connections. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the Logic App, the extension resource. - * @param options The options parameters. - */ - listWorkflowsConnections( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - options?: LogicAppsListWorkflowsConnectionsOptionalParams, - ): Promise; - /** - * Proxies a the API call to the logic app backed by the container app. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param containerAppName Name of the Container App. - * @param logicAppName Name of the LogicApp App, the extension resource. - * @param xMsLogicAppsProxyPath The proxy path for the API call - * @param xMsLogicAppsProxyMethod The proxy method for the API call - * @param options The options parameters. - */ - invoke( - resourceGroupName: string, - containerAppName: string, - logicAppName: string, - xMsLogicAppsProxyPath: string, - xMsLogicAppsProxyMethod: LogicAppsProxyMethod, - options?: LogicAppsInvokeOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateEndpointConnections.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateEndpointConnections.ts deleted file mode 100644 index 6f6d16a40382..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateEndpointConnections.ts +++ /dev/null @@ -1,120 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - PrivateEndpointConnection, - ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsGetResponse, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse, - ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse, -} from "../models/index.js"; - -/// -/** Interface representing a ManagedEnvironmentPrivateEndpointConnections. */ -export interface ManagedEnvironmentPrivateEndpointConnections { - /** - * List private endpoint connections for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsListOptionalParams, - ): PagedAsyncIterableIterator; - /** - * Get a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsGetOptionalParams, - ): Promise; - /** - * Update the state of a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param privateEndpointConnectionEnvelope The resource of private endpoint and its properties - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - privateEndpointConnectionEnvelope: PrivateEndpointConnection, - options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateResponse - > - >; - /** - * Update the state of a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param privateEndpointConnectionEnvelope The resource of private endpoint and its properties - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - privateEndpointConnectionEnvelope: PrivateEndpointConnection, - options?: ManagedEnvironmentPrivateEndpointConnectionsCreateOrUpdateOptionalParams, - ): Promise; - /** - * Delete a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ): Promise< - SimplePollerLike< - OperationState, - ManagedEnvironmentPrivateEndpointConnectionsDeleteResponse - > - >; - /** - * Delete a private endpoint connection for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param privateEndpointConnectionName The name of the private endpoint connection associated with the - * Azure resource. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - environmentName: string, - privateEndpointConnectionName: string, - options?: ManagedEnvironmentPrivateEndpointConnectionsDeleteOptionalParams, - ): Promise; -} diff --git a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateLinkResources.ts b/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateLinkResources.ts deleted file mode 100644 index c6cfc3f4da5c..000000000000 --- a/sdk/appcontainers/arm-appcontainers/src/operationsInterfaces/managedEnvironmentPrivateLinkResources.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. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - PrivateLinkResource, - ManagedEnvironmentPrivateLinkResourcesListOptionalParams, -} from "../models/index.js"; - -/// -/** Interface representing a ManagedEnvironmentPrivateLinkResources. */ -export interface ManagedEnvironmentPrivateLinkResources { - /** - * List private link resources for a given managed environment. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param environmentName Name of the Managed Environment. - * @param options The options parameters. - */ - list( - resourceGroupName: string, - environmentName: string, - options?: ManagedEnvironmentPrivateLinkResourcesListOptionalParams, - ): PagedAsyncIterableIterator; -} diff --git a/sdk/appcontainers/arm-appcontainers/test/appcontainers_examples.spec.ts b/sdk/appcontainers/arm-appcontainers/test/appcontainers_examples.spec.ts deleted file mode 100644 index 1c8362a3e547..000000000000 --- a/sdk/appcontainers/arm-appcontainers/test/appcontainers_examples.spec.ts +++ /dev/null @@ -1,132 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { - env, - Recorder, - RecorderStartOptions, - isPlaybackMode, -} from "@azure-tools/test-recorder"; -import { createTestCredential } from "@azure-tools/test-credential"; -import { ContainerAppsAPIClient } from "../src/containerAppsAPIClient.js"; -import { ContainerApp, ManagedEnvironment } from "../src/models/index.js"; -import { describe, it, assert, beforeEach, afterEach } from "vitest"; - -const replaceableVariables: Record = { - SUBSCRIPTION_ID: "88888888-8888-8888-8888-888888888888" -}; - -const recorderOptions: RecorderStartOptions = { - envSetupForPlayback: replaceableVariables, - removeCentralSanitizers: [ - "AZSDK3493", // .name in the body is not a secret and is listed below in the beforeEach section - "AZSDK3430", // .id in the body is not a secret and is listed below in the beforeEach section - ], -}; - -export const testPollingOptions = { - updateIntervalInMs: isPlaybackMode() ? 0 : undefined, -}; - -describe("AppContainer test", () => { - let recorder: Recorder; - let subscriptionId: string; - let client: ContainerAppsAPIClient; - let location: string; - let resourceGroup: string; - let containerAppName: string; - let environmentEnvelope: ManagedEnvironment; - let containerAppEnvelope: ContainerApp; - let environmentName: string; - - beforeEach(async function (ctx) { - recorder = new Recorder(ctx); - await recorder.start(recorderOptions); - subscriptionId = env.SUBSCRIPTION_ID || ''; - // This is an example of how the environment variables are used - const credential = createTestCredential(); - client = new ContainerAppsAPIClient(credential, subscriptionId, recorder.configureClientOptions({})); - location = "westus"; - resourceGroup = "myjstest"; - containerAppName = "mycontainerappxxx"; - environmentName = "testcontainerenv12"; - }); - - afterEach(async function () { - await recorder.stop(); - }); - - it("operations list test", async function () { - const resArray = new Array(); - for await (const item of client.operations.list()) { - resArray.push(item); - } - assert.notEqual(resArray.length, 0); - }); - - it("managedEnvironments create test", async function () { - environmentEnvelope = { - location, - zoneRedundant: false - }; - const res = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroup, - environmentName, - environmentEnvelope, - testPollingOptions - ); - assert.equal(res.name, environmentName); - }) - - it("containerApp create test", async function () { - containerAppEnvelope = { - "location": location, - "managedEnvironmentId": "/subscriptions/" + subscriptionId + "/resourceGroups/" + resourceGroup + "/providers/Microsoft.App/managedEnvironments/" + environmentName, - template: { - containers: [ - { - name: "simple-hello-world-container", - image: "mcr.microsoft.com/azuredocs/containerapps-helloworld", - resources: { - cpu: 0.25, - memory: "0.5Gi" - } - } - ] - } - } - const res = await client.containerApps.beginCreateOrUpdateAndWait(resourceGroup, containerAppName, containerAppEnvelope, testPollingOptions); - assert.equal(res.name, containerAppName); - }); - - it("containerapp list Secrets test", async function () { - const res = await client.containerApps.listSecrets( - resourceGroup, - containerAppName - ); - console.log(res); - }); - - it("containerapp delete test", async function () { - await client.containerApps.beginDeleteAndWait(resourceGroup, containerAppName, testPollingOptions); - const resArray = new Array(); - for await (let item of client.containerApps.listByResourceGroup(resourceGroup)) { - resArray.push(item); - } - assert.equal(resArray.length, 0); - }) - - it("managedEnvironments delete test", async function () { - await client.managedEnvironments.beginDeleteAndWait(resourceGroup, environmentName, testPollingOptions); - const resArray = new Array(); - for await (let item of client.managedEnvironments.listByResourceGroup(resourceGroup)) { - resArray.push(item); - } - assert.equal(resArray.length, 0); - }) -}) diff --git a/sdk/appcontainers/arm-appcontainers/test/sampleTest.ts b/sdk/appcontainers/arm-appcontainers/test/sampleTest.ts new file mode 100644 index 000000000000..a1cf7c25afd2 --- /dev/null +++ b/sdk/appcontainers/arm-appcontainers/test/sampleTest.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. + */ + +import { + Recorder, + RecorderStartOptions, +} from "@azure-tools/test-recorder"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async (ctx) => { + recorder = new Recorder(ctx); + await recorder.start(recorderOptions); + }); + + afterEach(async () => { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/appcontainers/arm-appcontainers/test/snippets.spec.ts b/sdk/appcontainers/arm-appcontainers/test/snippets.spec.ts index 1dcc9342da8f..a1d5d09f6fbd 100644 --- a/sdk/appcontainers/arm-appcontainers/test/snippets.spec.ts +++ b/sdk/appcontainers/arm-appcontainers/test/snippets.spec.ts @@ -1,15 +1,29 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. import { ContainerAppsAPIClient } from "../src/index.js"; -import { DefaultAzureCredential, InteractiveBrowserCredential } from "@azure/identity"; +import { + DefaultAzureCredential, + InteractiveBrowserCredential, +} from "@azure/identity"; import { setLogLevel } from "@azure/logger"; import { describe, it } from "vitest"; describe("snippets", () => { it("ReadmeSampleCreateClient_Node", async () => { const subscriptionId = "00000000-0000-0000-0000-000000000000"; - const client = new ContainerAppsAPIClient(new DefaultAzureCredential(), subscriptionId); + const client = new ContainerAppsAPIClient( + new DefaultAzureCredential(), + subscriptionId, + ); }); it("ReadmeSampleCreateClient_Browser", async () => { diff --git a/sdk/appcontainers/arm-appcontainers/tsconfig.browser.config.json b/sdk/appcontainers/arm-appcontainers/tsconfig.browser.config.json index b6586181d006..0c8bafa97126 100644 --- a/sdk/appcontainers/arm-appcontainers/tsconfig.browser.config.json +++ b/sdk/appcontainers/arm-appcontainers/tsconfig.browser.config.json @@ -1,17 +1,6 @@ { - "extends": "./.tshy/build.json", - "include": [ - "./src/**/*.ts", - "./src/**/*.mts", - "./test/**/*.spec.ts", - "./test/**/*.mts" - ], - "exclude": [ - "./test/**/node/**/*.ts" - ], - "compilerOptions": { - "outDir": "./dist-test/browser", - "rootDir": ".", - "skipLibCheck": true - } + "extends": [ + "./tsconfig.test.json", + "../../../tsconfig.browser.base.json" + ] } diff --git a/sdk/appcontainers/arm-appcontainers/tsconfig.json b/sdk/appcontainers/arm-appcontainers/tsconfig.json index 19ceb382b521..b35d05ad6e9d 100644 --- a/sdk/appcontainers/arm-appcontainers/tsconfig.json +++ b/sdk/appcontainers/arm-appcontainers/tsconfig.json @@ -1,13 +1,27 @@ { - "references": [ - { - "path": "./tsconfig.src.json" - }, - { - "path": "./tsconfig.samples.json" - }, - { - "path": "./tsconfig.test.json" - } + "compilerOptions": { + "module": "es6", + "moduleResolution": "node", + "strict": true, + "target": "es6", + "sourceMap": true, + "declarationMap": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "forceConsistentCasingInFileNames": true, + "lib": [ + "es6", + "dom" + ], + "declaration": true, + "outDir": "./dist-esm", + "importHelpers": true + }, + "include": [ + "src/**/*.ts", + "test/**/*.ts" + ], + "exclude": [ + "node_modules" ] -} +} \ No newline at end of file diff --git a/sdk/appcontainers/arm-appcontainers/vitest.browser.config.ts b/sdk/appcontainers/arm-appcontainers/vitest.browser.config.ts index 0ee1aecbc47e..182729ab5ce9 100644 --- a/sdk/appcontainers/arm-appcontainers/vitest.browser.config.ts +++ b/sdk/appcontainers/arm-appcontainers/vitest.browser.config.ts @@ -9,11 +9,9 @@ export default mergeConfig( viteConfig, defineConfig({ test: { - include: [ - "dist-test/browser/test/**/*.spec.js", - ], - hookTimeout: 1200000, + include: ["dist-test/browser/test/**/*.spec.js",], testTimeout: 1200000, + hookTimeout: 1200000, }, }), ); diff --git a/sdk/appcontainers/arm-appcontainers/vitest.config.ts b/sdk/appcontainers/arm-appcontainers/vitest.config.ts index 2a4750c84292..40e031385dd8 100644 --- a/sdk/appcontainers/arm-appcontainers/vitest.config.ts +++ b/sdk/appcontainers/arm-appcontainers/vitest.config.ts @@ -1,3 +1,4 @@ + // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. @@ -8,8 +9,8 @@ export default mergeConfig( viteConfig, defineConfig({ test: { - hookTimeout: 1200000, testTimeout: 1200000, + hookTimeout: 1200000, }, }), ); diff --git a/sdk/core/core-rest-pipeline/review/core-rest-pipeline.api.md b/sdk/core/core-rest-pipeline/review/core-rest-pipeline.api.md index b1cb4778bd37..a5acb82880e8 100644 --- a/sdk/core/core-rest-pipeline/review/core-rest-pipeline.api.md +++ b/sdk/core/core-rest-pipeline/review/core-rest-pipeline.api.md @@ -375,9 +375,9 @@ export type RequestBodyType = NodeJS.ReadableStream | (() => NodeJS.ReadableStre // @public export class RestError extends Error { + // Warning: (ae-forgotten-export) The symbol "custom" needs to be exported by the entry point index.d.ts + [custom]: () => string; constructor(message: string, options?: RestErrorOptions); - // (undocumented) - [x: symbol]: () => string; code?: string; details?: unknown; static readonly PARSE_ERROR: string;