diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index b745c70f36bc..4f97b0a2c915 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -3971,7 +3971,7 @@ packages: dependencies: semver: 7.3.7 shelljs: 0.8.5 - typescript: 4.8.0-dev.20220804 + typescript: 4.8.0-dev.20220805 dev: false /downlevel-dts/0.4.0: @@ -8860,8 +8860,8 @@ packages: hasBin: true dev: false - /typescript/4.8.0-dev.20220804: - resolution: {integrity: sha512-N5tKzl5WE31E6YHL3nlYls2zCxkCfax3gb3zKKcrRJXEzfPRFodE0xzkIgGJIshTLQnF/uwiN2Nc8TG50aE9Hg==} + /typescript/4.8.0-dev.20220805: + resolution: {integrity: sha512-br4hTSU5UU+VnCdEDXgv4jeQduwNxNiYv30KW4cXU7W3fCxB8/UDd2OCqciN8H5pF//Lzo0clJBFHXbhrLx3eA==} engines: {node: '>=4.2.0'} hasBin: true dev: false @@ -10009,7 +10009,7 @@ packages: dev: false file:projects/arm-app.tgz: - resolution: {integrity: sha512-MBuEZe9zeDK0SS5qMXadnb39mMHcCk7VUzxVS+2JwrOCGPGejzqkplM1v10wWY+17nD+AbRLeGxfvn9fEAIXlw==, tarball: file:projects/arm-app.tgz} + resolution: {integrity: sha512-otTlrb80l+GmgMmPRUm/yWOdiYi1IM7c0pCdlONs7WIJTVKWu3avTyT5T2KmSgq/rp06sKa1c7M49j/Pyio5wA==, tarball: file:projects/arm-app.tgz} name: '@rush-temp/arm-app' version: 0.0.0 dependencies: @@ -10021,6 +10021,8 @@ packages: '@rollup/plugin-json': 4.1.0_rollup@2.77.0 '@rollup/plugin-multi-entry': 4.1.0_rollup@2.77.0 '@rollup/plugin-node-resolve': 13.3.0_rollup@2.77.0 + '@types/chai': 4.3.1 + chai: 4.3.6 cross-env: 7.0.3 mkdirp: 1.0.4 mocha: 7.2.0 @@ -10032,7 +10034,6 @@ packages: uglify-js: 3.16.3 transitivePeerDependencies: - '@types/node' - - encoding - supports-color dev: false diff --git a/sdk/app/arm-app/CHANGELOG.md b/sdk/app/arm-app/CHANGELOG.md index 3468066a2951..243d669d7b7a 100644 --- a/sdk/app/arm-app/CHANGELOG.md +++ b/sdk/app/arm-app/CHANGELOG.md @@ -1,5 +1,164 @@ # Release History +## 1.0.0-beta.1 (2022-08-05) + +**Features** + + - Added operation group ConnectedEnvironments + - Added operation group ConnectedEnvironmentsCertificates + - Added operation group ConnectedEnvironmentsDaprComponents + - Added operation group ConnectedEnvironmentsStorages + - Added operation group ContainerAppsDiagnostics + - Added operation group ManagedEnvironmentDiagnostics + - Added operation group ManagedEnvironmentsDiagnostics + - Added operation group Namespaces + - Added operation ContainerApps.beginUpdate + - Added operation ContainerApps.beginUpdateAndWait + - Added operation DaprComponents.listSecrets + - Added operation ManagedEnvironments.beginUpdate + - Added operation ManagedEnvironments.beginUpdateAndWait + - Added Interface AuthConfig + - Added Interface Certificate + - Added Interface CheckNameAvailabilityRequest + - Added Interface CheckNameAvailabilityResponse + - Added Interface ConnectedEnvironment + - Added Interface ConnectedEnvironmentCollection + - Added Interface ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams + - Added Interface ConnectedEnvironmentsCertificatesDeleteOptionalParams + - Added Interface ConnectedEnvironmentsCertificatesGetOptionalParams + - Added Interface ConnectedEnvironmentsCertificatesListNextOptionalParams + - Added Interface ConnectedEnvironmentsCertificatesListOptionalParams + - Added Interface ConnectedEnvironmentsCertificatesUpdateOptionalParams + - Added Interface ConnectedEnvironmentsCheckNameAvailabilityOptionalParams + - Added Interface ConnectedEnvironmentsCreateOrUpdateOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsDeleteOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsGetOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsListNextOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsListOptionalParams + - Added Interface ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams + - Added Interface ConnectedEnvironmentsDeleteOptionalParams + - Added Interface ConnectedEnvironmentsGetOptionalParams + - Added Interface ConnectedEnvironmentsListByResourceGroupNextOptionalParams + - Added Interface ConnectedEnvironmentsListByResourceGroupOptionalParams + - Added Interface ConnectedEnvironmentsListBySubscriptionNextOptionalParams + - Added Interface ConnectedEnvironmentsListBySubscriptionOptionalParams + - Added Interface ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams + - Added Interface ConnectedEnvironmentsStoragesDeleteOptionalParams + - Added Interface ConnectedEnvironmentsStoragesGetOptionalParams + - Added Interface ConnectedEnvironmentsStoragesListOptionalParams + - Added Interface ConnectedEnvironmentStorage + - Added Interface ConnectedEnvironmentStorageProperties + - Added Interface ConnectedEnvironmentStoragesCollection + - Added Interface ConnectedEnvironmentsUpdateOptionalParams + - Added Interface ContainerApp + - Added Interface ContainerAppsDiagnosticsGetDetectorOptionalParams + - Added Interface ContainerAppsDiagnosticsGetRevisionOptionalParams + - Added Interface ContainerAppsDiagnosticsGetRootOptionalParams + - Added Interface ContainerAppsDiagnosticsListDetectorsNextOptionalParams + - Added Interface ContainerAppsDiagnosticsListDetectorsOptionalParams + - Added Interface ContainerAppsDiagnosticsListRevisionsNextOptionalParams + - Added Interface ContainerAppsDiagnosticsListRevisionsOptionalParams + - Added Interface CustomHostnameAnalysisResult + - Added Interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo + - Added Interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem + - Added Interface DaprComponent + - Added Interface DaprComponentsListSecretsOptionalParams + - Added Interface DaprSecretsCollection + - Added Interface DiagnosticDataProviderMetadata + - Added Interface DiagnosticDataProviderMetadataPropertyBagItem + - Added Interface DiagnosticDataTableResponseColumn + - Added Interface DiagnosticDataTableResponseObject + - Added Interface DiagnosticRendering + - Added Interface Diagnostics + - Added Interface DiagnosticsCollection + - Added Interface DiagnosticsDataApiResponse + - Added Interface DiagnosticsDefinition + - Added Interface DiagnosticsProperties + - Added Interface DiagnosticsStatus + - Added Interface DiagnosticSupportTopic + - Added Interface ExtendedLocation + - Added Interface ManagedEnvironment + - Added Interface ManagedEnvironmentDiagnosticsGetDetectorOptionalParams + - Added Interface ManagedEnvironmentDiagnosticsListDetectorsOptionalParams + - Added Interface ManagedEnvironmentsDiagnosticsGetRootOptionalParams + - Added Interface ManagedEnvironmentStorage + - Added Interface NamespacesCheckNameAvailabilityOptionalParams + - Added Interface ProxyResource + - Added Interface Replica + - Added Interface Revision + - Added Interface SourceControl + - Added Interface TrackedResource + - Added Interface TrafficLabel + - Added Type Alias CheckNameAvailabilityReason + - Added Type Alias ConnectedEnvironmentProvisioningState + - Added Type Alias ConnectedEnvironmentsCertificatesCreateOrUpdateResponse + - Added Type Alias ConnectedEnvironmentsCertificatesGetResponse + - Added Type Alias ConnectedEnvironmentsCertificatesListNextResponse + - Added Type Alias ConnectedEnvironmentsCertificatesListResponse + - Added Type Alias ConnectedEnvironmentsCertificatesUpdateResponse + - Added Type Alias ConnectedEnvironmentsCheckNameAvailabilityResponse + - Added Type Alias ConnectedEnvironmentsCreateOrUpdateResponse + - Added Type Alias ConnectedEnvironmentsDaprComponentsCreateOrUpdateResponse + - Added Type Alias ConnectedEnvironmentsDaprComponentsGetResponse + - Added Type Alias ConnectedEnvironmentsDaprComponentsListNextResponse + - Added Type Alias ConnectedEnvironmentsDaprComponentsListResponse + - Added Type Alias ConnectedEnvironmentsDaprComponentsListSecretsResponse + - Added Type Alias ConnectedEnvironmentsGetResponse + - Added Type Alias ConnectedEnvironmentsListByResourceGroupNextResponse + - Added Type Alias ConnectedEnvironmentsListByResourceGroupResponse + - Added Type Alias ConnectedEnvironmentsListBySubscriptionNextResponse + - Added Type Alias ConnectedEnvironmentsListBySubscriptionResponse + - Added Type Alias ConnectedEnvironmentsStoragesCreateOrUpdateResponse + - Added Type Alias ConnectedEnvironmentsStoragesGetResponse + - Added Type Alias ConnectedEnvironmentsStoragesListResponse + - Added Type Alias ConnectedEnvironmentsUpdateResponse + - Added Type Alias ContainerAppsDiagnosticsGetDetectorResponse + - Added Type Alias ContainerAppsDiagnosticsGetRevisionResponse + - Added Type Alias ContainerAppsDiagnosticsGetRootResponse + - Added Type Alias ContainerAppsDiagnosticsListDetectorsNextResponse + - Added Type Alias ContainerAppsDiagnosticsListDetectorsResponse + - Added Type Alias ContainerAppsDiagnosticsListRevisionsNextResponse + - Added Type Alias ContainerAppsDiagnosticsListRevisionsResponse + - Added Type Alias DaprComponentsListSecretsResponse + - Added Type Alias ExtendedLocationTypes + - Added Type Alias ManagedEnvironmentDiagnosticsGetDetectorResponse + - Added Type Alias ManagedEnvironmentDiagnosticsListDetectorsResponse + - Added Type Alias ManagedEnvironmentsDiagnosticsGetRootResponse + - Added Type Alias NamespacesCheckNameAvailabilityResponse + - Added Type Alias Scheme + - Interface CertificateProperties has a new optional parameter subjectAlternativeNames + - Interface ContainerAppsRevisionsListRevisionsNextOptionalParams has a new optional parameter filter + - Interface ContainerAppsRevisionsListRevisionsOptionalParams has a new optional parameter filter + - Interface ContainerAppsUpdateOptionalParams has a new optional parameter resumeFrom + - Interface ContainerAppsUpdateOptionalParams has a new optional parameter updateIntervalInMs + - Interface Dapr has a new optional parameter httpReadBufferSize + - Interface GithubActionConfiguration has a new optional parameter contextPath + - Interface GithubActionConfiguration has a new optional parameter image + - Interface ManagedEnvironmentsUpdateOptionalParams has a new optional parameter resumeFrom + - Interface ManagedEnvironmentsUpdateOptionalParams has a new optional parameter updateIntervalInMs + - Interface RegistryCredentials has a new optional parameter identity + - Interface TrafficWeight has a new optional parameter label + - Class ContainerAppsAPIClient has a new parameter connectedEnvironments + - Class ContainerAppsAPIClient has a new parameter connectedEnvironmentsCertificates + - Class ContainerAppsAPIClient has a new parameter connectedEnvironmentsDaprComponents + - Class ContainerAppsAPIClient has a new parameter connectedEnvironmentsStorages + - Class ContainerAppsAPIClient has a new parameter containerAppsDiagnostics + - Class ContainerAppsAPIClient has a new parameter managedEnvironmentDiagnostics + - Class ContainerAppsAPIClient has a new parameter managedEnvironmentsDiagnostics + - Class ContainerAppsAPIClient has a new parameter namespaces + - Added Enum KnownCheckNameAvailabilityReason + - Added Enum KnownConnectedEnvironmentProvisioningState + - Added Enum KnownExtendedLocationTypes + - Added Enum KnownScheme + +**Breaking Changes** + + - Removed operation ContainerApps.update + - Removed operation ManagedEnvironments.update + - Interface GithubActionConfiguration no longer has parameter dockerfilePath + + ## 1.0.0-beta.1 (2022-03-23) The package of @azure/arm-app is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/js-track2-quickstart). diff --git a/sdk/app/arm-app/_meta.json b/sdk/app/arm-app/_meta.json index 8e9ec010d51b..ad455b880965 100644 --- a/sdk/app/arm-app/_meta.json +++ b/sdk/app/arm-app/_meta.json @@ -1,8 +1,8 @@ { - "commit": "82fdf284eea880a8e027c354911a814999a77178", + "commit": "f0c49369cdfb1ac2d26a70c8cf7a3b56ce4523c3", "readme": "specification/app/resource-manager/readme.md", - "autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\work\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\app\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-beta.17 --generate-sample=true", + "autorest_command": "", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.1.3", - "use": "@autorest/typescript@6.0.0-beta.17" + "release_tool": "@azure-tools/js-sdk-release-tools@2.4.1", + "use": "@autorest/typescript@6.0.0-rc.1" } \ No newline at end of file diff --git a/sdk/app/arm-app/package.json b/sdk/app/arm-app/package.json index 7b4daa6d778f..8124474a98ac 100644 --- a/sdk/app/arm-app/package.json +++ b/sdk/app/arm-app/package.json @@ -11,9 +11,9 @@ "@azure/core-lro": "^2.2.0", "@azure/abort-controller": "^1.0.0", "@azure/core-paging": "^1.2.0", - "@azure/core-client": "^1.0.0", + "@azure/core-client": "^1.5.0", "@azure/core-auth": "^1.3.0", - "@azure/core-rest-pipeline": "^1.1.0", + "@azure/core-rest-pipeline": "^1.8.0", "tslib": "^2.2.0" }, "keywords": [ @@ -40,9 +40,13 @@ "uglify-js": "^3.4.9", "rimraf": "^3.0.0", "@azure/identity": "^2.0.1", - "@azure-tools/test-recorder": "^1.0.0", + "@azure-tools/test-recorder": "^2.0.0", + "@azure-tools/test-credential": "^1.0.0", "mocha": "^7.1.1", - "cross-env": "^7.0.2" + "@types/chai": "^4.2.8", + "chai": "^4.2.0", + "cross-env": "^7.0.2", + "@azure/dev-tool": "^1.0.0" }, "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/app/arm-app", "repository": { @@ -93,9 +97,8 @@ "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", "unit-test:browser": "echo skipped", "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:node": "mocha -r esm --require ts-node/register --timeout 1200000 --full-trace test/*.ts --reporter ../../../common/tools/mocha-multi-reporter.js", - "integration-test:browser": "echo skipped", - "docs": "echo skipped" + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -106,13 +109,5 @@ } ] }, - "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-app?view=azure-node-preview" - } -} + "autoPublish": true +} \ No newline at end of file diff --git a/sdk/app/arm-app/recordings/node/my_test/recording_sample_test.js b/sdk/app/arm-app/recordings/node/my_test/recording_sample_test.js deleted file mode 100644 index 0f6ecb857acf..000000000000 --- a/sdk/app/arm-app/recordings/node/my_test/recording_sample_test.js +++ /dev/null @@ -1,5 +0,0 @@ -let nock = require('nock'); - -module.exports.hash = "7a6be38bb8cb644d64b4094802301751"; - -module.exports.testInfo = {"uniqueName":{},"newDate":{}} diff --git a/sdk/app/arm-app/review/arm-app.api.md b/sdk/app/arm-app/review/arm-app.api.md index b0546afd6ffa..89b9a6997328 100644 --- a/sdk/app/arm-app/review/arm-app.api.md +++ b/sdk/app/arm-app/review/arm-app.api.md @@ -56,13 +56,13 @@ export interface AppRegistration { } // @public -export type AuthConfig = ProxyResource & { - platform?: AuthPlatform; +export interface AuthConfig extends ProxyResource { globalValidation?: GlobalValidation; + httpSettings?: HttpSettings; identityProviders?: IdentityProviders; login?: Login; - httpSettings?: HttpSettings; -}; + platform?: AuthPlatform; +} // @public export interface AuthConfigCollection { @@ -145,9 +145,9 @@ export interface AzureStaticWebAppsRegistration { export type BindingType = string; // @public -export type Certificate = TrackedResource & { +export interface Certificate extends TrackedResource { properties?: CertificateProperties; -}; +} // @public export interface CertificateCollection { @@ -170,6 +170,7 @@ export interface CertificateProperties { password?: string; readonly provisioningState?: CertificateProvisioningState; readonly publicKeyHash?: string; + readonly subjectAlternativeNames?: string[]; readonly subjectName?: string; readonly thumbprint?: string; readonly valid?: boolean; @@ -181,11 +182,11 @@ export type CertificateProvisioningState = string; // @public export interface Certificates { - createOrUpdate(resourceGroupName: string, managedEnvironmentName: string, name: string, options?: CertificatesCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, managedEnvironmentName: string, name: string, options?: CertificatesDeleteOptionalParams): Promise; - get(resourceGroupName: string, managedEnvironmentName: string, name: string, options?: CertificatesGetOptionalParams): Promise; - list(resourceGroupName: string, managedEnvironmentName: string, options?: CertificatesListOptionalParams): PagedAsyncIterableIterator; - update(resourceGroupName: string, managedEnvironmentName: string, name: string, certificateEnvelope: CertificatePatch, options?: CertificatesUpdateOptionalParams): Promise; + createOrUpdate(resourceGroupName: string, environmentName: string, certificateName: string, options?: CertificatesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, environmentName: string, certificateName: string, options?: CertificatesDeleteOptionalParams): Promise; + get(resourceGroupName: string, environmentName: string, certificateName: string, options?: CertificatesGetOptionalParams): Promise; + list(resourceGroupName: string, environmentName: string, options?: CertificatesListOptionalParams): PagedAsyncIterableIterator; + update(resourceGroupName: string, environmentName: string, certificateName: string, certificateEnvelope: CertificatePatch, options?: CertificatesUpdateOptionalParams): Promise; } // @public @@ -228,6 +229,22 @@ export interface CertificatesUpdateOptionalParams extends coreClient.OperationOp // @public export type CertificatesUpdateResponse = Certificate; +// @public +export type CheckNameAvailabilityReason = string; + +// @public +export interface CheckNameAvailabilityRequest { + name?: string; + type?: string; +} + +// @public +export interface CheckNameAvailabilityResponse { + message?: string; + nameAvailable?: boolean; + reason?: CheckNameAvailabilityReason; +} + // @public export interface ClientRegistration { clientId?: string; @@ -243,6 +260,247 @@ export interface Configuration { secrets?: Secret[]; } +// @public +export interface ConnectedEnvironment extends TrackedResource { + daprAIConnectionString?: string; + readonly defaultDomain?: string; + readonly deploymentErrors?: string; + extendedLocation?: ExtendedLocation; + readonly provisioningState?: ConnectedEnvironmentProvisioningState; + staticIp?: string; +} + +// @public +export interface ConnectedEnvironmentCollection { + readonly nextLink?: string; + value?: ConnectedEnvironment[]; +} + +// @public +export type ConnectedEnvironmentProvisioningState = string; + +// @public +export interface ConnectedEnvironments { + beginCreateOrUpdate(resourceGroupName: string, connectedEnvironmentName: string, environmentEnvelope: ConnectedEnvironment, options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams): Promise, ConnectedEnvironmentsCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, connectedEnvironmentName: string, environmentEnvelope: ConnectedEnvironment, options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams): Promise; + beginDelete(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsDeleteOptionalParams): Promise, void>>; + beginDeleteAndWait(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsDeleteOptionalParams): Promise; + checkNameAvailability(resourceGroupName: string, connectedEnvironmentName: string, checkNameAvailabilityRequest: CheckNameAvailabilityRequest, options?: ConnectedEnvironmentsCheckNameAvailabilityOptionalParams): Promise; + get(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsGetOptionalParams): Promise; + listByResourceGroup(resourceGroupName: string, options?: ConnectedEnvironmentsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; + listBySubscription(options?: ConnectedEnvironmentsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; + update(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsUpdateOptionalParams): Promise; +} + +// @public +export interface ConnectedEnvironmentsCertificates { + createOrUpdate(resourceGroupName: string, connectedEnvironmentName: string, certificateName: string, options?: ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, connectedEnvironmentName: string, certificateName: string, options?: ConnectedEnvironmentsCertificatesDeleteOptionalParams): Promise; + get(resourceGroupName: string, connectedEnvironmentName: string, certificateName: string, options?: ConnectedEnvironmentsCertificatesGetOptionalParams): Promise; + list(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsCertificatesListOptionalParams): PagedAsyncIterableIterator; + update(resourceGroupName: string, connectedEnvironmentName: string, certificateName: string, certificateEnvelope: CertificatePatch, options?: ConnectedEnvironmentsCertificatesUpdateOptionalParams): Promise; +} + +// @public +export interface ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { + certificateEnvelope?: Certificate; +} + +// @public +export type ConnectedEnvironmentsCertificatesCreateOrUpdateResponse = Certificate; + +// @public +export interface ConnectedEnvironmentsCertificatesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ConnectedEnvironmentsCertificatesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsCertificatesGetResponse = Certificate; + +// @public +export interface ConnectedEnvironmentsCertificatesListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsCertificatesListNextResponse = CertificateCollection; + +// @public +export interface ConnectedEnvironmentsCertificatesListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsCertificatesListResponse = CertificateCollection; + +// @public +export interface ConnectedEnvironmentsCertificatesUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsCertificatesUpdateResponse = Certificate; + +// @public +export interface ConnectedEnvironmentsCheckNameAvailabilityOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; + +// @public +export interface ConnectedEnvironmentsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + +// @public +export type ConnectedEnvironmentsCreateOrUpdateResponse = ConnectedEnvironment; + +// @public +export interface ConnectedEnvironmentsDaprComponents { + createOrUpdate(resourceGroupName: string, connectedEnvironmentName: string, componentName: string, daprComponentEnvelope: DaprComponent, options?: ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, connectedEnvironmentName: string, componentName: string, options?: ConnectedEnvironmentsDaprComponentsDeleteOptionalParams): Promise; + get(resourceGroupName: string, connectedEnvironmentName: string, componentName: string, options?: ConnectedEnvironmentsDaprComponentsGetOptionalParams): Promise; + list(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsDaprComponentsListOptionalParams): PagedAsyncIterableIterator; + listSecrets(resourceGroupName: string, connectedEnvironmentName: string, componentName: string, options?: ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams): Promise; +} + +// @public +export interface ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsDaprComponentsCreateOrUpdateResponse = DaprComponent; + +// @public +export interface ConnectedEnvironmentsDaprComponentsDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ConnectedEnvironmentsDaprComponentsGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsDaprComponentsGetResponse = DaprComponent; + +// @public +export interface ConnectedEnvironmentsDaprComponentsListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsDaprComponentsListNextResponse = DaprComponentsCollection; + +// @public +export interface ConnectedEnvironmentsDaprComponentsListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsDaprComponentsListResponse = DaprComponentsCollection; + +// @public +export interface ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsDaprComponentsListSecretsResponse = DaprSecretsCollection; + +// @public +export interface ConnectedEnvironmentsDeleteOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + +// @public +export interface ConnectedEnvironmentsGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsGetResponse = ConnectedEnvironment; + +// @public +export interface ConnectedEnvironmentsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsListByResourceGroupNextResponse = ConnectedEnvironmentCollection; + +// @public +export interface ConnectedEnvironmentsListByResourceGroupOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsListByResourceGroupResponse = ConnectedEnvironmentCollection; + +// @public +export interface ConnectedEnvironmentsListBySubscriptionNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsListBySubscriptionNextResponse = ConnectedEnvironmentCollection; + +// @public +export interface ConnectedEnvironmentsListBySubscriptionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsListBySubscriptionResponse = ConnectedEnvironmentCollection; + +// @public +export interface ConnectedEnvironmentsStorages { + createOrUpdate(resourceGroupName: string, connectedEnvironmentName: string, storageName: string, storageEnvelope: ConnectedEnvironmentStorage, options?: ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, connectedEnvironmentName: string, storageName: string, options?: ConnectedEnvironmentsStoragesDeleteOptionalParams): Promise; + get(resourceGroupName: string, connectedEnvironmentName: string, storageName: string, options?: ConnectedEnvironmentsStoragesGetOptionalParams): Promise; + list(resourceGroupName: string, connectedEnvironmentName: string, options?: ConnectedEnvironmentsStoragesListOptionalParams): Promise; +} + +// @public +export interface ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsStoragesCreateOrUpdateResponse = ConnectedEnvironmentStorage; + +// @public +export interface ConnectedEnvironmentsStoragesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ConnectedEnvironmentsStoragesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsStoragesGetResponse = ConnectedEnvironmentStorage; + +// @public +export interface ConnectedEnvironmentsStoragesListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsStoragesListResponse = ConnectedEnvironmentStoragesCollection; + +// @public +export interface ConnectedEnvironmentStorage extends ProxyResource { + properties?: ConnectedEnvironmentStorageProperties; +} + +// @public +export interface ConnectedEnvironmentStorageProperties { + azureFile?: AzureFileProperties; +} + +// @public +export interface ConnectedEnvironmentStoragesCollection { + value: ConnectedEnvironmentStorage[]; +} + +// @public +export interface ConnectedEnvironmentsUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ConnectedEnvironmentsUpdateResponse = ConnectedEnvironment; + // @public export interface Container { args?: string[]; @@ -256,17 +514,19 @@ export interface Container { } // @public -export type ContainerApp = TrackedResource & { +export interface ContainerApp extends TrackedResource { + configuration?: Configuration; + readonly customDomainVerificationId?: string; + environmentId?: string; + extendedLocation?: ExtendedLocation; identity?: ManagedServiceIdentity; - readonly provisioningState?: ContainerAppProvisioningState; - managedEnvironmentId?: string; - readonly latestRevisionName?: string; readonly latestRevisionFqdn?: string; - readonly customDomainVerificationId?: string; - configuration?: Configuration; - template?: Template; + readonly latestRevisionName?: string; + managedEnvironmentId?: string; readonly outboundIPAddresses?: string[]; -}; + readonly provisioningState?: ContainerAppProvisioningState; + template?: Template; +} // @public export interface ContainerAppCollection { @@ -274,13 +534,6 @@ export interface ContainerAppCollection { value: ContainerApp[]; } -// @public -export interface ContainerAppPatch { - tags?: { - [propertyName: string]: string; - }; -} - // @public export interface ContainerAppProbe { failureThreshold?: number; @@ -300,7 +553,7 @@ export interface ContainerAppProbeHttpGet { httpHeaders?: ContainerAppProbeHttpGetHttpHeadersItem[]; path?: string; port: number; - scheme?: string; + scheme?: Scheme; } // @public @@ -320,16 +573,17 @@ export type ContainerAppProvisioningState = string; // @public export interface ContainerApps { - beginCreateOrUpdate(resourceGroupName: string, name: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise, ContainerAppsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams): Promise, void>>; - beginDeleteAndWait(resourceGroupName: string, name: string, options?: ContainerAppsDeleteOptionalParams): Promise; - get(resourceGroupName: string, name: string, options?: ContainerAppsGetOptionalParams): Promise; + beginCreateOrUpdate(resourceGroupName: string, containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise, ContainerAppsCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams): Promise; + beginDelete(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDeleteOptionalParams): Promise, void>>; + beginDeleteAndWait(resourceGroupName: string, containerAppName: string, options?: ContainerAppsDeleteOptionalParams): Promise; + beginUpdate(resourceGroupName: string, containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsUpdateOptionalParams): Promise, void>>; + beginUpdateAndWait(resourceGroupName: string, containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsUpdateOptionalParams): Promise; + get(resourceGroupName: string, containerAppName: string, options?: ContainerAppsGetOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: ContainerAppsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; listBySubscription(options?: ContainerAppsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; listCustomHostNameAnalysis(resourceGroupName: string, containerAppName: string, options?: ContainerAppsListCustomHostNameAnalysisOptionalParams): Promise; - listSecrets(resourceGroupName: string, name: string, options?: ContainerAppsListSecretsOptionalParams): Promise; - update(resourceGroupName: string, name: string, containerAppEnvelope: ContainerAppPatch, options?: ContainerAppsUpdateOptionalParams): Promise; + listSecrets(resourceGroupName: string, containerAppName: string, options?: ContainerAppsListSecretsOptionalParams): Promise; } // @public (undocumented) @@ -342,10 +596,20 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) certificates: Certificates; // (undocumented) + connectedEnvironments: ConnectedEnvironments; + // (undocumented) + connectedEnvironmentsCertificates: ConnectedEnvironmentsCertificates; + // (undocumented) + connectedEnvironmentsDaprComponents: ConnectedEnvironmentsDaprComponents; + // (undocumented) + connectedEnvironmentsStorages: ConnectedEnvironmentsStorages; + // (undocumented) containerApps: ContainerApps; // (undocumented) containerAppsAuthConfigs: ContainerAppsAuthConfigs; // (undocumented) + containerAppsDiagnostics: ContainerAppsDiagnostics; + // (undocumented) containerAppsRevisionReplicas: ContainerAppsRevisionReplicas; // (undocumented) containerAppsRevisions: ContainerAppsRevisions; @@ -354,10 +618,16 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { // (undocumented) daprComponents: DaprComponents; // (undocumented) + managedEnvironmentDiagnostics: ManagedEnvironmentDiagnostics; + // (undocumented) managedEnvironments: ManagedEnvironments; // (undocumented) + managedEnvironmentsDiagnostics: ManagedEnvironmentsDiagnostics; + // (undocumented) managedEnvironmentsStorages: ManagedEnvironmentsStorages; // (undocumented) + namespaces: Namespaces; + // (undocumented) operations: Operations; // (undocumented) subscriptionId: string; @@ -372,9 +642,9 @@ export interface ContainerAppsAPIClientOptionalParams extends coreClient.Service // @public export interface ContainerAppsAuthConfigs { - createOrUpdate(resourceGroupName: string, containerAppName: string, name: string, authConfigEnvelope: AuthConfig, options?: ContainerAppsAuthConfigsCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsAuthConfigsDeleteOptionalParams): Promise; - get(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsAuthConfigsGetOptionalParams): Promise; + createOrUpdate(resourceGroupName: string, containerAppName: string, authConfigName: string, authConfigEnvelope: AuthConfig, options?: ContainerAppsAuthConfigsCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, containerAppName: string, authConfigName: string, options?: ContainerAppsAuthConfigsDeleteOptionalParams): Promise; + get(resourceGroupName: string, containerAppName: string, authConfigName: string, options?: ContainerAppsAuthConfigsGetOptionalParams): Promise; listByContainerApp(resourceGroupName: string, containerAppName: string, options?: ContainerAppsAuthConfigsListByContainerAppOptionalParams): PagedAsyncIterableIterator; } @@ -425,6 +695,66 @@ export interface ContainerAppsDeleteOptionalParams extends coreClient.OperationO 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; + +// @public +export interface ContainerAppsDiagnosticsListDetectorsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ContainerAppsDiagnosticsListDetectorsNextResponse = DiagnosticsCollection; + +// @public +export interface ContainerAppsDiagnosticsListDetectorsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ContainerAppsDiagnosticsListDetectorsResponse = DiagnosticsCollection; + +// @public +export interface ContainerAppsDiagnosticsListRevisionsNextOptionalParams extends coreClient.OperationOptions { + filter?: string; +} + +// @public +export type ContainerAppsDiagnosticsListRevisionsNextResponse = RevisionCollection; + +// @public +export interface ContainerAppsDiagnosticsListRevisionsOptionalParams extends coreClient.OperationOptions { + filter?: string; +} + +// @public +export type ContainerAppsDiagnosticsListRevisionsResponse = RevisionCollection; + // @public export interface ContainerAppSecret { readonly name?: string; @@ -483,7 +813,7 @@ export type ContainerAppsListSecretsResponse = SecretsCollection; // @public export interface ContainerAppsRevisionReplicas { - getReplica(resourceGroupName: string, containerAppName: string, revisionName: string, name: string, options?: ContainerAppsRevisionReplicasGetReplicaOptionalParams): Promise; + getReplica(resourceGroupName: string, containerAppName: string, revisionName: string, replicaName: string, options?: ContainerAppsRevisionReplicasGetReplicaOptionalParams): Promise; listReplicas(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsRevisionReplicasListReplicasOptionalParams): Promise; } @@ -503,11 +833,11 @@ export type ContainerAppsRevisionReplicasListReplicasResponse = ReplicaCollectio // @public export interface ContainerAppsRevisions { - activateRevision(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsRevisionsActivateRevisionOptionalParams): Promise; - deactivateRevision(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsRevisionsDeactivateRevisionOptionalParams): Promise; - getRevision(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsRevisionsGetRevisionOptionalParams): Promise; + activateRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsRevisionsActivateRevisionOptionalParams): Promise; + deactivateRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsRevisionsDeactivateRevisionOptionalParams): Promise; + getRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsRevisionsGetRevisionOptionalParams): Promise; listRevisions(resourceGroupName: string, containerAppName: string, options?: ContainerAppsRevisionsListRevisionsOptionalParams): PagedAsyncIterableIterator; - restartRevision(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsRevisionsRestartRevisionOptionalParams): Promise; + restartRevision(resourceGroupName: string, containerAppName: string, revisionName: string, options?: ContainerAppsRevisionsRestartRevisionOptionalParams): Promise; } // @public @@ -527,6 +857,7 @@ export type ContainerAppsRevisionsGetRevisionResponse = Revision; // @public export interface ContainerAppsRevisionsListRevisionsNextOptionalParams extends coreClient.OperationOptions { + filter?: string; } // @public @@ -534,6 +865,7 @@ export type ContainerAppsRevisionsListRevisionsNextResponse = RevisionCollection // @public export interface ContainerAppsRevisionsListRevisionsOptionalParams extends coreClient.OperationOptions { + filter?: string; } // @public @@ -545,11 +877,11 @@ export interface ContainerAppsRevisionsRestartRevisionOptionalParams extends cor // @public export interface ContainerAppsSourceControls { - beginCreateOrUpdate(resourceGroupName: string, containerAppName: string, name: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams): Promise, ContainerAppsSourceControlsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, containerAppName: string, name: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsSourceControlsDeleteOptionalParams): Promise, void>>; - beginDeleteAndWait(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsSourceControlsDeleteOptionalParams): Promise; - get(resourceGroupName: string, containerAppName: string, name: string, options?: ContainerAppsSourceControlsGetOptionalParams): Promise; + beginCreateOrUpdate(resourceGroupName: string, containerAppName: string, sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams): Promise, ContainerAppsSourceControlsCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, containerAppName: string, sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams): Promise; + beginDelete(resourceGroupName: string, containerAppName: string, sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams): Promise, void>>; + beginDeleteAndWait(resourceGroupName: string, containerAppName: string, sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams): Promise; + get(resourceGroupName: string, containerAppName: string, sourceControlName: string, options?: ContainerAppsSourceControlsGetOptionalParams): Promise; listByContainerApp(resourceGroupName: string, containerAppName: string, options?: ContainerAppsSourceControlsListByContainerAppOptionalParams): PagedAsyncIterableIterator; } @@ -591,11 +923,10 @@ export type ContainerAppsSourceControlsListByContainerAppResponse = SourceContro // @public export interface ContainerAppsUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } -// @public -export type ContainerAppsUpdateResponse = ContainerApp; - // @public export interface ContainerResources { cpu?: number; @@ -623,19 +954,34 @@ export interface CustomDomain { } // @public -export type CustomHostnameAnalysisResult = ProxyResource & { - readonly hostName?: string; - readonly isHostnameAlreadyVerified?: boolean; +export interface CustomHostnameAnalysisResult { + alternateCNameRecords?: string[]; + alternateTxtRecords?: string[]; + aRecords?: string[]; + cNameRecords?: string[]; + readonly conflictingContainerAppResourceId?: string; + readonly customDomainVerificationFailureInfo?: CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo; readonly customDomainVerificationTest?: DnsVerificationTestResult; - readonly customDomainVerificationFailureInfo?: DefaultErrorResponse; readonly hasConflictOnManagedEnvironment?: boolean; - readonly conflictingContainerAppResourceId?: string; - cNameRecords?: string[]; + readonly hostName?: string; + readonly isHostnameAlreadyVerified?: boolean; txtRecords?: string[]; - aRecords?: string[]; - alternateCNameRecords?: string[]; - alternateTxtRecords?: string[]; -}; +} + +// @public +export interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo { + readonly code?: string; + details?: CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem[]; + readonly message?: string; + readonly target?: string; +} + +// @public +export interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem { + readonly code?: string; + readonly message?: string; + readonly target?: string; +} // @public export interface CustomOpenIdConnectProvider { @@ -659,25 +1005,28 @@ export interface Dapr { appPort?: number; appProtocol?: AppProtocol; enabled?: boolean; + // (undocumented) + httpReadBufferSize?: number; } // @public -export type DaprComponent = ProxyResource & { +export interface DaprComponent extends ProxyResource { componentType?: string; - version?: string; ignoreErrors?: boolean; initTimeout?: string; - secrets?: Secret[]; metadata?: DaprMetadata[]; scopes?: string[]; -}; + secrets?: Secret[]; + version?: string; +} // @public export interface DaprComponents { - createOrUpdate(resourceGroupName: string, environmentName: string, name: string, daprComponentEnvelope: DaprComponent, options?: DaprComponentsCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, environmentName: string, name: string, options?: DaprComponentsDeleteOptionalParams): Promise; - get(resourceGroupName: string, environmentName: string, name: string, options?: DaprComponentsGetOptionalParams): Promise; + createOrUpdate(resourceGroupName: string, environmentName: string, componentName: string, daprComponentEnvelope: DaprComponent, options?: DaprComponentsCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, environmentName: string, componentName: string, options?: DaprComponentsDeleteOptionalParams): Promise; + get(resourceGroupName: string, environmentName: string, componentName: string, options?: DaprComponentsGetOptionalParams): Promise; list(resourceGroupName: string, environmentName: string, options?: DaprComponentsListOptionalParams): PagedAsyncIterableIterator; + listSecrets(resourceGroupName: string, environmentName: string, componentName: string, options?: DaprComponentsListSecretsOptionalParams): Promise; } // @public @@ -718,6 +1067,13 @@ export interface DaprComponentsListOptionalParams extends coreClient.OperationOp // @public export type DaprComponentsListResponse = DaprComponentsCollection; +// @public +export interface DaprComponentsListSecretsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type DaprComponentsListSecretsResponse = DaprSecretsCollection; + // @public export interface DaprMetadata { name?: string; @@ -725,6 +1081,11 @@ export interface DaprMetadata { value?: string; } +// @public +export interface DaprSecretsCollection { + value: Secret[]; +} + // @public export interface DefaultAuthorizationPolicy { allowedApplications?: string[]; @@ -752,6 +1113,90 @@ export interface DefaultErrorResponseErrorDetailsItem { readonly target?: string; } +// @public +export interface DiagnosticDataProviderMetadata { + propertyBag?: DiagnosticDataProviderMetadataPropertyBagItem[]; + providerName?: string; +} + +// @public +export interface DiagnosticDataProviderMetadataPropertyBagItem { + name?: string; + value?: string; +} + +// @public +export interface DiagnosticDataTableResponseColumn { + columnName?: string; + columnType?: string; + dataType?: string; +} + +// @public +export interface DiagnosticDataTableResponseObject { + columns?: DiagnosticDataTableResponseColumn[]; + rows?: Record[]; + tableName?: string; +} + +// @public +export interface DiagnosticRendering { + description?: string; + isVisible?: boolean; + title?: string; + type?: number; +} + +// @public +export interface Diagnostics extends ProxyResource { + properties?: DiagnosticsProperties; +} + +// @public +export interface DiagnosticsCollection { + readonly nextLink?: string; + value: Diagnostics[]; +} + +// @public +export interface DiagnosticsDataApiResponse { + renderingProperties?: DiagnosticRendering; + table?: DiagnosticDataTableResponseObject; +} + +// @public +export interface DiagnosticsDefinition { + analysisTypes?: string[]; + readonly author?: string; + readonly category?: string; + readonly description?: string; + readonly id?: string; + readonly name?: string; + readonly score?: number; + supportTopicList?: DiagnosticSupportTopic[]; + readonly type?: string; +} + +// @public +export interface DiagnosticsProperties { + dataProviderMetadata?: DiagnosticDataProviderMetadata; + dataset?: DiagnosticsDataApiResponse[]; + metadata?: DiagnosticsDefinition; + status?: DiagnosticsStatus; +} + +// @public +export interface DiagnosticsStatus { + message?: string; + statusId?: number; +} + +// @public +export interface DiagnosticSupportTopic { + readonly id?: string; + readonly pesId?: string; +} + // @public export type DnsVerificationTestResult = "Passed" | "Failed" | "Skipped"; @@ -765,6 +1210,15 @@ export interface EnvironmentVar { value?: string; } +// @public +export interface ExtendedLocation { + name?: string; + type?: ExtendedLocationTypes; +} + +// @public +export type ExtendedLocationTypes = string; + // @public export interface Facebook { enabled?: boolean; @@ -793,7 +1247,8 @@ export interface GitHub { // @public export interface GithubActionConfiguration { azureCredentials?: AzureCredentials; - dockerfilePath?: string; + contextPath?: string; + image?: string; os?: string; publishType?: string; registryInfo?: RegistryInfo; @@ -872,172 +1327,146 @@ export interface JwtClaimChecks { // @public export enum KnownAccessMode { - // (undocumented) ReadOnly = "ReadOnly", - // (undocumented) ReadWrite = "ReadWrite" } // @public export enum KnownActiveRevisionsMode { - // (undocumented) - Multiple = "multiple", - // (undocumented) - Single = "single" + Multiple = "Multiple", + Single = "Single" } // @public export enum KnownAppProtocol { - // (undocumented) Grpc = "grpc", - // (undocumented) Http = "http" } // @public export enum KnownBindingType { - // (undocumented) Disabled = "Disabled", - // (undocumented) SniEnabled = "SniEnabled" } // @public export enum KnownCertificateProvisioningState { - // (undocumented) Canceled = "Canceled", - // (undocumented) DeleteFailed = "DeleteFailed", - // (undocumented) Failed = "Failed", - // (undocumented) Pending = "Pending", - // (undocumented) Succeeded = "Succeeded" } +// @public +export enum KnownCheckNameAvailabilityReason { + AlreadyExists = "AlreadyExists", + Invalid = "Invalid" +} + +// @public +export enum KnownConnectedEnvironmentProvisioningState { + Canceled = "Canceled", + Failed = "Failed", + InfrastructureSetupComplete = "InfrastructureSetupComplete", + InfrastructureSetupInProgress = "InfrastructureSetupInProgress", + InitializationInProgress = "InitializationInProgress", + ScheduledForDelete = "ScheduledForDelete", + Succeeded = "Succeeded", + Waiting = "Waiting" +} + // @public export enum KnownContainerAppProvisioningState { - // (undocumented) Canceled = "Canceled", - // (undocumented) Failed = "Failed", - // (undocumented) InProgress = "InProgress", - // (undocumented) Succeeded = "Succeeded" } // @public export enum KnownCreatedByType { - // (undocumented) Application = "Application", - // (undocumented) Key = "Key", - // (undocumented) ManagedIdentity = "ManagedIdentity", - // (undocumented) User = "User" } // @public export enum KnownEnvironmentProvisioningState { - // (undocumented) Canceled = "Canceled", - // (undocumented) Failed = "Failed", - // (undocumented) InfrastructureSetupComplete = "InfrastructureSetupComplete", - // (undocumented) InfrastructureSetupInProgress = "InfrastructureSetupInProgress", - // (undocumented) InitializationInProgress = "InitializationInProgress", - // (undocumented) ScheduledForDelete = "ScheduledForDelete", - // (undocumented) Succeeded = "Succeeded", - // (undocumented) UpgradeFailed = "UpgradeFailed", - // (undocumented) UpgradeRequested = "UpgradeRequested", - // (undocumented) Waiting = "Waiting" } +// @public +export enum KnownExtendedLocationTypes { + CustomLocation = "CustomLocation" +} + // @public export enum KnownIngressTransportMethod { - // (undocumented) Auto = "auto", - // (undocumented) Http = "http", - // (undocumented) Http2 = "http2" } // @public export enum KnownManagedServiceIdentityType { - // (undocumented) None = "None", - // (undocumented) SystemAssigned = "SystemAssigned", - // (undocumented) SystemAssignedUserAssigned = "SystemAssigned,UserAssigned", - // (undocumented) UserAssigned = "UserAssigned" } // @public export enum KnownRevisionHealthState { - // (undocumented) Healthy = "Healthy", - // (undocumented) None = "None", - // (undocumented) Unhealthy = "Unhealthy" } // @public export enum KnownRevisionProvisioningState { - // (undocumented) Deprovisioned = "Deprovisioned", - // (undocumented) Deprovisioning = "Deprovisioning", - // (undocumented) Failed = "Failed", - // (undocumented) Provisioned = "Provisioned", - // (undocumented) Provisioning = "Provisioning" } +// @public +export enum KnownScheme { + Http = "HTTP", + Https = "HTTPS" +} + // @public export enum KnownSourceControlOperationState { - // (undocumented) Canceled = "Canceled", - // (undocumented) Failed = "Failed", - // (undocumented) InProgress = "InProgress", - // (undocumented) Succeeded = "Succeeded" } // @public export enum KnownStorageType { - // (undocumented) AzureFile = "AzureFile", - // (undocumented) EmptyDir = "EmptyDir" } // @public export enum KnownType { - // (undocumented) - Liveness = "liveness", - // (undocumented) - Readiness = "readiness", - // (undocumented) - Startup = "startup" + Liveness = "Liveness", + Readiness = "Readiness", + Startup = "Startup" } // @public @@ -1066,33 +1495,49 @@ export interface LoginScopes { } // @public -export type ManagedEnvironment = TrackedResource & { - readonly provisioningState?: EnvironmentProvisioningState; +export interface ManagedEnvironment extends TrackedResource { + appLogsConfiguration?: AppLogsConfiguration; + daprAIConnectionString?: string; daprAIInstrumentationKey?: string; - vnetConfiguration?: VnetConfiguration; - readonly deploymentErrors?: string; readonly defaultDomain?: string; + readonly deploymentErrors?: string; + readonly provisioningState?: EnvironmentProvisioningState; readonly staticIp?: string; - appLogsConfiguration?: AppLogsConfiguration; -}; + vnetConfiguration?: VnetConfiguration; + zoneRedundant?: boolean; +} // @public -export interface ManagedEnvironmentPatch { - tags?: { - [propertyName: string]: string; - }; +export interface ManagedEnvironmentDiagnostics { + getDetector(resourceGroupName: string, environmentName: string, detectorName: string, options?: ManagedEnvironmentDiagnosticsGetDetectorOptionalParams): Promise; + listDetectors(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentDiagnosticsListDetectorsOptionalParams): Promise; } +// @public +export interface ManagedEnvironmentDiagnosticsGetDetectorOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedEnvironmentDiagnosticsGetDetectorResponse = Diagnostics; + +// @public +export interface ManagedEnvironmentDiagnosticsListDetectorsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedEnvironmentDiagnosticsListDetectorsResponse = DiagnosticsCollection; + // @public export interface ManagedEnvironments { - beginCreateOrUpdate(resourceGroupName: string, name: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams): Promise, ManagedEnvironmentsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, name: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams): Promise; - beginDelete(resourceGroupName: string, name: string, options?: ManagedEnvironmentsDeleteOptionalParams): Promise, void>>; - beginDeleteAndWait(resourceGroupName: string, name: string, options?: ManagedEnvironmentsDeleteOptionalParams): Promise; - get(resourceGroupName: string, name: string, options?: ManagedEnvironmentsGetOptionalParams): Promise; + beginCreateOrUpdate(resourceGroupName: string, environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams): Promise, ManagedEnvironmentsCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams): Promise; + beginDelete(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams): Promise, void>>; + beginDeleteAndWait(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams): Promise; + beginUpdate(resourceGroupName: string, environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsUpdateOptionalParams): Promise, void>>; + beginUpdateAndWait(resourceGroupName: string, environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsUpdateOptionalParams): Promise; + get(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentsGetOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: ManagedEnvironmentsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; listBySubscription(options?: ManagedEnvironmentsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; - update(resourceGroupName: string, name: string, environmentEnvelope: ManagedEnvironmentPatch, options?: ManagedEnvironmentsUpdateOptionalParams): Promise; } // @public @@ -1116,6 +1561,18 @@ export interface ManagedEnvironmentsDeleteOptionalParams extends coreClient.Oper updateIntervalInMs?: number; } +// @public +export interface ManagedEnvironmentsDiagnostics { + getRoot(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentsDiagnosticsGetRootOptionalParams): Promise; +} + +// @public +export interface ManagedEnvironmentsDiagnosticsGetRootOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedEnvironmentsDiagnosticsGetRootResponse = ManagedEnvironment; + // @public export interface ManagedEnvironmentsGetOptionalParams extends coreClient.OperationOptions { } @@ -1153,10 +1610,10 @@ export type ManagedEnvironmentsListBySubscriptionResponse = ManagedEnvironmentsC // @public export interface ManagedEnvironmentsStorages { - createOrUpdate(resourceGroupName: string, envName: string, name: string, storageEnvelope: ManagedEnvironmentStorage, options?: ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, envName: string, name: string, options?: ManagedEnvironmentsStoragesDeleteOptionalParams): Promise; - get(resourceGroupName: string, envName: string, name: string, options?: ManagedEnvironmentsStoragesGetOptionalParams): Promise; - list(resourceGroupName: string, envName: string, options?: ManagedEnvironmentsStoragesListOptionalParams): Promise; + createOrUpdate(resourceGroupName: string, environmentName: string, storageName: string, storageEnvelope: ManagedEnvironmentStorage, options?: ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, environmentName: string, storageName: string, options?: ManagedEnvironmentsStoragesDeleteOptionalParams): Promise; + get(resourceGroupName: string, environmentName: string, storageName: string, options?: ManagedEnvironmentsStoragesGetOptionalParams): Promise; + list(resourceGroupName: string, environmentName: string, options?: ManagedEnvironmentsStoragesListOptionalParams): Promise; } // @public @@ -1185,9 +1642,9 @@ export interface ManagedEnvironmentsStoragesListOptionalParams extends coreClien export type ManagedEnvironmentsStoragesListResponse = ManagedEnvironmentStoragesCollection; // @public -export type ManagedEnvironmentStorage = ProxyResource & { +export interface ManagedEnvironmentStorage extends ProxyResource { properties?: ManagedEnvironmentStorageProperties; -}; +} // @public export interface ManagedEnvironmentStorageProperties { @@ -1201,11 +1658,10 @@ export interface ManagedEnvironmentStoragesCollection { // @public export interface ManagedEnvironmentsUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } -// @public -export type ManagedEnvironmentsUpdateResponse = ManagedEnvironment; - // @public export interface ManagedServiceIdentity { readonly principalId?: string; @@ -1219,6 +1675,18 @@ export interface ManagedServiceIdentity { // @public export type ManagedServiceIdentityType = string; +// @public +export interface Namespaces { + checkNameAvailability(resourceGroupName: string, environmentName: string, checkNameAvailabilityRequest: CheckNameAvailabilityRequest, options?: NamespacesCheckNameAvailabilityOptionalParams): Promise; +} + +// @public +export interface NamespacesCheckNameAvailabilityOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type NamespacesCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; + // @public export interface Nonce { nonceExpirationInterval?: string; @@ -1289,7 +1757,8 @@ export interface OperationsListOptionalParams extends coreClient.OperationOption export type OperationsListResponse = AvailableOperations; // @public -export type ProxyResource = Resource & {}; +export interface ProxyResource extends Resource { +} // @public export interface QueueScaleRule { @@ -1300,6 +1769,7 @@ export interface QueueScaleRule { // @public export interface RegistryCredentials { + identity?: string; passwordSecretRef?: string; server?: string; username?: string; @@ -1313,10 +1783,10 @@ export interface RegistryInfo { } // @public -export type Replica = ProxyResource & { - readonly createdTime?: Date; +export interface Replica extends ProxyResource { containers?: ReplicaContainer[]; -}; + readonly createdTime?: Date; +} // @public export interface ReplicaCollection { @@ -1341,17 +1811,18 @@ export interface Resource { } // @public -export type Revision = ProxyResource & { +export interface Revision extends ProxyResource { + readonly active?: boolean; readonly createdTime?: Date; readonly fqdn?: string; - readonly template?: Template; - readonly active?: boolean; - readonly replicas?: number; - readonly trafficWeight?: number; - readonly provisioningError?: string; readonly healthState?: RevisionHealthState; + readonly provisioningError?: string; readonly provisioningState?: RevisionProvisioningState; -}; + readonly replicas?: number; + readonly template?: Template; + readonly trafficLabels?: TrafficLabel[]; + readonly trafficWeight?: number; +} // @public export interface RevisionCollection { @@ -1386,6 +1857,9 @@ export interface ScaleRuleAuth { triggerParameter?: string; } +// @public +export type Scheme = string; + // @public export interface Secret { name?: string; @@ -1398,12 +1872,12 @@ export interface SecretsCollection { } // @public -export type SourceControl = ProxyResource & { - readonly operationState?: SourceControlOperationState; - repoUrl?: string; +export interface SourceControl extends ProxyResource { branch?: string; githubActionConfiguration?: GithubActionConfiguration; -}; + readonly operationState?: SourceControlOperationState; + repoUrl?: string; +} // @public export interface SourceControlCollection { @@ -1436,15 +1910,22 @@ export interface Template { } // @public -export type TrackedResource = Resource & { +export interface TrackedResource extends Resource { + location: string; tags?: { [propertyName: string]: string; }; - location: string; -}; +} + +// @public +export interface TrafficLabel { + readonly fqdn?: string; + readonly label?: string; +} // @public export interface TrafficWeight { + label?: string; latestRevision?: boolean; revisionName?: string; weight?: number; diff --git a/sdk/app/arm-app/samples-dev/certificatesCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/certificatesCreateOrUpdateSample.ts deleted file mode 100644 index 487eec304763..000000000000 --- a/sdk/app/arm-app/samples-dev/certificatesCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - Certificate, - CertificatesCreateOrUpdateOptionalParams, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - password: "private key password", - value: new Uint8Array() - } - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - managedEnvironmentName, - name, - options - ); - console.log(result); -} - -createOrUpdateCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/certificatesDeleteSample.ts b/sdk/app/arm-app/samples-dev/certificatesDeleteSample.ts deleted file mode 100644 index c872144e3b1b..000000000000 --- a/sdk/app/arm-app/samples-dev/certificatesDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete( - resourceGroupName, - managedEnvironmentName, - name - ); - console.log(result); -} - -deleteCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/certificatesGetSample.ts b/sdk/app/arm-app/samples-dev/certificatesGetSample.ts deleted file mode 100644 index fb53e9432dcd..000000000000 --- a/sdk/app/arm-app/samples-dev/certificatesGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_Get.json - */ -async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get( - resourceGroupName, - managedEnvironmentName, - name - ); - console.log(result); -} - -getCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/certificatesListSample.ts b/sdk/app/arm-app/samples-dev/certificatesListSample.ts deleted file mode 100644 index 73c627622c1a..000000000000 --- a/sdk/app/arm-app/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.list( - resourceGroupName, - managedEnvironmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/certificatesUpdateSample.ts b/sdk/app/arm-app/samples-dev/certificatesUpdateSample.ts deleted file mode 100644 index 95c86c42fe06..000000000000 --- a/sdk/app/arm-app/samples-dev/certificatesUpdateSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { CertificatePatch, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "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, - managedEnvironmentName, - name, - certificateEnvelope - ); - console.log(result); -} - -patchCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.ts deleted file mode 100644 index 81f7090e87bf..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { AuthConfig, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update the AuthConfig for a Container App. - * - * @summary Description for Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const authConfigEnvelope: AuthConfig = { - 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, - name, - authConfigEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsDeleteSample.ts b/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsDeleteSample.ts deleted file mode 100644 index 0554af0821fa..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App AuthConfig. - * - * @summary Description for Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsGetSample.ts b/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsGetSample.ts deleted file mode 100644 index 853a1febc1dd..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts b/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts deleted file mode 100644 index e3f89107286b..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsAuthConfigsListByContainerAppSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAuthConfigsByContainerApps().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/containerAppsCreateOrUpdateSample.ts deleted file mode 100644 index cb2523bdfb55..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerApp, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a Container App. - * - * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { appPort: 3000, appProtocol: "http", enabled: true }, - 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, - targetPort: 3000 - } - }, - location: "East US", - managedEnvironmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - 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 - } - ] - } - ], - scale: { - maxReplicas: 5, - minReplicas: 1, - 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, - name, - containerAppEnvelope - ); - console.log(result); -} - -createOrUpdateContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsDeleteSample.ts b/sdk/app/arm-app/samples-dev/containerAppsDeleteSample.ts deleted file mode 100644 index c6b7ad11da66..000000000000 --- a/sdk/app/arm-app/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App. - * - * @summary Description for Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsGetSample.ts b/sdk/app/arm-app/samples-dev/containerAppsGetSample.ts deleted file mode 100644 index c3ed9ba32bdf..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the properties of a Container App. - * - * @summary Get the properties of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, name); - console.log(result); -} - -getContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsListByResourceGroupSample.ts b/sdk/app/arm-app/samples-dev/containerAppsListByResourceGroupSample.ts deleted file mode 100644 index ef6d4c259ce4..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Container Apps in a given resource group. - * - * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsListBySubscriptionSample.ts b/sdk/app/arm-app/samples-dev/containerAppsListBySubscriptionSample.ts deleted file mode 100644 index 9204c4d3330c..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsListBySubscriptionSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription() { - const subscriptionId = "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); -} - -listContainerAppsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts b/sdk/app/arm-app/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts deleted file mode 100644 index 549bd4a27bf5..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsListCustomHostNameAnalysisSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ContainerAppsListCustomHostNameAnalysisOptionalParams, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -analyzeCustomHostname().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsListSecretsSample.ts b/sdk/app/arm-app/samples-dev/containerAppsListSecretsSample.ts deleted file mode 100644 index 966f520a5e27..000000000000 --- a/sdk/app/arm-app/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List secrets for a container app - * - * @summary List secrets for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets( - resourceGroupName, - name - ); - console.log(result); -} - -listContainerAppsSecrets().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts deleted file mode 100644 index 30ef6ae6b233..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasGetReplicaSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const name = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - name - ); - console.log(result); -} - -getContainerAppRevisionReplica().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts deleted file mode 100644 index 844b7bdee308..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionReplicasListReplicasSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listContainerAppReplicas().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionsActivateRevisionSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionsActivateRevisionSample.ts deleted file mode 100644 index 38c6a5eb9828..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionsActivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Activates a revision for a Container App - * - * @summary Activates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -activateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts deleted file mode 100644 index d413520920df..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionsDeactivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Deactivates a revision for a Container App - * - * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deactivateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionsGetRevisionSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionsGetRevisionSample.ts deleted file mode 100644 index 2a97703a317e..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionsGetRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get a revision of a Container App. - * - * @summary Get a revision of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionsListRevisionsSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionsListRevisionsSample.ts deleted file mode 100644 index 13ca118da5b4..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionsListRevisionsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Revisions for a given Container App. - * - * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppRevisions().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsRevisionsRestartRevisionSample.ts b/sdk/app/arm-app/samples-dev/containerAppsRevisionsRestartRevisionSample.ts deleted file mode 100644 index aaec1158e232..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsRevisionsRestartRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Restarts a revision for a Container App - * - * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testStaticSite0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -restartContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.ts deleted file mode 100644 index fb65ad01eb7a..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { SourceControl, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update the SourceControl for a Container App. - * - * @summary Description for Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const sourceControlEnvelope: SourceControl = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - tenantId: "" - }, - registryInfo: { - registryPassword: "", - registryUrl: "xwang971reg.azurecr.io", - registryUserName: "xwang971reg" - } - }, - repoUrl: "https://github.com/xwang971/ghatest" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - name, - sourceControlEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsDeleteSample.ts b/sdk/app/arm-app/samples-dev/containerAppsSourceControlsDeleteSample.ts deleted file mode 100644 index 85ea0498d6a4..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App SourceControl. - * - * @summary Description for Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsGetSample.ts b/sdk/app/arm-app/samples-dev/containerAppsSourceControlsGetSample.ts deleted file mode 100644 index be593d5790a1..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts b/sdk/app/arm-app/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts deleted file mode 100644 index b4bb6d8b7e93..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsSourceControlsListByContainerAppSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAppSourceControls().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/containerAppsUpdateSample.ts b/sdk/app/arm-app/samples-dev/containerAppsUpdateSample.ts deleted file mode 100644 index 9343d0472dac..000000000000 --- a/sdk/app/arm-app/samples-dev/containerAppsUpdateSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppPatch, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Patches a Container App. Currently only patching of tags is supported - * - * @summary Patches a Container App. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope: ContainerAppPatch = { - tags: { tag1: "value1", tag2: "value2" } - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.update( - resourceGroupName, - name, - containerAppEnvelope - ); - console.log(result); -} - -patchContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/daprComponentsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/daprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index dd0318e85e58..000000000000 --- a/sdk/app/arm-app/samples-dev/daprComponentsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { DaprComponent, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "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" }], - version: "v1" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprComponentEnvelope - ); - console.log(result); -} - -createOrUpdateDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/daprComponentsDeleteSample.ts b/sdk/app/arm-app/samples-dev/daprComponentsDeleteSample.ts deleted file mode 100644 index d91260e74d5b..000000000000 --- a/sdk/app/arm-app/samples-dev/daprComponentsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete( - resourceGroupName, - environmentName, - name - ); - console.log(result); -} - -deleteDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/daprComponentsGetSample.ts b/sdk/app/arm-app/samples-dev/daprComponentsGetSample.ts deleted file mode 100644 index aaeb76f21d85..000000000000 --- a/sdk/app/arm-app/samples-dev/daprComponentsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Get.json - */ -async function getDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get( - resourceGroupName, - environmentName, - name - ); - console.log(result); -} - -getDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/daprComponentsListSample.ts b/sdk/app/arm-app/samples-dev/daprComponentsListSample.ts deleted file mode 100644 index 42c3487bd276..000000000000 --- a/sdk/app/arm-app/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listDaprComponents().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 8030b24e4581..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ManagedEnvironment, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" } - }, - location: "East US" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -createEnvironments().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsDeleteSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsDeleteSample.ts deleted file mode 100644 index 50c93edba9f4..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteEnvironmentByName().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsGetSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsGetSample.ts deleted file mode 100644 index db4f69523265..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getEnvironmentsByName().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsListByResourceGroupSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index cf452fab2bf6..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listEnvironmentsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsListBySubscriptionSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index ccfe7c862995..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsListBySubscriptionSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = "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); -} - -listEnvironmentsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 96a53c68f61f..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ManagedEnvironmentStorage, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "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, - envName, - name, - storageEnvelope - ); - console.log(result); -} - -createOrUpdateEnvironmentsStorage().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesDeleteSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index 71a66acd9251..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete( - resourceGroupName, - envName, - name - ); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesGetSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index 76bd4e1c4a4d..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - envName, - name - ); - console.log(result); -} - -getAEnvironmentsStoragePropertiesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesListSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsStoragesListSample.ts deleted file mode 100644 index dbf75cbe839b..000000000000 --- a/sdk/app/arm-app/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list( - resourceGroupName, - envName - ); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/managedEnvironmentsUpdateSample.ts b/sdk/app/arm-app/samples-dev/managedEnvironmentsUpdateSample.ts deleted file mode 100644 index d3693deee729..000000000000 --- a/sdk/app/arm-app/samples-dev/managedEnvironmentsUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ManagedEnvironmentPatch, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironmentPatch = { - tags: { tag1: "value1", tag2: "value2" } - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.update( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -patchManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples-dev/operationsListSample.ts b/sdk/app/arm-app/samples-dev/operationsListSample.ts deleted file mode 100644 index 62c55bbfb800..000000000000 --- a/sdk/app/arm-app/samples-dev/operationsListSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Operations_List.json - */ -async function listAllOperations() { - const subscriptionId = "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); -} - -listAllOperations().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/README.md b/sdk/app/arm-app/samples/v1-beta/javascript/README.md deleted file mode 100644 index 65ba4afc39dc..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/README.md +++ /dev/null @@ -1,134 +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** | -| ------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [certificatesCreateOrUpdateSample.js][certificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Certificate_CreateOrUpdate.json | -| [certificatesDeleteSample.js][certificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Certificate_Delete.json | -| [certificatesGetSample.js][certificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/Certificates_Patch.json | -| [containerAppsAuthConfigsCreateOrUpdateSample.js][containerappsauthconfigscreateorupdatesample] | Description for Create or update the AuthConfig for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_CreateOrUpdate.json | -| [containerAppsAuthConfigsDeleteSample.js][containerappsauthconfigsdeletesample] | Description for Delete a Container App AuthConfig. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/AuthConfigs_ListByContainer.json | -| [containerAppsCreateOrUpdateSample.js][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_CreateOrUpdate.json | -| [containerAppsDeleteSample.js][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Delete.json | -| [containerAppsGetSample.js][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/ContainerApps_ListSecrets.json | -| [containerAppsRevisionReplicasGetReplicaSample.js][containerappsrevisionreplicasgetreplicasample] | Get a replica for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/Revisions_Restart.json | -| [containerAppsSourceControlsCreateOrUpdateSample.js][containerappssourcecontrolscreateorupdatesample] | Description for Create or update the SourceControl for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_CreateOrUpdate.json | -| [containerAppsSourceControlsDeleteSample.js][containerappssourcecontrolsdeletesample] | Description for Delete a Container App SourceControl. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/SourceControls_ListByContainer.json | -| [containerAppsUpdateSample.js][containerappsupdatesample] | Patches a Container App. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Patch.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/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json | -| [daprComponentsDeleteSample.js][daprcomponentsdeletesample] | Delete a Dapr Component from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Delete.json | -| [daprComponentsGetSample.js][daprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json | -| [daprComponentsListSample.js][daprcomponentslistsample] | Get the Dapr Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_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/2022-01-01-preview/examples/ManagedEnvironments_CreateOrUpdate.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/2022-01-01-preview/examples/ManagedEnvironments_Delete.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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/ManagedEnvironments_ListBySubscription.json | -| [managedEnvironmentsStoragesCreateOrUpdateSample.js][managedenvironmentsstoragescreateorupdatesample] | Create or update storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json | -| [managedEnvironmentsStoragesDeleteSample.js][managedenvironmentsstoragesdeletesample] | Delete storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Delete.json | -| [managedEnvironmentsStoragesGetSample.js][managedenvironmentsstoragesgetsample] | Get storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_List.json | -| [managedEnvironmentsUpdateSample.js][managedenvironmentsupdatesample] | Patches a Managed Environment. Only patching of tags is supported currently x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironments_Patch.json | -| [operationsListSample.js][operationslistsample] | Lists all of the available RP operations. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Operations_List.json | - -## Prerequisites - -The sample programs are compatible with [LTS versions of Node.js](https://nodejs.org/about/releases/). - -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 certificatesCreateOrUpdateSample.js -``` - -Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): - -```bash -npx cross-env node certificatesCreateOrUpdateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/certificatesCreateOrUpdateSample.js -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/certificatesDeleteSample.js -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/certificatesGetSample.js -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/certificatesListSample.js -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/certificatesUpdateSample.js -[containerappsauthconfigscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js -[containerappsauthconfigsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsDeleteSample.js -[containerappsauthconfigsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsGetSample.js -[containerappsauthconfigslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsCreateOrUpdateSample.js -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsDeleteSample.js -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsGetSample.js -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListByResourceGroupSample.js -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListBySubscriptionSample.js -[containerappslistcustomhostnameanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListSecretsSample.js -[containerappsrevisionreplicasgetreplicasample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js -[containerappsrevisionreplicaslistreplicassample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsActivateRevisionSample.js -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsGetRevisionSample.js -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsListRevisionsSample.js -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsRestartRevisionSample.js -[containerappssourcecontrolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js -[containerappssourcecontrolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsDeleteSample.js -[containerappssourcecontrolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsGetSample.js -[containerappssourcecontrolslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js -[containerappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsUpdateSample.js -[daprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsCreateOrUpdateSample.js -[daprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsDeleteSample.js -[daprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsGetSample.js -[daprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsListSample.js -[managedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js -[managedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsDeleteSample.js -[managedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsGetSample.js -[managedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListByResourceGroupSample.js -[managedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListBySubscriptionSample.js -[managedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js -[managedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesDeleteSample.js -[managedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesGetSample.js -[managedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesListSample.js -[managedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsUpdateSample.js -[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/javascript/operationsListSample.js -[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-app?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/app/arm-app/README.md diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/certificatesCreateOrUpdateSample.js deleted file mode 100644 index ba0e4022d0de..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesCreateOrUpdateSample.js +++ /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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const certificateEnvelope = { - location: "East US", - properties: { - password: "private key password", - value: new Uint8Array(), - }, - }; - const options = { - certificateEnvelope, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - managedEnvironmentName, - name, - options - ); - console.log(result); -} - -createOrUpdateCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/certificatesDeleteSample.js deleted file mode 100644 index 0fbaecd4d33e..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesDeleteSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete(resourceGroupName, managedEnvironmentName, name); - console.log(result); -} - -deleteCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/certificatesGetSample.js deleted file mode 100644 index d0e1bc5770a3..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesGetSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Certificate_Get.json - */ -async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get(resourceGroupName, managedEnvironmentName, name); - console.log(result); -} - -getCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesListSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/certificatesListSample.js deleted file mode 100644 index 21ae888dd338..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesListSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.list(resourceGroupName, managedEnvironmentName)) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/certificatesUpdateSample.js deleted file mode 100644 index f5876664122c..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/certificatesUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Certificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "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, - managedEnvironmentName, - name, - certificateEnvelope - ); - console.log(result); -} - -patchCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.js deleted file mode 100644 index d2b098640337..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsCreateOrUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Create or update the AuthConfig for a Container App. - * - * @summary Description for Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const authConfigEnvelope = { - 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, - name, - authConfigEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsDeleteSample.js deleted file mode 100644 index 6f67fc553f03..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsDeleteSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a Container App AuthConfig. - * - * @summary Description for Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsGetSample.js deleted file mode 100644 index 0d4d4a605942..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsGetSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.js deleted file mode 100644 index 5af5c58bdac5..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsAuthConfigsListByContainerAppSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAuthConfigsByContainerApps().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsCreateOrUpdateSample.js deleted file mode 100644 index 2486b6202c65..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsCreateOrUpdateSample.js +++ /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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Create or update a Container App. - * - * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope = { - configuration: { - dapr: { appPort: 3000, appProtocol: "http", enabled: true }, - 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, - targetPort: 3000, - }, - }, - location: "East US", - managedEnvironmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - 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, - }, - ], - }, - ], - scale: { - maxReplicas: 5, - minReplicas: 1, - 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, - name, - containerAppEnvelope - ); - console.log(result); -} - -createOrUpdateContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsDeleteSample.js deleted file mode 100644 index 438be2d524c9..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a Container App. - * - * @summary Description for Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsGetSample.js deleted file mode 100644 index 084ac03b22c0..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the properties of a Container App. - * - * @summary Get the properties of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, name); - console.log(result); -} - -getContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListByResourceGroupSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListByResourceGroupSample.js deleted file mode 100644 index 62a74f53f522..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the Container Apps in a given resource group. - * - * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListBySubscriptionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListBySubscriptionSample.js deleted file mode 100644 index e02beeba7648..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListBySubscriptionSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription() { - const subscriptionId = "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); -} - -listContainerAppsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListCustomHostNameAnalysisSample.js deleted file mode 100644 index 214d6f0a246d..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListCustomHostNameAnalysisSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -analyzeCustomHostname().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListSecretsSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListSecretsSample.js deleted file mode 100644 index 2393fe6a9341..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsListSecretsSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to List secrets for a container app - * - * @summary List secrets for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets(resourceGroupName, name); - console.log(result); -} - -listContainerAppsSecrets().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.js deleted file mode 100644 index f9a8af4adcc6..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasGetReplicaSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const name = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - name - ); - console.log(result); -} - -getContainerAppRevisionReplica().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasListReplicasSample.js deleted file mode 100644 index ff795656f3e6..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionReplicasListReplicasSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listContainerAppReplicas().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsActivateRevisionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsActivateRevisionSample.js deleted file mode 100644 index 00558e0519a3..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsActivateRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Activates a revision for a Container App - * - * @summary Activates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -activateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js deleted file mode 100644 index f0613ccf6307..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsDeactivateRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Deactivates a revision for a Container App - * - * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deactivateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsGetRevisionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsGetRevisionSample.js deleted file mode 100644 index eb13d7a823ad..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsGetRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get a revision of a Container App. - * - * @summary Get a revision of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsListRevisionsSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsListRevisionsSample.js deleted file mode 100644 index 677600bfd580..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsListRevisionsSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Get the Revisions for a given Container App. - * - * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppRevisions().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsRestartRevisionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsRestartRevisionSample.js deleted file mode 100644 index 32d200bdf205..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsRevisionsRestartRevisionSample.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Restarts a revision for a Container App - * - * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testStaticSite0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -restartContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.js deleted file mode 100644 index 24eb059852c8..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsCreateOrUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Create or update the SourceControl for a Container App. - * - * @summary Description for Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const sourceControlEnvelope = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - tenantId: "", - }, - registryInfo: { - registryPassword: "", - registryUrl: "xwang971reg.azurecr.io", - registryUserName: "xwang971reg", - }, - }, - repoUrl: "https://github.com/xwang971/ghatest", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - name, - sourceControlEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsDeleteSample.js deleted file mode 100644 index 36d8037d49a5..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsDeleteSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Description for Delete a Container App SourceControl. - * - * @summary Description for Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsGetSample.js deleted file mode 100644 index 52e7277017a1..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsGetSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsListByContainerAppSample.js deleted file mode 100644 index 12005c154314..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsSourceControlsListByContainerAppSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAppSourceControls().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsUpdateSample.js deleted file mode 100644 index 5fe32a3e1413..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/containerAppsUpdateSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * This sample demonstrates how to Patches a Container App. Currently only patching of tags is supported - * - * @summary Patches a Container App. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.update(resourceGroupName, name, containerAppEnvelope); - console.log(result); -} - -patchContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsCreateOrUpdateSample.js deleted file mode 100644 index 67e14853f537..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsCreateOrUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "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" }], - version: "v1", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprComponentEnvelope - ); - console.log(result); -} - -createOrUpdateDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsDeleteSample.js deleted file mode 100644 index b17b0327f7f4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsDeleteSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete(resourceGroupName, environmentName, name); - console.log(result); -} - -deleteDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsGetSample.js deleted file mode 100644 index bd96f6b5a42b..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsGetSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Get.json - */ -async function getDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get(resourceGroupName, environmentName, name); - console.log(result); -} - -getDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsListSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsListSample.js deleted file mode 100644 index 09461560ad3a..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/daprComponentsListSample.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listDaprComponents().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsCreateOrUpdateSample.js deleted file mode 100644 index ac88f16bac50..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsCreateOrUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" }, - }, - location: "East US", - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -createEnvironments().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsDeleteSample.js deleted file mode 100644 index 7b14b36e8094..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsDeleteSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait(resourceGroupName, name); - console.log(result); -} - -deleteEnvironmentByName().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsGetSample.js deleted file mode 100644 index 64c77ef2cc01..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsGetSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getEnvironmentsByName().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListByResourceGroupSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListByResourceGroupSample.js deleted file mode 100644 index c7801458ec72..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListByResourceGroupSample.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listEnvironmentsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListBySubscriptionSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListBySubscriptionSample.js deleted file mode 100644 index b13f81c237b0..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsListBySubscriptionSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = "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); -} - -listEnvironmentsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js deleted file mode 100644 index 4fcc05aa216f..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesCreateOrUpdateSample.js +++ /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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "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, - envName, - name, - storageEnvelope - ); - console.log(result); -} - -createOrUpdateEnvironmentsStorage().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesDeleteSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesDeleteSample.js deleted file mode 100644 index 74d62824fdb0..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesDeleteSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete(resourceGroupName, envName, name); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesGetSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesGetSample.js deleted file mode 100644 index 6b2156c3f1b4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesGetSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get(resourceGroupName, envName, name); - console.log(result); -} - -getAEnvironmentsStoragePropertiesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesListSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesListSample.js deleted file mode 100644 index cf95baf60092..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsStoragesListSample.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list(resourceGroupName, envName); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsUpdateSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsUpdateSample.js deleted file mode 100644 index 3515e8cb0f5a..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/managedEnvironmentsUpdateSample.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-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope = { - tags: { tag1: "value1", tag2: "value2" }, - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.update( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -patchManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/operationsListSample.js b/sdk/app/arm-app/samples/v1-beta/javascript/operationsListSample.js deleted file mode 100644 index 191858d4b9ec..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/operationsListSample.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -const { ContainerAppsAPIClient } = require("@azure/arm-app"); -const { DefaultAzureCredential } = require("@azure/identity"); - -/** - * 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/2022-01-01-preview/examples/Operations_List.json - */ -async function listAllOperations() { - const subscriptionId = "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); -} - -listAllOperations().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/package.json b/sdk/app/arm-app/samples/v1-beta/javascript/package.json deleted file mode 100644 index d34d2209144e..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/javascript/package.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "name": "@azure-samples/arm-app-js-beta", - "private": true, - "version": "1.0.0", - "description": " client library samples for JavaScript (Beta)", - "engines": { - "node": ">=12.0.0" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/Azure/azure-sdk-for-js.git", - "directory": "sdk/app/arm-app" - }, - "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/app/arm-app", - "dependencies": { - "@azure/arm-app": "next", - "dotenv": "latest", - "@azure/identity": "^2.0.1" - } -} diff --git a/sdk/app/arm-app/samples/v1-beta/javascript/sample.env b/sdk/app/arm-app/samples/v1-beta/javascript/sample.env deleted file mode 100644 index 672847a3fea0..000000000000 --- a/sdk/app/arm-app/samples/v1-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/app/arm-app/samples/v1-beta/typescript/README.md b/sdk/app/arm-app/samples/v1-beta/typescript/README.md deleted file mode 100644 index 200612321d38..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/README.md +++ /dev/null @@ -1,147 +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** | -| ------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [certificatesCreateOrUpdateSample.ts][certificatescreateorupdatesample] | Create or Update a Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Certificate_CreateOrUpdate.json | -| [certificatesDeleteSample.ts][certificatesdeletesample] | Deletes the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Certificate_Delete.json | -| [certificatesGetSample.ts][certificatesgetsample] | Get the specified Certificate. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/Certificates_Patch.json | -| [containerAppsAuthConfigsCreateOrUpdateSample.ts][containerappsauthconfigscreateorupdatesample] | Description for Create or update the AuthConfig for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_CreateOrUpdate.json | -| [containerAppsAuthConfigsDeleteSample.ts][containerappsauthconfigsdeletesample] | Description for Delete a Container App AuthConfig. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/AuthConfigs_ListByContainer.json | -| [containerAppsCreateOrUpdateSample.ts][containerappscreateorupdatesample] | Description for Create or update a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_CreateOrUpdate.json | -| [containerAppsDeleteSample.ts][containerappsdeletesample] | Description for Delete a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Delete.json | -| [containerAppsGetSample.ts][containerappsgetsample] | Get the properties of a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/ContainerApps_ListSecrets.json | -| [containerAppsRevisionReplicasGetReplicaSample.ts][containerappsrevisionreplicasgetreplicasample] | Get a replica for a Container App Revision. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/Revisions_Restart.json | -| [containerAppsSourceControlsCreateOrUpdateSample.ts][containerappssourcecontrolscreateorupdatesample] | Description for Create or update the SourceControl for a Container App. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_CreateOrUpdate.json | -| [containerAppsSourceControlsDeleteSample.ts][containerappssourcecontrolsdeletesample] | Description for Delete a Container App SourceControl. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/SourceControls_ListByContainer.json | -| [containerAppsUpdateSample.ts][containerappsupdatesample] | Patches a Container App. Currently only patching of tags is supported x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Patch.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/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json | -| [daprComponentsDeleteSample.ts][daprcomponentsdeletesample] | Delete a Dapr Component from a Managed Environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Delete.json | -| [daprComponentsGetSample.ts][daprcomponentsgetsample] | Get a dapr component. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json | -| [daprComponentsListSample.ts][daprcomponentslistsample] | Get the Dapr Components for a managed environment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_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/2022-01-01-preview/examples/ManagedEnvironments_CreateOrUpdate.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/2022-01-01-preview/examples/ManagedEnvironments_Delete.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/2022-01-01-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/2022-01-01-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/2022-01-01-preview/examples/ManagedEnvironments_ListBySubscription.json | -| [managedEnvironmentsStoragesCreateOrUpdateSample.ts][managedenvironmentsstoragescreateorupdatesample] | Create or update storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json | -| [managedEnvironmentsStoragesDeleteSample.ts][managedenvironmentsstoragesdeletesample] | Delete storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Delete.json | -| [managedEnvironmentsStoragesGetSample.ts][managedenvironmentsstoragesgetsample] | Get storage for a managedEnvironment. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_List.json | -| [managedEnvironmentsUpdateSample.ts][managedenvironmentsupdatesample] | Patches a Managed Environment. Only patching of tags is supported currently x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ManagedEnvironments_Patch.json | -| [operationsListSample.ts][operationslistsample] | Lists all of the available RP operations. x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Operations_List.json | - -## Prerequisites - -The sample programs are compatible with [LTS versions of Node.js](https://nodejs.org/about/releases/). - -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/certificatesCreateOrUpdateSample.js -``` - -Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform): - -```bash -npx cross-env node dist/certificatesCreateOrUpdateSample.js -``` - -## Next Steps - -Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients. - -[certificatescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesCreateOrUpdateSample.ts -[certificatesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesDeleteSample.ts -[certificatesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesGetSample.ts -[certificateslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesListSample.ts -[certificatesupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesUpdateSample.ts -[containerappsauthconfigscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts -[containerappsauthconfigsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts -[containerappsauthconfigsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsGetSample.ts -[containerappsauthconfigslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts -[containerappscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsCreateOrUpdateSample.ts -[containerappsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsDeleteSample.ts -[containerappsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsGetSample.ts -[containerappslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListByResourceGroupSample.ts -[containerappslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListBySubscriptionSample.ts -[containerappslistcustomhostnameanalysissample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts -[containerappslistsecretssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListSecretsSample.ts -[containerappsrevisionreplicasgetreplicasample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts -[containerappsrevisionreplicaslistreplicassample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts -[containerappsrevisionsactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts -[containerappsrevisionsdeactivaterevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts -[containerappsrevisionsgetrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts -[containerappsrevisionslistrevisionssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts -[containerappsrevisionsrestartrevisionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts -[containerappssourcecontrolscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts -[containerappssourcecontrolsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts -[containerappssourcecontrolsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsGetSample.ts -[containerappssourcecontrolslistbycontainerappsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts -[containerappsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsUpdateSample.ts -[daprcomponentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts -[daprcomponentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsDeleteSample.ts -[daprcomponentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsGetSample.ts -[daprcomponentslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsListSample.ts -[managedenvironmentscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts -[managedenvironmentsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsDeleteSample.ts -[managedenvironmentsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsGetSample.ts -[managedenvironmentslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts -[managedenvironmentslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts -[managedenvironmentsstoragescreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts -[managedenvironmentsstoragesdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts -[managedenvironmentsstoragesgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts -[managedenvironmentsstorageslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesListSample.ts -[managedenvironmentsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsUpdateSample.ts -[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/app/arm-app/samples/v1-beta/typescript/src/operationsListSample.ts -[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-app?view=azure-node-preview -[freesub]: https://azure.microsoft.com/free/ -[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/app/arm-app/README.md -[typescript]: https://www.typescriptlang.org/docs/home.html diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/package.json b/sdk/app/arm-app/samples/v1-beta/typescript/package.json deleted file mode 100644 index c144f4072c7d..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@azure-samples/arm-app-ts-beta", - "private": true, - "version": "1.0.0", - "description": " client library samples for TypeScript (Beta)", - "engines": { - "node": ">=12.0.0" - }, - "scripts": { - "build": "tsc", - "prebuild": "rimraf dist/" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/Azure/azure-sdk-for-js.git", - "directory": "sdk/app/arm-app" - }, - "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/app/arm-app", - "dependencies": { - "@azure/arm-app": "next", - "dotenv": "latest", - "@azure/identity": "^2.0.1" - }, - "devDependencies": { - "@types/node": "^12.0.0", - "typescript": "~4.4.0", - "rimraf": "latest" - } -} diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/sample.env b/sdk/app/arm-app/samples/v1-beta/typescript/sample.env deleted file mode 100644 index 672847a3fea0..000000000000 --- a/sdk/app/arm-app/samples/v1-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/app/arm-app/samples/v1-beta/typescript/src/certificatesCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesCreateOrUpdateSample.ts deleted file mode 100644 index 487eec304763..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - Certificate, - CertificatesCreateOrUpdateOptionalParams, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_CreateOrUpdate.json - */ -async function createOrUpdateCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const certificateEnvelope: Certificate = { - location: "East US", - properties: { - password: "private key password", - value: new Uint8Array() - } - }; - const options: CertificatesCreateOrUpdateOptionalParams = { - certificateEnvelope - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.createOrUpdate( - resourceGroupName, - managedEnvironmentName, - name, - options - ); - console.log(result); -} - -createOrUpdateCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesDeleteSample.ts deleted file mode 100644 index c872144e3b1b..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_Delete.json - */ -async function deleteCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.delete( - resourceGroupName, - managedEnvironmentName, - name - ); - console.log(result); -} - -deleteCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesGetSample.ts deleted file mode 100644 index fb53e9432dcd..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificate_Get.json - */ -async function getCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "certificate-firendly-name"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.certificates.get( - resourceGroupName, - managedEnvironmentName, - name - ); - console.log(result); -} - -getCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesListSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesListSample.ts deleted file mode 100644 index 73c627622c1a..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificates_ListByManagedEnvironment.json - */ -async function listCertificatesByManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const resArray = new Array(); - for await (let item of client.certificates.list( - resourceGroupName, - managedEnvironmentName - )) { - resArray.push(item); - } - console.log(resArray); -} - -listCertificatesByManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesUpdateSample.ts deleted file mode 100644 index 95c86c42fe06..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/certificatesUpdateSample.ts +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { CertificatePatch, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Certificates_Patch.json - */ -async function patchCertificate() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const managedEnvironmentName = "testcontainerenv"; - const name = "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, - managedEnvironmentName, - name, - certificateEnvelope - ); - console.log(result); -} - -patchCertificate().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.ts deleted file mode 100644 index 81f7090e87bf..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { AuthConfig, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update the AuthConfig for a Container App. - * - * @summary Description for Create or update the AuthConfig for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const authConfigEnvelope: AuthConfig = { - 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, - name, - authConfigEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts deleted file mode 100644 index 0554af0821fa..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App AuthConfig. - * - * @summary Description for Delete a Container App AuthConfig. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/AuthConfigs_Delete.json - */ -async function deleteContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.delete( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsGetSample.ts deleted file mode 100644 index 853a1febc1dd..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_Get.json - */ -async function getContainerAppAuthConfig() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsAuthConfigs.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppAuthConfig().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts deleted file mode 100644 index e3f89107286b..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsAuthConfigsListByContainerAppSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/AuthConfigs_ListByContainer.json - */ -async function listAuthConfigsByContainerApps() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAuthConfigsByContainerApps().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsCreateOrUpdateSample.ts deleted file mode 100644 index cb2523bdfb55..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerApp, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update a Container App. - * - * @summary Description for Create or update a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_CreateOrUpdate.json - */ -async function createOrUpdateContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope: ContainerApp = { - configuration: { - dapr: { appPort: 3000, appProtocol: "http", enabled: true }, - 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, - targetPort: 3000 - } - }, - location: "East US", - managedEnvironmentId: - "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/rg/providers/Microsoft.App/managedEnvironments/demokube", - 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 - } - ] - } - ], - scale: { - maxReplicas: 5, - minReplicas: 1, - 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, - name, - containerAppEnvelope - ); - console.log(result); -} - -createOrUpdateContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsDeleteSample.ts deleted file mode 100644 index c6b7ad11da66..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App. - * - * @summary Description for Delete a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Delete.json - */ -async function deleteContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testWorkerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsGetSample.ts deleted file mode 100644 index c3ed9ba32bdf..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the properties of a Container App. - * - * @summary Get the properties of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Get.json - */ -async function getContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.get(resourceGroupName, name); - console.log(result); -} - -getContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListByResourceGroupSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListByResourceGroupSample.ts deleted file mode 100644 index ef6d4c259ce4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Container Apps in a given resource group. - * - * @summary Get the Container Apps in a given resource group. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListByResourceGroup.json - */ -async function listContainerAppsByResourceGroup() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListBySubscriptionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListBySubscriptionSample.ts deleted file mode 100644 index 9204c4d3330c..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListBySubscriptionSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListBySubscription.json - */ -async function listContainerAppsBySubscription() { - const subscriptionId = "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); -} - -listContainerAppsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts deleted file mode 100644 index 549bd4a27bf5..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListCustomHostNameAnalysisSample.ts +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ContainerAppsListCustomHostNameAnalysisOptionalParams, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ContainerApps_ListCustomHostNameAnalysis.json - */ -async function analyzeCustomHostname() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -analyzeCustomHostname().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListSecretsSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsListSecretsSample.ts deleted file mode 100644 index 966f520a5e27..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to List secrets for a container app - * - * @summary List secrets for a container app - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_ListSecrets.json - */ -async function listContainerAppsSecrets() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.listSecrets( - resourceGroupName, - name - ); - console.log(result); -} - -listContainerAppsSecrets().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts deleted file mode 100644 index 30ef6ae6b233..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasGetReplicaSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Replicas_Get.json - */ -async function getContainerAppRevisionReplica() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "myapp"; - const revisionName = "myapp--0wlqy09"; - const name = "myapp--0wlqy09-5d9774cff-5wnd8"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisionReplicas.getReplica( - resourceGroupName, - containerAppName, - revisionName, - name - ); - console.log(result); -} - -getContainerAppRevisionReplica().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts deleted file mode 100644 index 844b7bdee308..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionReplicasListReplicasSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Replicas_List.json - */ -async function listContainerAppReplicas() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listContainerAppReplicas().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts deleted file mode 100644 index 38c6a5eb9828..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsActivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Activates a revision for a Container App - * - * @summary Activates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Activate.json - */ -async function activateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.activateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -activateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts deleted file mode 100644 index d413520920df..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsDeactivateRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Deactivates a revision for a Container App - * - * @summary Deactivates a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Deactivate.json - */ -async function deactivateContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.deactivateRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deactivateContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts deleted file mode 100644 index 2a97703a317e..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsGetRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get a revision of a Container App. - * - * @summary Get a revision of a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Get.json - */ -async function getContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testcontainerApp0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.getRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts deleted file mode 100644 index 13ca118da5b4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsListRevisionsSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Get the Revisions for a given Container App. - * - * @summary Get the Revisions for a given Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_List.json - */ -async function listContainerAppRevisions() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "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); -} - -listContainerAppRevisions().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts deleted file mode 100644 index aaec1158e232..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsRevisionsRestartRevisionSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Restarts a revision for a Container App - * - * @summary Restarts a revision for a Container App - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/Revisions_Restart.json - */ -async function restartContainerAppRevision() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const containerAppName = "testStaticSite0"; - const name = "testcontainerApp0-pjxhsye"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsRevisions.restartRevision( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -restartContainerAppRevision().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.ts deleted file mode 100644 index fb65ad01eb7a..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { SourceControl, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Create or update the SourceControl for a Container App. - * - * @summary Description for Create or update the SourceControl for a Container App. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_CreateOrUpdate.json - */ -async function createOrUpdateContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const sourceControlEnvelope: SourceControl = { - branch: "master", - githubActionConfiguration: { - azureCredentials: { - clientId: "", - clientSecret: "", - tenantId: "" - }, - registryInfo: { - registryPassword: "", - registryUrl: "xwang971reg.azurecr.io", - registryUserName: "xwang971reg" - } - }, - repoUrl: "https://github.com/xwang971/ghatest" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginCreateOrUpdateAndWait( - resourceGroupName, - containerAppName, - name, - sourceControlEnvelope - ); - console.log(result); -} - -createOrUpdateContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts deleted file mode 100644 index 85ea0498d6a4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Description for Delete a Container App SourceControl. - * - * @summary Description for Delete a Container App SourceControl. - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/SourceControls_Delete.json - */ -async function deleteContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.beginDeleteAndWait( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -deleteContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsGetSample.ts deleted file mode 100644 index be593d5790a1..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/SourceControls_Get.json - */ -async function getContainerAppSourceControl() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "workerapps-rg-xj"; - const containerAppName = "testcanadacentral"; - const name = "current"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerAppsSourceControls.get( - resourceGroupName, - containerAppName, - name - ); - console.log(result); -} - -getContainerAppSourceControl().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts deleted file mode 100644 index b4bb6d8b7e93..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsSourceControlsListByContainerAppSample.ts +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/SourceControls_ListByContainer.json - */ -async function listAppSourceControls() { - const subscriptionId = "651f8027-33e8-4ec4-97b4-f6e9f3dc8744"; - const resourceGroupName = "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); -} - -listAppSourceControls().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsUpdateSample.ts deleted file mode 100644 index 9343d0472dac..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/containerAppsUpdateSample.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppPatch, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * This sample demonstrates how to Patches a Container App. Currently only patching of tags is supported - * - * @summary Patches a Container App. Currently only patching of tags is supported - * x-ms-original-file: specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/ContainerApps_Patch.json - */ -async function patchContainerApp() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "rg"; - const name = "testcontainerApp0"; - const containerAppEnvelope: ContainerAppPatch = { - tags: { tag1: "value1", tag2: "value2" } - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.containerApps.update( - resourceGroupName, - name, - containerAppEnvelope - ); - console.log(result); -} - -patchContainerApp().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsCreateOrUpdateSample.ts deleted file mode 100644 index dd0318e85e58..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { DaprComponent, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json - */ -async function createOrUpdateDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "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" }], - version: "v1" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.createOrUpdate( - resourceGroupName, - environmentName, - name, - daprComponentEnvelope - ); - console.log(result); -} - -createOrUpdateDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsDeleteSample.ts deleted file mode 100644 index d91260e74d5b..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Delete.json - */ -async function deleteDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.delete( - resourceGroupName, - environmentName, - name - ); - console.log(result); -} - -deleteDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsGetSample.ts deleted file mode 100644 index aaeb76f21d85..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_Get.json - */ -async function getDaprComponent() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const environmentName = "myenvironment"; - const name = "reddog"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.daprComponents.get( - resourceGroupName, - environmentName, - name - ); - console.log(result); -} - -getDaprComponent().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsListSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/daprComponentsListSample.ts deleted file mode 100644 index 42c3487bd276..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/DaprComponents_List.json - */ -async function listDaprComponents() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listDaprComponents().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts deleted file mode 100644 index 8030b24e4581..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsCreateOrUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ManagedEnvironment, ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_CreateOrUpdate.json - */ -async function createEnvironments() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironment = { - appLogsConfiguration: { - logAnalyticsConfiguration: { customerId: "string", sharedKey: "string" } - }, - location: "East US" - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginCreateOrUpdateAndWait( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -createEnvironments().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsDeleteSample.ts deleted file mode 100644 index 50c93edba9f4..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsDeleteSample.ts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Delete.json - */ -async function deleteEnvironmentByName() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "examplekenv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.beginDeleteAndWait( - resourceGroupName, - name - ); - console.log(result); -} - -deleteEnvironmentByName().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsGetSample.ts deleted file mode 100644 index db4f69523265..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsGetSample.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Get.json - */ -async function getEnvironmentsByName() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.get(resourceGroupName, name); - console.log(result); -} - -getEnvironmentsByName().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts deleted file mode 100644 index cf452fab2bf6..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListByResourceGroupSample.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListByResourceGroup.json - */ -async function listEnvironmentsByResourceGroup() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "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); -} - -listEnvironmentsByResourceGroup().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.ts deleted file mode 100644 index ccfe7c862995..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsListBySubscriptionSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_ListBySubscription.json - */ -async function listEnvironmentsBySubscription() { - const subscriptionId = "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); -} - -listEnvironmentsBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.ts deleted file mode 100644 index 96a53c68f61f..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesCreateOrUpdateSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ManagedEnvironmentStorage, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_CreateOrUpdate.json - */ -async function createOrUpdateEnvironmentsStorage() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "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, - envName, - name, - storageEnvelope - ); - console.log(result); -} - -createOrUpdateEnvironmentsStorage().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts deleted file mode 100644 index 71a66acd9251..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesDeleteSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Delete.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.delete( - resourceGroupName, - envName, - name - ); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts deleted file mode 100644 index 76bd4e1c4a4d..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesGetSample.ts +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_Get.json - */ -async function getAEnvironmentsStoragePropertiesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const name = "jlaw-demo1"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.get( - resourceGroupName, - envName, - name - ); - console.log(result); -} - -getAEnvironmentsStoragePropertiesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesListSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsStoragesListSample.ts deleted file mode 100644 index dbf75cbe839b..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironmentsStorages_List.json - */ -async function listEnvironmentsStoragesBySubscription() { - const subscriptionId = "8efdecc5-919e-44eb-b179-915dca89ebf9"; - const resourceGroupName = "examplerg"; - const envName = "managedEnv"; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironmentsStorages.list( - resourceGroupName, - envName - ); - console.log(result); -} - -listEnvironmentsStoragesBySubscription().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsUpdateSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsUpdateSample.ts deleted file mode 100644 index d3693deee729..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/managedEnvironmentsUpdateSample.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { - ManagedEnvironmentPatch, - ContainerAppsAPIClient -} from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/ManagedEnvironments_Patch.json - */ -async function patchManagedEnvironment() { - const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345"; - const resourceGroupName = "examplerg"; - const name = "testcontainerenv"; - const environmentEnvelope: ManagedEnvironmentPatch = { - tags: { tag1: "value1", tag2: "value2" } - }; - const credential = new DefaultAzureCredential(); - const client = new ContainerAppsAPIClient(credential, subscriptionId); - const result = await client.managedEnvironments.update( - resourceGroupName, - name, - environmentEnvelope - ); - console.log(result); -} - -patchManagedEnvironment().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/src/operationsListSample.ts b/sdk/app/arm-app/samples/v1-beta/typescript/src/operationsListSample.ts deleted file mode 100644 index 62c55bbfb800..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/src/operationsListSample.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. - */ - -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { ContainerAppsAPIClient } from "@azure/arm-app"; -import { DefaultAzureCredential } from "@azure/identity"; - -/** - * 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/2022-01-01-preview/examples/Operations_List.json - */ -async function listAllOperations() { - const subscriptionId = "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); -} - -listAllOperations().catch(console.error); diff --git a/sdk/app/arm-app/samples/v1-beta/typescript/tsconfig.json b/sdk/app/arm-app/samples/v1-beta/typescript/tsconfig.json deleted file mode 100644 index 416c2dd82e00..000000000000 --- a/sdk/app/arm-app/samples/v1-beta/typescript/tsconfig.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "compilerOptions": { - "target": "ES2018", - "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/app/arm-app/src/containerAppsAPIClient.ts b/sdk/app/arm-app/src/containerAppsAPIClient.ts index c40368293462..f937ee9e22ca 100644 --- a/sdk/app/arm-app/src/containerAppsAPIClient.ts +++ b/sdk/app/arm-app/src/containerAppsAPIClient.ts @@ -7,30 +7,52 @@ */ import * as coreClient from "@azure/core-client"; +import * as coreRestPipeline from "@azure/core-rest-pipeline"; +import { + PipelineRequest, + PipelineResponse, + SendRequest +} from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { + ContainerAppsAuthConfigsImpl, ContainerAppsImpl, ContainerAppsRevisionsImpl, ContainerAppsRevisionReplicasImpl, + DaprComponentsImpl, + ContainerAppsDiagnosticsImpl, + ManagedEnvironmentDiagnosticsImpl, + ManagedEnvironmentsDiagnosticsImpl, + OperationsImpl, ManagedEnvironmentsImpl, CertificatesImpl, - OperationsImpl, + NamespacesImpl, + ManagedEnvironmentsStoragesImpl, ContainerAppsSourceControlsImpl, - DaprComponentsImpl, - ContainerAppsAuthConfigsImpl, - ManagedEnvironmentsStoragesImpl + ConnectedEnvironmentsImpl, + ConnectedEnvironmentsCertificatesImpl, + ConnectedEnvironmentsDaprComponentsImpl, + ConnectedEnvironmentsStoragesImpl } from "./operations"; import { + ContainerAppsAuthConfigs, ContainerApps, ContainerAppsRevisions, ContainerAppsRevisionReplicas, + DaprComponents, + ContainerAppsDiagnostics, + ManagedEnvironmentDiagnostics, + ManagedEnvironmentsDiagnostics, + Operations, ManagedEnvironments, Certificates, - Operations, + Namespaces, + ManagedEnvironmentsStorages, ContainerAppsSourceControls, - DaprComponents, - ContainerAppsAuthConfigs, - ManagedEnvironmentsStorages + ConnectedEnvironments, + ConnectedEnvironmentsCertificates, + ConnectedEnvironmentsDaprComponents, + ConnectedEnvironmentsStorages } from "./operationsInterfaces"; import { ContainerAppsAPIClientOptionalParams } from "./models"; @@ -85,38 +107,116 @@ export class ContainerAppsAPIClient extends coreClient.ServiceClient { options.endpoint ?? options.baseUri ?? "https://management.azure.com" }; super(optionsWithDefaults); + + if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( + (pipelinePolicy) => + pipelinePolicy.name === + coreRestPipeline.bearerTokenAuthenticationPolicyName + ); + if (!bearerTokenAuthenticationPolicyFound) { + this.pipeline.removePolicy({ + name: coreRestPipeline.bearerTokenAuthenticationPolicyName + }); + this.pipeline.addPolicy( + coreRestPipeline.bearerTokenAuthenticationPolicy({ + scopes: `${optionsWithDefaults.baseUri}/.default`, + challengeCallbacks: { + authorizeRequestOnChallenge: + coreClient.authorizeRequestOnClaimChallenge + } + }) + ); + } + } // Parameter assignments this.subscriptionId = subscriptionId; // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2022-01-01-preview"; + this.apiVersion = options.apiVersion || "2022-06-01-preview"; + this.containerAppsAuthConfigs = new ContainerAppsAuthConfigsImpl(this); this.containerApps = new ContainerAppsImpl(this); this.containerAppsRevisions = new ContainerAppsRevisionsImpl(this); this.containerAppsRevisionReplicas = new ContainerAppsRevisionReplicasImpl( this ); + this.daprComponents = new DaprComponentsImpl(this); + this.containerAppsDiagnostics = new ContainerAppsDiagnosticsImpl(this); + this.managedEnvironmentDiagnostics = new ManagedEnvironmentDiagnosticsImpl( + this + ); + this.managedEnvironmentsDiagnostics = new ManagedEnvironmentsDiagnosticsImpl( + this + ); + this.operations = new OperationsImpl(this); this.managedEnvironments = new ManagedEnvironmentsImpl(this); this.certificates = new CertificatesImpl(this); - this.operations = new OperationsImpl(this); + this.namespaces = new NamespacesImpl(this); + this.managedEnvironmentsStorages = new ManagedEnvironmentsStoragesImpl( + this + ); this.containerAppsSourceControls = new ContainerAppsSourceControlsImpl( this ); - this.daprComponents = new DaprComponentsImpl(this); - this.containerAppsAuthConfigs = new ContainerAppsAuthConfigsImpl(this); - this.managedEnvironmentsStorages = new ManagedEnvironmentsStoragesImpl( + this.connectedEnvironments = new ConnectedEnvironmentsImpl(this); + this.connectedEnvironmentsCertificates = new ConnectedEnvironmentsCertificatesImpl( this ); + this.connectedEnvironmentsDaprComponents = new ConnectedEnvironmentsDaprComponentsImpl( + this + ); + this.connectedEnvironmentsStorages = new ConnectedEnvironmentsStoragesImpl( + this + ); + this.addCustomApiVersionPolicy(options.apiVersion); + } + + /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */ + private addCustomApiVersionPolicy(apiVersion?: string) { + if (!apiVersion) { + return; + } + const apiVersionPolicy = { + name: "CustomApiVersionPolicy", + async sendRequest( + request: PipelineRequest, + next: SendRequest + ): Promise { + const param = request.url.split("?"); + if (param.length > 1) { + const newParams = param[1].split("&").map((item) => { + if (item.indexOf("api-version") > -1) { + return "api-version=" + apiVersion; + } else { + return item; + } + }); + request.url = param[0] + "?" + newParams.join("&"); + } + return next(request); + } + }; + this.pipeline.addPolicy(apiVersionPolicy); } + containerAppsAuthConfigs: ContainerAppsAuthConfigs; containerApps: ContainerApps; containerAppsRevisions: ContainerAppsRevisions; containerAppsRevisionReplicas: ContainerAppsRevisionReplicas; + daprComponents: DaprComponents; + containerAppsDiagnostics: ContainerAppsDiagnostics; + managedEnvironmentDiagnostics: ManagedEnvironmentDiagnostics; + managedEnvironmentsDiagnostics: ManagedEnvironmentsDiagnostics; + operations: Operations; managedEnvironments: ManagedEnvironments; certificates: Certificates; - operations: Operations; - containerAppsSourceControls: ContainerAppsSourceControls; - daprComponents: DaprComponents; - containerAppsAuthConfigs: ContainerAppsAuthConfigs; + namespaces: Namespaces; managedEnvironmentsStorages: ManagedEnvironmentsStorages; + containerAppsSourceControls: ContainerAppsSourceControls; + connectedEnvironments: ConnectedEnvironments; + connectedEnvironmentsCertificates: ConnectedEnvironmentsCertificates; + connectedEnvironmentsDaprComponents: ConnectedEnvironmentsDaprComponents; + connectedEnvironmentsStorages: ConnectedEnvironmentsStorages; } diff --git a/sdk/app/arm-app/src/models/index.ts b/sdk/app/arm-app/src/models/index.ts index 35ac2407869e..ef520d38ce13 100644 --- a/sdk/app/arm-app/src/models/index.ts +++ b/sdk/app/arm-app/src/models/index.ts @@ -8,10 +8,10 @@ import * as coreClient from "@azure/core-client"; -/** Container App collection ARM resource. */ -export interface ContainerAppCollection { +/** AuthConfig collection ARM resource. */ +export interface AuthConfigCollection { /** Collection of resources. */ - value: ContainerApp[]; + value: AuthConfig[]; /** * Link to next page of resources. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -19,323 +19,394 @@ export interface ContainerAppCollection { readonly nextLink?: string; } -/** 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 configuration settings of the platform of ContainerApp Service Authentication/Authorization. */ +export interface AuthPlatform { + /** true if the Authentication / Authorization feature is enabled for the current app; otherwise, false. */ + enabled?: boolean; /** - * 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. + * The RuntimeVersion of the Authentication / Authorization feature in use for the current app. + * The setting in this value can control the behavior of certain features in the Authentication / Authorization module. */ - 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 }; + runtimeVersion?: string; } -/** User assigned identity properties */ -export interface UserAssignedIdentity { +/** The configuration settings that determines the validation flow of users using ContainerApp Service Authentication/Authorization. */ +export interface GlobalValidation { + /** The action to take when an unauthenticated client attempts to access the app. */ + unauthenticatedClientAction?: UnauthenticatedClientActionV2; /** - * The principal ID of the assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. + * The default authentication provider to use when multiple providers are configured. + * This setting is only needed if multiple providers are configured and the unauthenticated client + * action is set to "RedirectToLoginPage". */ - readonly principalId?: string; + redirectToProvider?: string; + /** The paths for which unauthenticated flow would not be redirected to the login page. */ + excludedPaths?: string[]; +} + +/** The configuration settings of each of the identity providers used to configure ContainerApp Service Authentication/Authorization. */ +export interface IdentityProviders { + /** The configuration settings of the Azure Active directory provider. */ + azureActiveDirectory?: AzureActiveDirectory; + /** The configuration settings of the Facebook provider. */ + facebook?: Facebook; + /** The configuration settings of the GitHub provider. */ + gitHub?: GitHub; + /** The configuration settings of the Google provider. */ + google?: Google; + /** The configuration settings of the Twitter provider. */ + twitter?: Twitter; + /** The configuration settings of the Apple provider. */ + apple?: Apple; + /** The configuration settings of the Azure Static Web Apps provider. */ + azureStaticWebApps?: AzureStaticWebApps; /** - * The client ID of the assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. + * The map of the name of the alias of each custom Open ID Connect provider to the + * configuration settings of the custom Open ID Connect provider. */ - readonly clientId?: string; + customOpenIdConnectProviders?: { + [propertyName: string]: CustomOpenIdConnectProvider; + }; } -/** Non versioned Container App configuration properties that define the mutable settings of a Container app */ -export interface Configuration { - /** Collection of secrets used by a Container app */ - secrets?: Secret[]; +/** The configuration settings of the Azure Active directory provider. */ +export interface AzureActiveDirectory { + /** false if the Azure Active Directory provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the Azure Active Directory app registration. */ + registration?: AzureActiveDirectoryRegistration; + /** The configuration settings of the Azure Active Directory login flow. */ + login?: AzureActiveDirectoryLogin; + /** The configuration settings of the Azure Active Directory token validation flow. */ + validation?: AzureActiveDirectoryValidation; /** - * ActiveRevisionsMode controls how active revisions are handled for the Container app: - * Multiple: multiple revisions can be active. If no value if provided, this is the defaultSingle: Only one revision can be active at a time. Revision weights can not be used in this mode + * Gets a value indicating whether the Azure AD configuration was auto-provisioned using 1st party tooling. + * This is an internal flag primarily intended to support the Azure Management Portal. Users should not + * read or write to this property. */ - activeRevisionsMode?: ActiveRevisionsMode; - /** Ingress configurations. */ - ingress?: Ingress; - /** Collection of private container registry credentials for containers used by the Container app */ - registries?: RegistryCredentials[]; - /** Dapr configuration for the Container App. */ - dapr?: Dapr; + isAutoProvisioned?: boolean; } -/** Secret definition. */ -export interface Secret { - /** Secret Name. */ - name?: string; - /** Secret Value. */ - value?: string; +/** The configuration settings of the Azure Active Directory app registration. */ +export interface AzureActiveDirectoryRegistration { + /** + * The OpenID Connect Issuer URI that represents the entity which issues access tokens for this application. + * When using Azure Active Directory, this value is the URI of the directory tenant, e.g. https://login.microsoftonline.com/v2.0/{tenant-guid}/. + * This URI is a case-sensitive identifier for the token issuer. + * More information on OpenID Connect Discovery: http://openid.net/specs/openid-connect-discovery-1_0.html + */ + openIdIssuer?: string; + /** + * The Client ID of this relying party application, known as the client_id. + * This setting is required for enabling OpenID Connection authentication with Azure Active Directory or + * other 3rd party OpenID Connect providers. + * More information on OpenID Connect: http://openid.net/specs/openid-connect-core-1_0.html + */ + clientId?: string; + /** The app setting name that contains the client secret of the relying party application. */ + clientSecretSettingName?: string; + /** + * An alternative to the client secret, that is the thumbprint of a certificate used for signing purposes. This property acts as + * a replacement for the Client Secret. It is also optional. + */ + clientSecretCertificateThumbprint?: string; + /** + * An alternative to the client secret thumbprint, that is the subject alternative name of a certificate used for signing purposes. This property acts as + * a replacement for the Client Secret Certificate Thumbprint. It is also optional. + */ + clientSecretCertificateSubjectAlternativeName?: string; + /** + * An alternative to the client secret thumbprint, that is the issuer of a certificate used for signing purposes. This property acts as + * a replacement for the Client Secret Certificate Thumbprint. It is also optional. + */ + clientSecretCertificateIssuer?: string; } -/** Container App Ingress configuration. */ -export interface Ingress { +/** The configuration settings of the Azure Active Directory login flow. */ +export interface AzureActiveDirectoryLogin { /** - * Hostname. - * NOTE: This property will not be serialized. It can only be populated by the server. + * Login parameters to send to the OpenID Connect authorization endpoint when + * a user logs in. Each parameter must be in the form "key=value". */ - readonly fqdn?: string; - /** Bool indicating if app exposes an external http endpoint */ - external?: boolean; - /** Target Port in containers for traffic from ingress */ - targetPort?: number; - /** Ingress transport protocol */ - transport?: IngressTransportMethod; - /** Traffic weights for app's revisions */ - traffic?: TrafficWeight[]; - /** custom domain bindings for Container Apps' hostnames. */ - customDomains?: CustomDomain[]; - /** Bool indicating if HTTP connections to is allowed. If set to false HTTP connections are automatically redirected to HTTPS connections */ - allowInsecure?: boolean; + loginParameters?: string[]; + /** true if the www-authenticate provider should be omitted from the request; otherwise, false. */ + disableWWWAuthenticate?: boolean; } -/** Traffic weight assigned to a revision */ -export interface TrafficWeight { - /** Name of a revision */ - revisionName?: string; - /** Traffic weight assigned to a revision */ - weight?: number; - /** Indicates that the traffic weight belongs to a latest stable revision */ - latestRevision?: boolean; +/** The configuration settings of the Azure Active Directory token validation flow. */ +export interface AzureActiveDirectoryValidation { + /** The configuration settings of the checks that should be made while validating the JWT Claims. */ + jwtClaimChecks?: JwtClaimChecks; + /** The list of audiences that can make successful authentication/authorization requests. */ + allowedAudiences?: string[]; + /** The configuration settings of the default authorization policy. */ + defaultAuthorizationPolicy?: DefaultAuthorizationPolicy; } -/** Custom Domain of a Container App */ -export interface CustomDomain { - /** Hostname. */ - name: string; - /** Custom Domain binding type. */ - bindingType?: BindingType; - /** Resource Id of the Certificate to be bound to this hostname. Must exist in the Managed Environment. */ - certificateId: string; +/** The configuration settings of the checks that should be made while validating the JWT Claims. */ +export interface JwtClaimChecks { + /** The list of the allowed groups. */ + allowedGroups?: string[]; + /** The list of the allowed client applications. */ + allowedClientApplications?: string[]; } -/** Container App Private Registry */ -export interface RegistryCredentials { - /** Container Registry Server */ - server?: string; - /** Container Registry Username */ - username?: string; - /** The name of the Secret that contains the registry login password */ - passwordSecretRef?: string; +/** The configuration settings of the Azure Active Directory default authorization policy. */ +export interface DefaultAuthorizationPolicy { + /** The configuration settings of the Azure Active Directory allowed principals. */ + allowedPrincipals?: AllowedPrincipals; + /** The configuration settings of the Azure Active Directory allowed applications. */ + allowedApplications?: string[]; } -/** Container App Dapr configuration. */ -export interface Dapr { - /** Boolean indicating if the Dapr side car is enabled */ +/** The configuration settings of the Azure Active Directory allowed principals. */ +export interface AllowedPrincipals { + /** The list of the allowed groups. */ + groups?: string[]; + /** The list of the allowed identities. */ + identities?: string[]; +} + +/** The configuration settings of the Facebook provider. */ +export interface Facebook { + /** false if the Facebook provider should not be enabled despite the set registration; otherwise, true. */ enabled?: boolean; - /** Dapr application identifier */ + /** The configuration settings of the app registration for the Facebook provider. */ + registration?: AppRegistration; + /** The version of the Facebook api to be used while logging in. */ + graphApiVersion?: string; + /** The configuration settings of the login flow. */ + login?: LoginScopes; +} + +/** The configuration settings of the app registration for providers that have app ids and app secrets */ +export interface AppRegistration { + /** The App ID of the app used for login. */ appId?: string; - /** Tells Dapr which protocol your application is using. Valid options are http and grpc. Default is http */ - appProtocol?: AppProtocol; - /** Tells Dapr which port your application is listening on */ - appPort?: number; + /** The app setting name that contains the app secret. */ + appSecretSettingName?: string; } -/** - * Container App versioned application definition. - * Defines the desired state of an immutable revision. - * Any changes to this section Will result in a new revision being created - */ -export interface Template { - /** User friendly suffix that is appended to the revision name */ - revisionSuffix?: string; - /** List of container definitions for the Container App. */ - containers?: Container[]; - /** Scaling properties for the Container App. */ - scale?: Scale; - /** List of volume definitions for the Container App. */ - volumes?: Volume[]; +/** The configuration settings of the login flow, including the scopes that should be requested. */ +export interface LoginScopes { + /** A list of the scopes that should be requested while authenticating. */ + scopes?: string[]; } -/** Container App container definition. */ -export interface Container { - /** Container image tag. */ - image?: string; - /** Custom container name. */ - name?: string; - /** Container start command. */ - command?: string[]; - /** Container start command arguments. */ - args?: string[]; - /** Container environment variables. */ - env?: EnvironmentVar[]; - /** Container resource requirements. */ - resources?: ContainerResources; - /** List of probes for the container. */ - probes?: ContainerAppProbe[]; - /** Container volume mounts. */ - volumeMounts?: VolumeMount[]; +/** The configuration settings of the GitHub provider. */ +export interface GitHub { + /** false if the GitHub provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the app registration for the GitHub provider. */ + registration?: ClientRegistration; + /** The configuration settings of the login flow. */ + login?: LoginScopes; } -/** Container App container environment variable. */ -export interface EnvironmentVar { - /** Environment variable name. */ - name?: string; - /** Non-secret environment variable value. */ - value?: string; - /** Name of the Container App secret from which to pull the environment variable value. */ - secretRef?: string; +/** The configuration settings of the app registration for providers that have client ids and client secrets */ +export interface ClientRegistration { + /** The Client ID of the app used for login. */ + clientId?: string; + /** The app setting name that contains the client secret. */ + clientSecretSettingName?: string; } -/** Container App container resource requirements. */ -export interface ContainerResources { - /** Required CPU in cores, e.g. 0.5 */ - cpu?: number; - /** Required memory, e.g. "250Mb" */ - memory?: string; - /** - * Ephemeral Storage, e.g. "1Gi" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly ephemeralStorage?: string; +/** The configuration settings of the Google provider. */ +export interface Google { + /** false if the Google provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the app registration for the Google provider. */ + registration?: ClientRegistration; + /** The configuration settings of the login flow. */ + login?: LoginScopes; + /** The configuration settings of the Azure Active Directory token validation flow. */ + validation?: AllowedAudiencesValidation; } -/** Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic. */ -export interface ContainerAppProbe { - /** Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. Maximum value is 10. */ - failureThreshold?: number; - /** HTTPGet specifies the http request to perform. */ - httpGet?: ContainerAppProbeHttpGet; - /** Number of seconds after the container has started before liveness probes are initiated. Minimum value is 1. Maximum value is 60. */ - initialDelaySeconds?: number; - /** How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. Maximum value is 240. */ - periodSeconds?: number; - /** Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1. Maximum value is 10. */ - successThreshold?: number; - /** TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported. */ - tcpSocket?: ContainerAppProbeTcpSocket; - /** Optional duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. If this value is nil, the pod's terminationGracePeriodSeconds will be used. Otherwise, this value overrides the value provided by the pod spec. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). This is an alpha field and requires enabling ProbeTerminationGracePeriod feature gate. Maximum value is 3600 seconds (1 hour) */ - terminationGracePeriodSeconds?: number; - /** Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. Maximum value is 240. */ - timeoutSeconds?: number; - /** The type of probe. */ - type?: Type; +/** The configuration settings of the Allowed Audiences validation flow. */ +export interface AllowedAudiencesValidation { + /** The configuration settings of the allowed list of audiences from which to validate the JWT token. */ + allowedAudiences?: string[]; } -/** HTTPGet specifies the http request to perform. */ -export interface ContainerAppProbeHttpGet { - /** Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. */ - host?: string; - /** Custom headers to set in the request. HTTP allows repeated headers. */ - httpHeaders?: ContainerAppProbeHttpGetHttpHeadersItem[]; - /** Path to access on the HTTP server. */ - path?: string; - /** Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. */ - port: number; - /** Scheme to use for connecting to the host. Defaults to HTTP. */ - scheme?: string; +/** The configuration settings of the Twitter provider. */ +export interface Twitter { + /** false if the Twitter provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the app registration for the Twitter provider. */ + registration?: TwitterRegistration; } -/** HTTPHeader describes a custom header to be used in HTTP probes */ -export interface ContainerAppProbeHttpGetHttpHeadersItem { - /** The header field name */ - name: string; - /** The header field value */ - value: string; +/** The configuration settings of the app registration for the Twitter provider. */ +export interface TwitterRegistration { + /** + * The OAuth 1.0a consumer key of the Twitter application used for sign-in. + * This setting is required for enabling Twitter Sign-In. + * Twitter Sign-In documentation: https://dev.twitter.com/web/sign-in + */ + consumerKey?: string; + /** + * The app setting name that contains the OAuth 1.0a consumer secret of the Twitter + * application used for sign-in. + */ + consumerSecretSettingName?: string; } -/** TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported. */ -export interface ContainerAppProbeTcpSocket { - /** Optional: Host name to connect to, defaults to the pod IP. */ - host?: string; - /** Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. */ - port: number; +/** The configuration settings of the Apple provider. */ +export interface Apple { + /** false if the Apple provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the Apple registration. */ + registration?: AppleRegistration; + /** The configuration settings of the login flow. */ + login?: LoginScopes; } -/** Volume mount for the Container App. */ -export interface VolumeMount { - /** This must match the Name of a Volume. */ - volumeName?: string; - /** Path within the container at which the volume should be mounted.Must not contain ':'. */ - mountPath?: string; +/** The configuration settings of the registration for the Apple provider */ +export interface AppleRegistration { + /** The Client ID of the app used for login. */ + clientId?: string; + /** The app setting name that contains the client secret. */ + clientSecretSettingName?: string; } -/** Container App scaling configurations. */ -export interface Scale { - /** Optional. Minimum number of container replicas. */ - minReplicas?: number; - /** Optional. Maximum number of container replicas. Defaults to 10 if not set. */ - maxReplicas?: number; - /** Scaling rules. */ - rules?: ScaleRule[]; +/** The configuration settings of the Azure Static Web Apps provider. */ +export interface AzureStaticWebApps { + /** false if the Azure Static Web Apps provider should not be enabled despite the set registration; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the Azure Static Web Apps registration. */ + registration?: AzureStaticWebAppsRegistration; } -/** Container App container scaling rule. */ -export interface ScaleRule { - /** Scale Rule Name */ - name?: string; - /** Azure Queue based scaling. */ - azureQueue?: QueueScaleRule; - /** Custom scale rule. */ - custom?: CustomScaleRule; - /** HTTP requests based scaling. */ - http?: HttpScaleRule; +/** The configuration settings of the registration for the Azure Static Web Apps provider */ +export interface AzureStaticWebAppsRegistration { + /** The Client ID of the app used for login. */ + clientId?: string; } -/** Container App container Azure Queue based scaling rule. */ -export interface QueueScaleRule { - /** Queue name. */ - queueName?: string; - /** Queue length. */ - queueLength?: number; - /** Authentication secrets for the queue scale rule. */ - auth?: ScaleRuleAuth[]; +/** The configuration settings of the custom Open ID Connect provider. */ +export interface CustomOpenIdConnectProvider { + /** false if the custom Open ID provider provider should not be enabled; otherwise, true. */ + enabled?: boolean; + /** The configuration settings of the app registration for the custom Open ID Connect provider. */ + registration?: OpenIdConnectRegistration; + /** The configuration settings of the login flow of the custom Open ID Connect provider. */ + login?: OpenIdConnectLogin; } -/** Auth Secrets for Container App Scale Rule */ -export interface ScaleRuleAuth { - /** Name of the Container App secret from which to pull the auth params. */ - secretRef?: string; - /** Trigger Parameter that uses the secret */ - triggerParameter?: string; +/** The configuration settings of the app registration for the custom Open ID Connect provider. */ +export interface OpenIdConnectRegistration { + /** The client id of the custom Open ID Connect provider. */ + clientId?: string; + /** The authentication credentials of the custom Open ID Connect provider. */ + clientCredential?: OpenIdConnectClientCredential; + /** The configuration settings of the endpoints used for the custom Open ID Connect provider. */ + openIdConnectConfiguration?: OpenIdConnectConfig; } -/** Container App container Custom scaling rule. */ -export interface CustomScaleRule { - /** - * Type of the custom scale rule - * eg: azure-servicebus, redis etc. - */ - type?: string; - /** Metadata properties to describe custom scale rule. */ - metadata?: { [propertyName: string]: string }; - /** Authentication secrets for the custom scale rule. */ - auth?: ScaleRuleAuth[]; +/** The authentication client credentials of the custom Open ID Connect provider. */ +export interface OpenIdConnectClientCredential { + /** The method that should be used to authenticate the user. */ + method?: "ClientSecretPost"; + /** The app setting that contains the client secret for the custom Open ID Connect provider. */ + clientSecretSettingName?: string; } -/** Container App container Custom scaling rule. */ -export interface HttpScaleRule { - /** Metadata properties to describe http scale rule. */ - metadata?: { [propertyName: string]: string }; - /** Authentication secrets for the custom scale rule. */ - auth?: ScaleRuleAuth[]; +/** The configuration settings of the endpoints used for the custom Open ID Connect provider. */ +export interface OpenIdConnectConfig { + /** The endpoint to be used to make an authorization request. */ + authorizationEndpoint?: string; + /** The endpoint to be used to request a token. */ + tokenEndpoint?: string; + /** The endpoint that issues the token. */ + issuer?: string; + /** The endpoint that provides the keys necessary to validate the token. */ + certificationUri?: string; + /** The endpoint that contains all the configuration endpoints for the provider. */ + wellKnownOpenIdConfiguration?: string; } -/** Volume definitions for the Container App. */ -export interface Volume { - /** Volume name. */ - name?: string; - /** Storage type for the volume. If not provided, use EmptyDir. */ - storageType?: StorageType; - /** Name of storage resource. No need to provide for EmptyDir. */ - storageName?: string; +/** The configuration settings of the login flow of the custom Open ID Connect provider. */ +export interface OpenIdConnectLogin { + /** The name of the claim that contains the users name. */ + nameClaimType?: string; + /** A list of the scopes that should be requested while authenticating. */ + scopes?: 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. 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 configuration settings of the login flow of users using ContainerApp Service Authentication/Authorization. */ +export interface Login { + /** The routes that specify the endpoints used for login and logout requests. */ + routes?: LoginRoutes; + /** true if the fragments from the request are preserved after the login request is made; otherwise, false. */ + preserveUrlFragmentsForLogins?: boolean; + /** + * External URLs that can be redirected to as part of logging in or logging out of the app. Note that the query string part of the URL is ignored. + * This is an advanced setting typically only needed by Windows Store application backends. + * Note that URLs within the current domain are always implicitly allowed. + */ + allowedExternalRedirectUrls?: string[]; + /** The configuration settings of the session cookie's expiration. */ + cookieExpiration?: CookieExpiration; + /** The configuration settings of the nonce used in the login flow. */ + nonce?: Nonce; +} + +/** The routes that specify the endpoints used for login and logout requests. */ +export interface LoginRoutes { + /** The endpoint at which a logout request should be made. */ + logoutEndpoint?: string; +} + +/** The configuration settings of the session cookie's expiration. */ +export interface CookieExpiration { + /** The convention used when determining the session cookie's expiration. */ + convention?: CookieExpirationConvention; + /** The time after the request is made when the session cookie should expire. */ + timeToExpiration?: string; +} + +/** The configuration settings of the nonce used in the login flow. */ +export interface Nonce { + /** false if the nonce should not be validated while completing the login flow; otherwise, true. */ + validateNonce?: boolean; + /** The time after the request is made when the nonce should expire. */ + nonceExpirationInterval?: string; +} + +/** The configuration settings of the HTTP requests for authentication and authorization requests made against ContainerApp Service Authentication/Authorization. */ +export interface HttpSettings { + /** false if the authentication/authorization responses not having the HTTPS scheme are permissible; otherwise, true. */ + requireHttps?: boolean; + /** The configuration settings of the paths HTTP requests. */ + routes?: HttpSettingsRoutes; + /** The configuration settings of a forward proxy used to make the requests. */ + forwardProxy?: ForwardProxy; +} + +/** The configuration settings of the paths HTTP requests. */ +export interface HttpSettingsRoutes { + /** The prefix that should precede all the authentication/authorization paths. */ + apiPrefix?: string; +} + +/** The configuration settings of a forward proxy used to make the requests. */ +export interface ForwardProxy { + /** The convention used to determine the url of the request made. */ + convention?: ForwardProxyConvention; + /** The name of the header containing the host of the request. */ + customHostHeaderName?: string; + /** The name of the header containing the scheme of the request. */ + customProtoHeaderName?: 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. 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. @@ -423,674 +494,824 @@ export interface DefaultErrorResponseErrorDetailsItem { readonly target?: string; } -/** Container App Patch. */ -export interface ContainerAppPatch { - /** Application-specific metadata in the form of key-value pairs. */ - tags?: { [propertyName: string]: string }; +/** Container App collection ARM resource. */ +export interface ContainerAppCollection { + /** Collection of resources. */ + value: ContainerApp[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; } -/** Container App Secrets Collection ARM resource. */ -export interface SecretsCollection { - /** Collection of resources. */ - value: ContainerAppSecret[]; +/** 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; } -/** Container App Secret. */ -export interface ContainerAppSecret { +/** Managed service identity (system assigned and/or user assigned identities) */ +export interface ManagedServiceIdentity { /** - * Secret Name. + * 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 name?: string; + readonly principalId?: string; /** - * Secret Value. + * 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 value?: string; + 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 }; } -/** Container App Revisions collection ARM resource. */ -export interface RevisionCollection { - /** Collection of resources. */ - value: Revision[]; +/** User assigned identity properties */ +export interface UserAssignedIdentity { /** - * Link to next page of resources. + * The principal ID of the assigned identity. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly nextLink?: string; + 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; } -/** Container object under Container App Revision Replica. */ -export interface ReplicaContainer { - /** The Name of the Container */ - name?: string; - /** The Id of the Container */ - containerId?: string; - /** The container ready status */ - ready?: boolean; - /** The container start status */ - started?: boolean; - /** The container restart count */ - restartCount?: number; +/** Non versioned Container App configuration properties that define the mutable settings of a Container app */ +export interface Configuration { + /** Collection of secrets used by a Container app */ + secrets?: Secret[]; + /** + * ActiveRevisionsMode controls how active revisions are handled for the Container app: + * Multiple: multiple revisions can be active.Single: Only one revision can be active at a time. Revision weights can not be used in this mode. If no value if provided, this is the default. + */ + activeRevisionsMode?: ActiveRevisionsMode; + /** Ingress configurations. */ + ingress?: Ingress; + /** Collection of private container registry credentials for containers used by the Container app */ + registries?: RegistryCredentials[]; + /** Dapr configuration for the Container App. */ + dapr?: Dapr; } -/** Container App Revision Replicas collection ARM resource. */ -export interface ReplicaCollection { - /** Collection of resources. */ - value: Replica[]; +/** Secret definition. */ +export interface Secret { + /** Secret Name. */ + name?: string; + /** Secret Value. */ + value?: string; } -/** Collection of Environments */ -export interface ManagedEnvironmentsCollection { - /** Collection of resources. */ - value: ManagedEnvironment[]; +/** Container App Ingress configuration. */ +export interface Ingress { /** - * Link to next page of resources. + * Hostname. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly nextLink?: string; -} - -/** Configuration properties for apps environment to join a Virtual Network */ -export interface VnetConfiguration { - /** Boolean indicating the environment only has an internal load balancer. These environments do not have a public static IP resource, must provide ControlPlaneSubnetResourceId and AppSubnetResourceId if enabling this property */ - internal?: boolean; - /** Resource ID of a subnet for infrastructure components. This subnet must be in the same VNET as the subnet defined in runtimeSubnetId. Must not overlap with any other provided IP ranges. */ - infrastructureSubnetId?: string; - /** Resource ID of a subnet that Container App containers are injected into. This subnet must be in the same VNET as the subnet defined in infrastructureSubnetId. Must not overlap with any other provided IP ranges. */ - runtimeSubnetId?: string; - /** CIDR notation IP range assigned to the Docker bridge, network. Must not overlap with any other provided IP ranges. */ - dockerBridgeCidr?: string; - /** IP range in CIDR notation that can be reserved for environment infrastructure IP addresses. Must not overlap with any other provided IP ranges. */ - platformReservedCidr?: string; - /** An IP address from the IP range defined by platformReservedCidr that will be reserved for the internal DNS server. */ - platformReservedDnsIP?: string; + readonly fqdn?: string; + /** Bool indicating if app exposes an external http endpoint */ + external?: boolean; + /** Target Port in containers for traffic from ingress */ + targetPort?: number; + /** Ingress transport protocol */ + transport?: IngressTransportMethod; + /** Traffic weights for app's revisions */ + traffic?: TrafficWeight[]; + /** custom domain bindings for Container Apps' hostnames. */ + customDomains?: CustomDomain[]; + /** Bool indicating if HTTP connections to is allowed. If set to false HTTP connections are automatically redirected to HTTPS connections */ + allowInsecure?: boolean; } -/** Configuration of application logs */ -export interface AppLogsConfiguration { - /** Logs destination */ - destination?: string; - /** Log Analytics configuration */ - logAnalyticsConfiguration?: LogAnalyticsConfiguration; +/** Traffic weight assigned to a revision */ +export interface TrafficWeight { + /** Name of a revision */ + revisionName?: string; + /** Traffic weight assigned to a revision */ + weight?: number; + /** Indicates that the traffic weight belongs to a latest stable revision */ + latestRevision?: boolean; + /** Associates a traffic label with a revision */ + label?: string; } -/** Log analytics configuration */ -export interface LogAnalyticsConfiguration { - /** Log analytics customer id */ - customerId?: string; - /** Log analytics customer key */ - sharedKey?: string; +/** Custom Domain of a Container App */ +export interface CustomDomain { + /** Hostname. */ + name: string; + /** Custom Domain binding type. */ + bindingType?: BindingType; + /** Resource Id of the Certificate to be bound to this hostname. Must exist in the Managed Environment. */ + certificateId: string; } -/** An environment for hosting container apps */ -export interface ManagedEnvironmentPatch { - /** Application-specific metadata in the form of key-value pairs. */ - tags?: { [propertyName: string]: string }; +/** Container App Private Registry */ +export interface RegistryCredentials { + /** Container Registry Server */ + server?: string; + /** Container Registry Username */ + username?: string; + /** The name of the Secret that contains the registry login password */ + passwordSecretRef?: string; + /** A Managed Identity to use to authenticate with Azure Container Registry. For user-assigned identities, use the full user-assigned identity Resource ID. For system-assigned identities, use 'system' */ + identity?: string; } -/** Collection of Certificates. */ -export interface CertificateCollection { - /** Collection of resources. */ - value: Certificate[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; +/** Container App Dapr configuration. */ +export interface Dapr { + /** Boolean indicating if the Dapr side car is enabled */ + enabled?: boolean; + /** Dapr application identifier */ + appId?: string; + /** Tells Dapr which protocol your application is using. Valid options are http and grpc. Default is http */ + appProtocol?: AppProtocol; + /** Tells Dapr which port your application is listening on */ + appPort?: number; + httpReadBufferSize?: number; } -/** Certificate resource specific properties */ -export interface CertificateProperties { - /** - * Provisioning state of the certificate. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: CertificateProvisioningState; - /** Certificate password. */ - password?: string; - /** - * Subject name of the certificate. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly subjectName?: string; - /** PFX or PEM blob */ - value?: Uint8Array; - /** - * Certificate issuer. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly issuer?: string; - /** - * Certificate issue Date. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly issueDate?: Date; - /** - * Certificate expiration date. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly expirationDate?: Date; - /** - * Certificate thumbprint. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly thumbprint?: string; - /** - * Is the certificate valid?. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly valid?: boolean; +/** + * Container App versioned application definition. + * Defines the desired state of an immutable revision. + * Any changes to this section Will result in a new revision being created + */ +export interface Template { + /** User friendly suffix that is appended to the revision name */ + revisionSuffix?: string; + /** List of container definitions for the Container App. */ + containers?: Container[]; + /** Scaling properties for the Container App. */ + scale?: Scale; + /** List of volume definitions for the Container App. */ + volumes?: Volume[]; +} + +/** Container App container definition. */ +export interface Container { + /** Container image tag. */ + image?: string; + /** Custom container name. */ + name?: string; + /** Container start command. */ + command?: string[]; + /** Container start command arguments. */ + args?: string[]; + /** Container environment variables. */ + env?: EnvironmentVar[]; + /** Container resource requirements. */ + resources?: ContainerResources; + /** List of probes for the container. */ + probes?: ContainerAppProbe[]; + /** Container volume mounts. */ + volumeMounts?: VolumeMount[]; +} + +/** Container App container environment variable. */ +export interface EnvironmentVar { + /** Environment variable name. */ + name?: string; + /** Non-secret environment variable value. */ + value?: string; + /** Name of the Container App secret from which to pull the environment variable value. */ + secretRef?: string; +} + +/** Container App container resource requirements. */ +export interface ContainerResources { + /** Required CPU in cores, e.g. 0.5 */ + cpu?: number; + /** Required memory, e.g. "250Mb" */ + memory?: string; /** - * Public key hash. + * Ephemeral Storage, e.g. "1Gi" * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly publicKeyHash?: string; + readonly ephemeralStorage?: string; } -/** A certificate to update */ -export interface CertificatePatch { - /** Application-specific metadata in the form of key-value pairs. */ - tags?: { [propertyName: string]: string }; +/** Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic. */ +export interface ContainerAppProbe { + /** Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. Maximum value is 10. */ + failureThreshold?: number; + /** HTTPGet specifies the http request to perform. */ + httpGet?: ContainerAppProbeHttpGet; + /** Number of seconds after the container has started before liveness probes are initiated. Minimum value is 1. Maximum value is 60. */ + initialDelaySeconds?: number; + /** How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. Maximum value is 240. */ + periodSeconds?: number; + /** Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1. Maximum value is 10. */ + successThreshold?: number; + /** TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported. */ + tcpSocket?: ContainerAppProbeTcpSocket; + /** Optional duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. If this value is nil, the pod's terminationGracePeriodSeconds will be used. Otherwise, this value overrides the value provided by the pod spec. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). This is an alpha field and requires enabling ProbeTerminationGracePeriod feature gate. Maximum value is 3600 seconds (1 hour) */ + terminationGracePeriodSeconds?: number; + /** Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. Maximum value is 240. */ + timeoutSeconds?: number; + /** The type of probe. */ + type?: Type; } -/** Available operations of the service */ -export interface AvailableOperations { - /** Collection of available operation details */ - value?: OperationDetail[]; - /** - * URL client should use to fetch the next page (per server side paging). - * It's null for now, added for future use. - */ - nextLink?: string; +/** HTTPGet specifies the http request to perform. */ +export interface ContainerAppProbeHttpGet { + /** Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. */ + host?: string; + /** Custom headers to set in the request. HTTP allows repeated headers. */ + httpHeaders?: ContainerAppProbeHttpGetHttpHeadersItem[]; + /** Path to access on the HTTP server. */ + path?: string; + /** Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. */ + port: number; + /** Scheme to use for connecting to the host. Defaults to HTTP. */ + scheme?: Scheme; } -/** Operation detail payload */ -export interface OperationDetail { - /** Name of the operation */ - name?: string; - /** Indicates whether the operation is a data action */ - isDataAction?: boolean; - /** Display of the operation */ - display?: OperationDisplay; - /** Origin of the operation */ - origin?: string; +/** HTTPHeader describes a custom header to be used in HTTP probes */ +export interface ContainerAppProbeHttpGetHttpHeadersItem { + /** The header field name */ + name: string; + /** The header field value */ + value: string; } -/** Operation display payload */ -export interface OperationDisplay { - /** Resource provider of the operation */ - provider?: string; - /** Resource of the operation */ - resource?: string; - /** Localized friendly name for the operation */ - operation?: string; - /** Localized friendly description for the operation */ - description?: string; +/** TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported. */ +export interface ContainerAppProbeTcpSocket { + /** Optional: Host name to connect to, defaults to the pod IP. */ + host?: string; + /** Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. */ + port: number; } -/** SourceControl collection ARM resource. */ -export interface SourceControlCollection { - /** Collection of resources. */ - value: SourceControl[]; - /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; +/** Volume mount for the Container App. */ +export interface VolumeMount { + /** This must match the Name of a Volume. */ + volumeName?: string; + /** Path within the container at which the volume should be mounted.Must not contain ':'. */ + mountPath?: string; } -/** Configuration properties that define the mutable settings of a Container App SourceControl */ -export interface GithubActionConfiguration { - /** Registry configurations. */ - registryInfo?: RegistryInfo; - /** AzureCredentials configurations. */ - azureCredentials?: AzureCredentials; - /** Docker file path */ - dockerfilePath?: string; - /** Code or Image */ - publishType?: string; - /** Operation system */ - os?: string; - /** Runtime stack */ - runtimeStack?: string; - /** Runtime Version */ - runtimeVersion?: string; +/** Container App scaling configurations. */ +export interface Scale { + /** Optional. Minimum number of container replicas. */ + minReplicas?: number; + /** Optional. Maximum number of container replicas. Defaults to 10 if not set. */ + maxReplicas?: number; + /** Scaling rules. */ + rules?: ScaleRule[]; } -/** Container App registry information. */ -export interface RegistryInfo { - /** registry server Url. */ - registryUrl?: string; - /** registry username. */ - registryUserName?: string; - /** registry secret. */ - registryPassword?: string; +/** Container App container scaling rule. */ +export interface ScaleRule { + /** Scale Rule Name */ + name?: string; + /** Azure Queue based scaling. */ + azureQueue?: QueueScaleRule; + /** Custom scale rule. */ + custom?: CustomScaleRule; + /** HTTP requests based scaling. */ + http?: HttpScaleRule; } -/** Container App credentials. */ -export interface AzureCredentials { - /** Client Id. */ - clientId?: string; - /** Client Secret. */ - clientSecret?: string; - /** Tenant Id. */ - tenantId?: string; - /** Subscription Id. */ - subscriptionId?: string; +/** Container App container Azure Queue based scaling rule. */ +export interface QueueScaleRule { + /** Queue name. */ + queueName?: string; + /** Queue length. */ + queueLength?: number; + /** Authentication secrets for the queue scale rule. */ + auth?: ScaleRuleAuth[]; } -/** Dapr Components ARM resource. */ -export interface DaprComponentsCollection { - /** Collection of resources. */ - value: DaprComponent[]; +/** Auth Secrets for Container App Scale Rule */ +export interface ScaleRuleAuth { + /** Name of the Container App secret from which to pull the auth params. */ + secretRef?: string; + /** Trigger Parameter that uses the secret */ + triggerParameter?: string; +} + +/** Container App container Custom scaling rule. */ +export interface CustomScaleRule { /** - * Link to next page of resources. - * NOTE: This property will not be serialized. It can only be populated by the server. + * Type of the custom scale rule + * eg: azure-servicebus, redis etc. */ - readonly nextLink?: string; + type?: string; + /** Metadata properties to describe custom scale rule. */ + metadata?: { [propertyName: string]: string }; + /** Authentication secrets for the custom scale rule. */ + auth?: ScaleRuleAuth[]; } -/** Dapr component metadata. */ -export interface DaprMetadata { - /** Metadata property name. */ +/** Container App container Custom scaling rule. */ +export interface HttpScaleRule { + /** Metadata properties to describe http scale rule. */ + metadata?: { [propertyName: string]: string }; + /** Authentication secrets for the custom scale rule. */ + auth?: ScaleRuleAuth[]; +} + +/** Volume definitions for the Container App. */ +export interface Volume { + /** Volume name. */ name?: string; - /** Metadata property value. */ - value?: string; - /** Name of the Dapr Component secret from which to pull the metadata property value. */ - secretRef?: string; + /** Storage type for the volume. If not provided, use EmptyDir. */ + storageType?: StorageType; + /** Name of storage resource. No need to provide for EmptyDir. */ + storageName?: string; } -/** AuthConfig collection ARM resource. */ -export interface AuthConfigCollection { - /** Collection of resources. */ - value: AuthConfig[]; +/** Custom domain analysis. */ +export interface CustomHostnameAnalysisResult { + /** + * Host name that was analyzed + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly hostName?: string; + /** + * true if hostname is already verified; otherwise, false. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly isHostnameAlreadyVerified?: boolean; + /** + * DNS verification test result. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly customDomainVerificationTest?: DnsVerificationTestResult; + /** + * Raw failure information if DNS verification fails. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly customDomainVerificationFailureInfo?: CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo; /** - * Link to next page of resources. + * true if there is a conflict on the Container App's managed environment; otherwise, false. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly nextLink?: string; -} - -/** The configuration settings of the platform of ContainerApp Service Authentication/Authorization. */ -export interface AuthPlatform { - /** true if the Authentication / Authorization feature is enabled for the current app; otherwise, false. */ - enabled?: boolean; + readonly hasConflictOnManagedEnvironment?: boolean; /** - * The RuntimeVersion of the Authentication / Authorization feature in use for the current app. - * The setting in this value can control the behavior of certain features in the Authentication / Authorization module. + * Name of the conflicting Container App on the Managed Environment if it's within the same subscription. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - runtimeVersion?: string; + readonly conflictingContainerAppResourceId?: string; + /** CName records visible for this hostname. */ + cNameRecords?: string[]; + /** TXT records visible for this hostname. */ + txtRecords?: string[]; + /** A records visible for this hostname. */ + aRecords?: string[]; + /** Alternate CName records visible for this hostname. */ + alternateCNameRecords?: string[]; + /** Alternate TXT records visible for this hostname. */ + alternateTxtRecords?: string[]; } -/** The configuration settings that determines the validation flow of users using ContainerApp Service Authentication/Authorization. */ -export interface GlobalValidation { - /** The action to take when an unauthenticated client attempts to access the app. */ - unauthenticatedClientAction?: UnauthenticatedClientActionV2; +/** Raw failure information if DNS verification fails. */ +export interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo { /** - * The default authentication provider to use when multiple providers are configured. - * This setting is only needed if multiple providers are configured and the unauthenticated client - * action is set to "RedirectToLoginPage". + * Standardized string to programmatically identify the error. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - redirectToProvider?: string; - /** The paths for which unauthenticated flow would not be redirected to the login page. */ - excludedPaths?: string[]; -} - -/** The configuration settings of each of the identity providers used to configure ContainerApp Service Authentication/Authorization. */ -export interface IdentityProviders { - /** The configuration settings of the Azure Active directory provider. */ - azureActiveDirectory?: AzureActiveDirectory; - /** The configuration settings of the Facebook provider. */ - facebook?: Facebook; - /** The configuration settings of the GitHub provider. */ - gitHub?: GitHub; - /** The configuration settings of the Google provider. */ - google?: Google; - /** The configuration settings of the Twitter provider. */ - twitter?: Twitter; - /** The configuration settings of the Apple provider. */ - apple?: Apple; - /** The configuration settings of the Azure Static Web Apps provider. */ - azureStaticWebApps?: AzureStaticWebApps; + readonly code?: string; /** - * The map of the name of the alias of each custom Open ID Connect provider to the - * configuration settings of the custom Open ID Connect provider. + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - customOpenIdConnectProviders?: { - [propertyName: string]: CustomOpenIdConnectProvider; - }; -} - -/** The configuration settings of the Azure Active directory provider. */ -export interface AzureActiveDirectory { - /** false if the Azure Active Directory provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the Azure Active Directory app registration. */ - registration?: AzureActiveDirectoryRegistration; - /** The configuration settings of the Azure Active Directory login flow. */ - login?: AzureActiveDirectoryLogin; - /** The configuration settings of the Azure Active Directory token validation flow. */ - validation?: AzureActiveDirectoryValidation; + readonly message?: string; /** - * Gets a value indicating whether the Azure AD configuration was auto-provisioned using 1st party tooling. - * This is an internal flag primarily intended to support the Azure Management Portal. Users should not - * read or write to this property. + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - isAutoProvisioned?: boolean; + readonly target?: string; + /** Details or the error */ + details?: CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem[]; } -/** The configuration settings of the Azure Active Directory app registration. */ -export interface AzureActiveDirectoryRegistration { +/** Detailed errors. */ +export interface CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem { /** - * The OpenID Connect Issuer URI that represents the entity which issues access tokens for this application. - * When using Azure Active Directory, this value is the URI of the directory tenant, e.g. https://login.microsoftonline.com/v2.0/{tenant-guid}/. - * This URI is a case-sensitive identifier for the token issuer. - * More information on OpenID Connect Discovery: http://openid.net/specs/openid-connect-discovery-1_0.html + * Standardized string to programmatically identify the error. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - openIdIssuer?: string; + readonly code?: string; /** - * The Client ID of this relying party application, known as the client_id. - * This setting is required for enabling OpenID Connection authentication with Azure Active Directory or - * other 3rd party OpenID Connect providers. - * More information on OpenID Connect: http://openid.net/specs/openid-connect-core-1_0.html + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - clientId?: string; - /** The app setting name that contains the client secret of the relying party application. */ - clientSecretSettingName?: string; + readonly message?: string; /** - * An alternative to the client secret, that is the thumbprint of a certificate used for signing purposes. This property acts as - * a replacement for the Client Secret. It is also optional. + * Detailed error description and debugging information. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - clientSecretCertificateThumbprint?: string; + readonly target?: string; +} + +/** Container App Secrets Collection ARM resource. */ +export interface SecretsCollection { + /** Collection of resources. */ + value: ContainerAppSecret[]; +} + +/** Container App Secret. */ +export interface ContainerAppSecret { /** - * An alternative to the client secret thumbprint, that is the subject alternative name of a certificate used for signing purposes. This property acts as - * a replacement for the Client Secret Certificate Thumbprint. It is also optional. + * Secret Name. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - clientSecretCertificateSubjectAlternativeName?: string; + readonly name?: string; /** - * An alternative to the client secret thumbprint, that is the issuer of a certificate used for signing purposes. This property acts as - * a replacement for the Client Secret Certificate Thumbprint. It is also optional. + * Secret Value. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - clientSecretCertificateIssuer?: string; + readonly value?: string; } -/** The configuration settings of the Azure Active Directory login flow. */ -export interface AzureActiveDirectoryLogin { +/** Container App Revisions collection ARM resource. */ +export interface RevisionCollection { + /** Collection of resources. */ + value: Revision[]; /** - * Login parameters to send to the OpenID Connect authorization endpoint when - * a user logs in. Each parameter must be in the form "key=value". + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. */ - loginParameters?: string[]; - /** true if the www-authenticate provider should be omitted from the request; otherwise, false. */ - disableWWWAuthenticate?: boolean; -} - -/** The configuration settings of the Azure Active Directory token validation flow. */ -export interface AzureActiveDirectoryValidation { - /** The configuration settings of the checks that should be made while validating the JWT Claims. */ - jwtClaimChecks?: JwtClaimChecks; - /** The list of audiences that can make successful authentication/authorization requests. */ - allowedAudiences?: string[]; - /** The configuration settings of the default authorization policy. */ - defaultAuthorizationPolicy?: DefaultAuthorizationPolicy; -} - -/** The configuration settings of the checks that should be made while validating the JWT Claims. */ -export interface JwtClaimChecks { - /** The list of the allowed groups. */ - allowedGroups?: string[]; - /** The list of the allowed client applications. */ - allowedClientApplications?: string[]; -} - -/** The configuration settings of the Azure Active Directory default authorization policy. */ -export interface DefaultAuthorizationPolicy { - /** The configuration settings of the Azure Active Directory allowed principals. */ - allowedPrincipals?: AllowedPrincipals; - /** The configuration settings of the Azure Active Directory allowed applications. */ - allowedApplications?: string[]; + readonly nextLink?: string; } -/** The configuration settings of the Azure Active Directory allowed principals. */ -export interface AllowedPrincipals { - /** The list of the allowed groups. */ - groups?: string[]; - /** The list of the allowed identities. */ - identities?: string[]; +/** Traffic label information */ +export interface TrafficLabel { + /** + * Traffic label assigned to a revision + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly label?: string; + /** + * Fully qualified domain name of a labelled revision + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly fqdn?: string; } -/** The configuration settings of the Facebook provider. */ -export interface Facebook { - /** false if the Facebook provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the app registration for the Facebook provider. */ - registration?: AppRegistration; - /** The version of the Facebook api to be used while logging in. */ - graphApiVersion?: string; - /** The configuration settings of the login flow. */ - login?: LoginScopes; +/** Container object under Container App Revision Replica. */ +export interface ReplicaContainer { + /** The Name of the Container */ + name?: string; + /** The Id of the Container */ + containerId?: string; + /** The container ready status */ + ready?: boolean; + /** The container start status */ + started?: boolean; + /** The container restart count */ + restartCount?: number; } -/** The configuration settings of the app registration for providers that have app ids and app secrets */ -export interface AppRegistration { - /** The App ID of the app used for login. */ - appId?: string; - /** The app setting name that contains the app secret. */ - appSecretSettingName?: string; +/** Container App Revision Replicas collection ARM resource. */ +export interface ReplicaCollection { + /** Collection of resources. */ + value: Replica[]; } -/** The configuration settings of the login flow, including the scopes that should be requested. */ -export interface LoginScopes { - /** A list of the scopes that should be requested while authenticating. */ - scopes?: string[]; +/** Dapr Components ARM resource. */ +export interface DaprComponentsCollection { + /** Collection of resources. */ + value: DaprComponent[]; + /** + * 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 configuration settings of the GitHub provider. */ -export interface GitHub { - /** false if the GitHub provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the app registration for the GitHub provider. */ - registration?: ClientRegistration; - /** The configuration settings of the login flow. */ - login?: LoginScopes; +/** Dapr component metadata. */ +export interface DaprMetadata { + /** Metadata property name. */ + name?: string; + /** Metadata property value. */ + value?: string; + /** Name of the Dapr Component secret from which to pull the metadata property value. */ + secretRef?: string; } -/** The configuration settings of the app registration for providers that have client ids and client secrets */ -export interface ClientRegistration { - /** The Client ID of the app used for login. */ - clientId?: string; - /** The app setting name that contains the client secret. */ - clientSecretSettingName?: string; +/** Dapr component Secrets Collection ARM resource. */ +export interface DaprSecretsCollection { + /** Collection of secrets used by a Dapr component */ + value: Secret[]; } -/** The configuration settings of the Google provider. */ -export interface Google { - /** false if the Google provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the app registration for the Google provider. */ - registration?: ClientRegistration; - /** The configuration settings of the login flow. */ - login?: LoginScopes; - /** The configuration settings of the Azure Active Directory token validation flow. */ - validation?: AllowedAudiencesValidation; +/** Diagnostics data collection for a resource. */ +export interface DiagnosticsCollection { + /** Collection of diagnostic data. */ + value: Diagnostics[]; + /** + * 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 configuration settings of the Allowed Audiences validation flow. */ -export interface AllowedAudiencesValidation { - /** The configuration settings of the allowed list of audiences from which to validate the JWT token. */ - allowedAudiences?: string[]; +/** Diagnostics resource specific properties */ +export interface DiagnosticsProperties { + /** Metadata of the diagnostics response. */ + metadata?: DiagnosticsDefinition; + /** Set of data collections associated with the response. */ + dataset?: DiagnosticsDataApiResponse[]; + /** Status of the diagnostics response. */ + status?: DiagnosticsStatus; + /** List of data providers' metadata. */ + dataProviderMetadata?: DiagnosticDataProviderMetadata; } -/** The configuration settings of the Twitter provider. */ -export interface Twitter { - /** false if the Twitter provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the app registration for the Twitter provider. */ - registration?: TwitterRegistration; +/** Metadata of the diagnostics response */ +export interface DiagnosticsDefinition { + /** + * Unique detector name + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; + /** + * Display Name of the detector + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * Details of the diagnostics info + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly description?: string; + /** + * Authors' names of the detector + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly author?: string; + /** + * Category of the detector + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly category?: string; + /** List of support topics */ + supportTopicList?: DiagnosticSupportTopic[]; + /** List of analysis types */ + analysisTypes?: string[]; + /** + * Authors' names of the detector + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * Authors' names of the detector + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly score?: number; } -/** The configuration settings of the app registration for the Twitter provider. */ -export interface TwitterRegistration { +/** Support topic information */ +export interface DiagnosticSupportTopic { /** - * The OAuth 1.0a consumer key of the Twitter application used for sign-in. - * This setting is required for enabling Twitter Sign-In. - * Twitter Sign-In documentation: https://dev.twitter.com/web/sign-in + * Unique topic identifier + * NOTE: This property will not be serialized. It can only be populated by the server. */ - consumerKey?: string; + readonly id?: string; /** - * The app setting name that contains the OAuth 1.0a consumer secret of the Twitter - * application used for sign-in. + * PES identifier + * NOTE: This property will not be serialized. It can only be populated by the server. */ - consumerSecretSettingName?: string; + readonly pesId?: string; } -/** The configuration settings of the Apple provider. */ -export interface Apple { - /** false if the Apple provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the Apple registration. */ - registration?: AppleRegistration; - /** The configuration settings of the login flow. */ - login?: LoginScopes; +/** Diagnostics data returned from a detector */ +export interface DiagnosticsDataApiResponse { + /** Table response */ + table?: DiagnosticDataTableResponseObject; + /** Details of the table response */ + renderingProperties?: DiagnosticRendering; } -/** The configuration settings of the registration for the Apple provider */ -export interface AppleRegistration { - /** The Client ID of the app used for login. */ - clientId?: string; - /** The app setting name that contains the client secret. */ - clientSecretSettingName?: string; +/** Diagnostics data table */ +export interface DiagnosticDataTableResponseObject { + /** Table name */ + tableName?: string; + /** Columns in the table */ + columns?: DiagnosticDataTableResponseColumn[]; + /** Rows in the table */ + rows?: Record[]; } -/** The configuration settings of the Azure Static Web Apps provider. */ -export interface AzureStaticWebApps { - /** false if the Azure Static Web Apps provider should not be enabled despite the set registration; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the Azure Static Web Apps registration. */ - registration?: AzureStaticWebAppsRegistration; +/** Diagnostics data column */ +export interface DiagnosticDataTableResponseColumn { + /** Column name */ + columnName?: string; + /** Data type of the column */ + dataType?: string; + /** Column type */ + columnType?: string; } -/** The configuration settings of the registration for the Azure Static Web Apps provider */ -export interface AzureStaticWebAppsRegistration { - /** The Client ID of the app used for login. */ - clientId?: string; +/** Rendering details of a diagnostics table */ +export interface DiagnosticRendering { + /** Rendering type */ + type?: number; + /** Title of the table */ + title?: string; + /** Description of the table */ + description?: string; + /** Flag if the table should be rendered */ + isVisible?: boolean; } -/** The configuration settings of the custom Open ID Connect provider. */ -export interface CustomOpenIdConnectProvider { - /** false if the custom Open ID provider provider should not be enabled; otherwise, true. */ - enabled?: boolean; - /** The configuration settings of the app registration for the custom Open ID Connect provider. */ - registration?: OpenIdConnectRegistration; - /** The configuration settings of the login flow of the custom Open ID Connect provider. */ - login?: OpenIdConnectLogin; +/** Rendering details of a diagnostics table */ +export interface DiagnosticsStatus { + /** Diagnostic message */ + message?: string; + /** Status */ + statusId?: number; } -/** The configuration settings of the app registration for the custom Open ID Connect provider. */ -export interface OpenIdConnectRegistration { - /** The client id of the custom Open ID Connect provider. */ - clientId?: string; - /** The authentication credentials of the custom Open ID Connect provider. */ - clientCredential?: OpenIdConnectClientCredential; - /** The configuration settings of the endpoints used for the custom Open ID Connect provider. */ - openIdConnectConfiguration?: OpenIdConnectConfig; +/** Details of a diagnostics data provider */ +export interface DiagnosticDataProviderMetadata { + /** Name of data provider */ + providerName?: string; + /** Collection of properties */ + propertyBag?: DiagnosticDataProviderMetadataPropertyBagItem[]; } -/** The authentication client credentials of the custom Open ID Connect provider. */ -export interface OpenIdConnectClientCredential { - /** The method that should be used to authenticate the user. */ - method?: "ClientSecretPost"; - /** The app setting that contains the client secret for the custom Open ID Connect provider. */ - clientSecretSettingName?: string; +/** Property details */ +export interface DiagnosticDataProviderMetadataPropertyBagItem { + /** Property name */ + name?: string; + /** Property value */ + value?: string; } -/** The configuration settings of the endpoints used for the custom Open ID Connect provider. */ -export interface OpenIdConnectConfig { - /** The endpoint to be used to make an authorization request. */ - authorizationEndpoint?: string; - /** The endpoint to be used to request a token. */ - tokenEndpoint?: string; - /** The endpoint that issues the token. */ - issuer?: string; - /** The endpoint that provides the keys necessary to validate the token. */ - certificationUri?: string; - /** The endpoint that contains all the configuration endpoints for the provider. */ - wellKnownOpenIdConfiguration?: string; +/** Configuration properties for apps environment to join a Virtual Network */ +export interface VnetConfiguration { + /** Boolean indicating the environment only has an internal load balancer. These environments do not have a public static IP resource. They must provide runtimeSubnetId and infrastructureSubnetId if enabling this property */ + internal?: boolean; + /** Resource ID of a subnet for infrastructure components. This subnet must be in the same VNET as the subnet defined in runtimeSubnetId. Must not overlap with any other provided IP ranges. */ + infrastructureSubnetId?: string; + /** Resource ID of a subnet that Container App containers are injected into. This subnet must be in the same VNET as the subnet defined in infrastructureSubnetId. Must not overlap with any other provided IP ranges. */ + runtimeSubnetId?: string; + /** CIDR notation IP range assigned to the Docker bridge, network. Must not overlap with any other provided IP ranges. */ + dockerBridgeCidr?: string; + /** IP range in CIDR notation that can be reserved for environment infrastructure IP addresses. Must not overlap with any other provided IP ranges. */ + platformReservedCidr?: string; + /** An IP address from the IP range defined by platformReservedCidr that will be reserved for the internal DNS server. */ + platformReservedDnsIP?: string; } -/** The configuration settings of the login flow of the custom Open ID Connect provider. */ -export interface OpenIdConnectLogin { - /** The name of the claim that contains the users name. */ - nameClaimType?: string; - /** A list of the scopes that should be requested while authenticating. */ - scopes?: string[]; +/** Configuration of application logs */ +export interface AppLogsConfiguration { + /** Logs destination */ + destination?: string; + /** Log Analytics configuration */ + logAnalyticsConfiguration?: LogAnalyticsConfiguration; } -/** The configuration settings of the login flow of users using ContainerApp Service Authentication/Authorization. */ -export interface Login { - /** The routes that specify the endpoints used for login and logout requests. */ - routes?: LoginRoutes; - /** true if the fragments from the request are preserved after the login request is made; otherwise, false. */ - preserveUrlFragmentsForLogins?: boolean; +/** Log analytics configuration */ +export interface LogAnalyticsConfiguration { + /** Log analytics customer id */ + customerId?: string; + /** Log analytics customer key */ + sharedKey?: string; +} + +/** Available operations of the service */ +export interface AvailableOperations { + /** Collection of available operation details */ + value?: OperationDetail[]; /** - * External URLs that can be redirected to as part of logging in or logging out of the app. Note that the query string part of the URL is ignored. - * This is an advanced setting typically only needed by Windows Store application backends. - * Note that URLs within the current domain are always implicitly allowed. + * URL client should use to fetch the next page (per server side paging). + * It's null for now, added for future use. */ - allowedExternalRedirectUrls?: string[]; - /** The configuration settings of the session cookie's expiration. */ - cookieExpiration?: CookieExpiration; - /** The configuration settings of the nonce used in the login flow. */ - nonce?: Nonce; + nextLink?: string; } -/** The routes that specify the endpoints used for login and logout requests. */ -export interface LoginRoutes { - /** The endpoint at which a logout request should be made. */ - logoutEndpoint?: string; +/** Operation detail payload */ +export interface OperationDetail { + /** Name of the operation */ + name?: string; + /** Indicates whether the operation is a data action */ + isDataAction?: boolean; + /** Display of the operation */ + display?: OperationDisplay; + /** Origin of the operation */ + origin?: string; } -/** The configuration settings of the session cookie's expiration. */ -export interface CookieExpiration { - /** The convention used when determining the session cookie's expiration. */ - convention?: CookieExpirationConvention; - /** The time after the request is made when the session cookie should expire. */ - timeToExpiration?: string; +/** Operation display payload */ +export interface OperationDisplay { + /** Resource provider of the operation */ + provider?: string; + /** Resource of the operation */ + resource?: string; + /** Localized friendly name for the operation */ + operation?: string; + /** Localized friendly description for the operation */ + description?: string; } -/** The configuration settings of the nonce used in the login flow. */ -export interface Nonce { - /** false if the nonce should not be validated while completing the login flow; otherwise, true. */ - validateNonce?: boolean; - /** The time after the request is made when the nonce should expire. */ - nonceExpirationInterval?: string; +/** Collection of Environments */ +export interface ManagedEnvironmentsCollection { + /** Collection of resources. */ + value: ManagedEnvironment[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Collection of Certificates. */ +export interface CertificateCollection { + /** Collection of resources. */ + value: Certificate[]; + /** + * Link to next page of resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Certificate resource specific properties */ +export interface CertificateProperties { + /** + * Provisioning state of the certificate. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: CertificateProvisioningState; + /** Certificate password. */ + password?: string; + /** + * Subject name of the certificate. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly subjectName?: string; + /** + * Subject alternative names the certificate applies to. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly subjectAlternativeNames?: string[]; + /** PFX or PEM blob */ + value?: Uint8Array; + /** + * Certificate issuer. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly issuer?: string; + /** + * Certificate issue Date. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly issueDate?: Date; + /** + * Certificate expiration date. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly expirationDate?: Date; + /** + * Certificate thumbprint. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly thumbprint?: string; + /** + * Is the certificate valid?. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly valid?: boolean; + /** + * Public key hash. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly publicKeyHash?: string; } -/** The configuration settings of the HTTP requests for authentication and authorization requests made against ContainerApp Service Authentication/Authorization. */ -export interface HttpSettings { - /** false if the authentication/authorization responses not having the HTTPS scheme are permissible; otherwise, true. */ - requireHttps?: boolean; - /** The configuration settings of the paths HTTP requests. */ - routes?: HttpSettingsRoutes; - /** The configuration settings of a forward proxy used to make the requests. */ - forwardProxy?: ForwardProxy; +/** A certificate to update */ +export interface CertificatePatch { + /** Application-specific metadata in the form of key-value pairs. */ + tags?: { [propertyName: string]: string }; } -/** The configuration settings of the paths HTTP requests. */ -export interface HttpSettingsRoutes { - /** The prefix that should precede all the authentication/authorization paths. */ - apiPrefix?: string; +/** The check availability request body. */ +export interface CheckNameAvailabilityRequest { + /** The name of the resource for which availability needs to be checked. */ + name?: string; + /** The resource type. */ + type?: string; } -/** The configuration settings of a forward proxy used to make the requests. */ -export interface ForwardProxy { - /** The convention used to determine the url of the request made. */ - convention?: ForwardProxyConvention; - /** The name of the header containing the host of the request. */ - customHostHeaderName?: string; - /** The name of the header containing the scheme of the request. */ - customProtoHeaderName?: string; +/** The check availability result. */ +export interface CheckNameAvailabilityResponse { + /** Indicates if the resource name is available. */ + nameAvailable?: boolean; + /** The reason why the given name is not available. */ + reason?: CheckNameAvailabilityReason; + /** Detailed reason why the given name is available. */ + message?: string; } /** Collection of Storage for Environments */ @@ -1117,263 +1338,388 @@ export interface AzureFileProperties { shareName?: string; } +/** SourceControl collection ARM resource. */ +export interface SourceControlCollection { + /** Collection of resources. */ + value: SourceControl[]; + /** + * 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 that define the mutable settings of a Container App SourceControl */ +export interface GithubActionConfiguration { + /** Registry configurations. */ + registryInfo?: RegistryInfo; + /** AzureCredentials configurations. */ + azureCredentials?: AzureCredentials; + /** Context path */ + contextPath?: string; + /** Image name */ + image?: string; + /** Code or Image */ + publishType?: string; + /** Operation system */ + os?: string; + /** Runtime stack */ + runtimeStack?: string; + /** Runtime version */ + runtimeVersion?: string; +} + +/** Container App registry information. */ +export interface RegistryInfo { + /** registry server Url. */ + registryUrl?: string; + /** registry username. */ + registryUserName?: string; + /** registry secret. */ + registryPassword?: string; +} + +/** Container App credentials. */ +export interface AzureCredentials { + /** Client Id. */ + clientId?: string; + /** Client Secret. */ + clientSecret?: string; + /** Tenant Id. */ + tenantId?: string; + /** Subscription Id. */ + subscriptionId?: 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; +} + +/** Collection of Storage for Environments */ +export interface ConnectedEnvironmentStoragesCollection { + /** Collection of storage resources. */ + value: ConnectedEnvironmentStorage[]; +} + +/** Storage properties */ +export interface ConnectedEnvironmentStorageProperties { + /** Azure file properties */ + azureFile?: AzureFileProperties; +} + +/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ +export interface ProxyResource extends Resource {} + /** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */ -export type TrackedResource = Resource & { +export interface TrackedResource extends Resource { /** Resource tags. */ tags?: { [propertyName: string]: string }; /** The geo-location where the resource lives */ location: string; -}; +} -/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ -export type ProxyResource = Resource & {}; +/** 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. */ + platform?: AuthPlatform; + /** The configuration settings that determines the validation flow of users using Service Authentication/Authorization. */ + globalValidation?: GlobalValidation; + /** The configuration settings of each of the identity providers used to configure ContainerApp Service Authentication/Authorization. */ + identityProviders?: IdentityProviders; + /** The configuration settings of the login flow of users using ContainerApp Service Authentication/Authorization. */ + login?: Login; + /** The configuration settings of the HTTP requests for authentication and authorization requests made against ContainerApp Service Authentication/Authorization. */ + httpSettings?: HttpSettings; +} -/** Container App. */ -export type ContainerApp = TrackedResource & { - /** managed identities for the Container App to interact with other Azure services without maintaining any secrets or credentials in code. */ - identity?: ManagedServiceIdentity; - /** - * Provisioning state of the Container App. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: ContainerAppProvisioningState; - /** Resource ID of the Container App's environment. */ - managedEnvironmentId?: string; +/** Container App Revision. */ +export interface Revision extends ProxyResource { /** - * Name of the latest revision of the Container App. + * Timestamp describing when the revision was created + * by controller * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly latestRevisionName?: string; + readonly createdTime?: Date; /** - * Fully Qualified Domain Name of the latest revision of the Container App. + * Fully qualified domain name of the revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly latestRevisionFqdn?: string; + readonly fqdn?: string; /** - * Id used to verify domain name ownership + * Container App Revision Template with all possible settings and the + * defaults if user did not provide them. The defaults are populated + * as they were at the creation time * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly customDomainVerificationId?: string; - /** Non versioned Container App configuration properties. */ - configuration?: Configuration; - /** Container App versioned application definition. */ - template?: Template; + readonly template?: Template; /** - * Outbound IP Addresses for container app. + * Boolean describing if the Revision is Active * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly outboundIPAddresses?: string[]; -}; - -/** An environment for hosting container apps */ -export type ManagedEnvironment = TrackedResource & { + readonly active?: boolean; /** - * Provisioning state of the Environment. + * Number of pods currently running for this revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly provisioningState?: EnvironmentProvisioningState; - /** Azure Monitor instrumentation key used by Dapr to export Service to Service communication telemetry */ - daprAIInstrumentationKey?: string; - /** Vnet configuration for the environment */ - vnetConfiguration?: VnetConfiguration; + readonly replicas?: number; /** - * Any errors that occurred during deployment or deployment validation + * Traffic weight assigned to this revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly deploymentErrors?: string; + readonly trafficWeight?: number; /** - * Default Domain Name for the cluster + * Traffic labels associated with this revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly defaultDomain?: string; + readonly trafficLabels?: TrafficLabel[]; /** - * Static IP of the Environment + * Optional Field - Platform Error Message * 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 - */ - appLogsConfiguration?: AppLogsConfiguration; -}; - -/** Certificate used for Custom Domain bindings of Container Apps in a Managed Environment */ -export type Certificate = TrackedResource & { - /** Certificate resource specific properties */ - properties?: CertificateProperties; -}; - -/** Custom domain analysis. */ -export type CustomHostnameAnalysisResult = ProxyResource & { + readonly provisioningError?: string; /** - * Host name that was analyzed + * Current health State of the revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly hostName?: string; + readonly healthState?: RevisionHealthState; /** - * true if hostname is already verified; otherwise, false. + * Current provisioning State of the revision * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly isHostnameAlreadyVerified?: boolean; + readonly provisioningState?: RevisionProvisioningState; +} + +/** Container App Revision Replica. */ +export interface Replica extends ProxyResource { /** - * DNS verification test result. + * Timestamp describing when the pod was created by controller * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly customDomainVerificationTest?: DnsVerificationTestResult; + readonly createdTime?: Date; + /** The containers collection under a replica. */ + containers?: ReplicaContainer[]; +} + +/** Dapr Component. */ +export interface DaprComponent extends ProxyResource { + /** Component type */ + componentType?: string; + /** Component version */ + version?: string; + /** Boolean describing if the component errors are ignores */ + ignoreErrors?: boolean; + /** Initialization timeout */ + initTimeout?: string; + /** Collection of secrets used by a Dapr component */ + secrets?: Secret[]; + /** Component metadata */ + metadata?: DaprMetadata[]; + /** Names of container apps that can use this Dapr component */ + scopes?: string[]; +} + +/** Diagnostics data for a resource. */ +export interface Diagnostics extends ProxyResource { + /** Diagnostics resource specific properties */ + properties?: DiagnosticsProperties; +} + +/** Storage resource for managedEnvironment. */ +export interface ManagedEnvironmentStorage extends ProxyResource { + /** Storage properties */ + properties?: ManagedEnvironmentStorageProperties; +} + +/** Container App SourceControl. */ +export interface SourceControl extends ProxyResource { /** - * Raw failure information if DNS verification fails. + * Current provisioning State of the operation * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly customDomainVerificationFailureInfo?: DefaultErrorResponse; + readonly operationState?: SourceControlOperationState; + /** The repo url which will be integrated to ContainerApp. */ + repoUrl?: string; + /** The branch which will trigger the auto deployment */ + branch?: string; /** - * true if there is a conflict on the Container App's managed environment; otherwise, false. - * NOTE: This property will not be serialized. It can only be populated by the server. + * Container App Revision Template with all possible settings and the + * defaults if user did not provide them. The defaults are populated + * as they were at the creation time */ - readonly hasConflictOnManagedEnvironment?: boolean; + githubActionConfiguration?: GithubActionConfiguration; +} + +/** Storage resource for connectedEnvironment. */ +export interface ConnectedEnvironmentStorage extends ProxyResource { + /** Storage properties */ + properties?: ConnectedEnvironmentStorageProperties; +} + +/** Container App. */ +export interface ContainerApp extends TrackedResource { + /** The complex type of the extended location. */ + extendedLocation?: ExtendedLocation; + /** managed identities for the Container App to interact with other Azure services without maintaining any secrets or credentials in code. */ + identity?: ManagedServiceIdentity; /** - * Name of the conflicting Container App on the Managed Environment if it's within the same subscription. + * Provisioning state of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly conflictingContainerAppResourceId?: string; - /** CName records visible for this hostname. */ - cNameRecords?: string[]; - /** TXT records visible for this hostname. */ - txtRecords?: string[]; - /** A records visible for this hostname. */ - aRecords?: string[]; - /** Alternate CName records visible for this hostname. */ - alternateCNameRecords?: string[]; - /** Alternate TXT records visible for this hostname. */ - alternateTxtRecords?: string[]; -}; - -/** Container App Revision. */ -export type Revision = ProxyResource & { + readonly provisioningState?: ContainerAppProvisioningState; + /** Deprecated. Resource ID of the Container App's environment. */ + managedEnvironmentId?: string; + /** Resource ID of environment. */ + environmentId?: string; /** - * Timestamp describing when the revision was created - * by controller + * Name of the latest revision of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly createdTime?: Date; + readonly latestRevisionName?: string; /** - * Fully qualified domain name of the revision + * Fully Qualified Domain Name of the latest revision of the Container App. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly fqdn?: string; + readonly latestRevisionFqdn?: string; /** - * Container App Revision Template with all possible settings and the - * defaults if user did not provide them. The defaults are populated - * as they were at the creation time + * Id used to verify domain name ownership * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly template?: Template; + readonly customDomainVerificationId?: string; + /** Non versioned Container App configuration properties. */ + configuration?: Configuration; + /** Container App versioned application definition. */ + template?: Template; /** - * Boolean describing if the Revision is Active + * Outbound IP Addresses for container app. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly active?: boolean; + readonly outboundIPAddresses?: string[]; +} + +/** An environment for hosting container apps */ +export interface ManagedEnvironment extends TrackedResource { /** - * Number of pods currently running for this revision + * Provisioning state of the Environment. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly replicas?: number; + readonly provisioningState?: EnvironmentProvisioningState; + /** Azure Monitor instrumentation key used by Dapr to export Service to Service communication telemetry */ + daprAIInstrumentationKey?: string; + /** Application Insights connection string used by Dapr to export Service to Service communication telemetry */ + daprAIConnectionString?: string; + /** Vnet configuration for the environment */ + vnetConfiguration?: VnetConfiguration; /** - * Traffic weight assigned to this revision + * Any errors that occurred during deployment or deployment validation * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly trafficWeight?: number; + readonly deploymentErrors?: string; /** - * Optional Field - Platform Error Message + * Default Domain Name for the cluster * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly provisioningError?: string; + readonly defaultDomain?: string; /** - * Current health State of the revision + * Static IP of the Environment * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly healthState?: RevisionHealthState; + readonly staticIp?: string; /** - * Current provisioning State of the revision - * NOTE: This property will not be serialized. It can only be populated by the server. + * Cluster configuration which enables the log daemon to export + * app logs to a destination. Currently only "log-analytics" is + * supported */ - readonly provisioningState?: RevisionProvisioningState; -}; + appLogsConfiguration?: AppLogsConfiguration; + /** Whether or not this Managed Environment is zone-redundant. */ + zoneRedundant?: boolean; +} -/** Container App Revision Replica. */ -export type Replica = ProxyResource & { +/** Certificate used for Custom Domain bindings of Container Apps in a Managed Environment */ +export interface Certificate extends TrackedResource { + /** Certificate resource specific properties */ + properties?: CertificateProperties; +} + +/** 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. */ + extendedLocation?: ExtendedLocation; /** - * Timestamp describing when the pod was created by controller + * Provisioning state of the Kubernetes Environment. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly createdTime?: Date; - /** The containers collection under a replica. */ - containers?: ReplicaContainer[]; -}; - -/** Container App SourceControl. */ -export type SourceControl = ProxyResource & { + readonly provisioningState?: ConnectedEnvironmentProvisioningState; /** - * Current provisioning State of the operation + * Any errors that occurred during deployment or deployment validation * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly operationState?: SourceControlOperationState; - /** The repo url which will be integrated to ContainerApp. */ - repoUrl?: string; - /** The branch which will trigger the auto deployment */ - branch?: string; + readonly deploymentErrors?: string; /** - * Container App Revision Template with all possible settings and the - * defaults if user did not provide them. The defaults are populated - * as they were at the creation time + * Default Domain Name for the cluster + * NOTE: This property will not be serialized. It can only be populated by the server. */ - githubActionConfiguration?: GithubActionConfiguration; -}; + readonly defaultDomain?: string; + /** Static IP of the connectedEnvironment */ + staticIp?: string; + /** Application Insights connection string used by Dapr to export Service to Service communication telemetry */ + daprAIConnectionString?: string; +} -/** Dapr Component. */ -export type DaprComponent = ProxyResource & { - /** Component type */ - componentType?: string; - /** Component version */ - version?: string; - /** Boolean describing if the component errors are ignores */ - ignoreErrors?: boolean; - /** Initialization timeout */ - initTimeout?: string; - /** Collection of secrets used by a Dapr component */ - secrets?: Secret[]; - /** Component metadata */ - metadata?: DaprMetadata[]; - /** Names of container apps that can use this Dapr component */ - scopes?: string[]; -}; +/** Known values of {@link CreatedByType} that the service accepts. */ +export enum KnownCreatedByType { + /** User */ + User = "User", + /** Application */ + Application = "Application", + /** ManagedIdentity */ + ManagedIdentity = "ManagedIdentity", + /** Key */ + Key = "Key" +} -/** Configuration settings for the Azure ContainerApp Service Authentication / Authorization feature. */ -export type AuthConfig = ProxyResource & { - /** The configuration settings of the platform of ContainerApp Service Authentication/Authorization. */ - platform?: AuthPlatform; - /** The configuration settings that determines the validation flow of users using Service Authentication/Authorization. */ - globalValidation?: GlobalValidation; - /** The configuration settings of each of the identity providers used to configure ContainerApp Service Authentication/Authorization. */ - identityProviders?: IdentityProviders; - /** The configuration settings of the login flow of users using ContainerApp Service Authentication/Authorization. */ - login?: Login; - /** The configuration settings of the HTTP requests for authentication and authorization requests made against ContainerApp Service Authentication/Authorization. */ - httpSettings?: HttpSettings; -}; +/** + * Defines values for CreatedByType. \ + * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **User** \ + * **Application** \ + * **ManagedIdentity** \ + * **Key** + */ +export type CreatedByType = string; -/** Storage resource for managedEnvironment. */ -export type ManagedEnvironmentStorage = ProxyResource & { - /** Storage properties */ - properties?: ManagedEnvironmentStorageProperties; -}; +/** Known values of {@link ExtendedLocationTypes} that the service accepts. */ +export enum KnownExtendedLocationTypes { + /** CustomLocation */ + CustomLocation = "CustomLocation" +} + +/** + * Defines values for ExtendedLocationTypes. \ + * {@link KnownExtendedLocationTypes} can be used interchangeably with ExtendedLocationTypes, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **CustomLocation** + */ +export type ExtendedLocationTypes = 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" } @@ -1391,9 +1737,13 @@ export type ManagedServiceIdentityType = string; /** Known values of {@link ContainerAppProvisioningState} that the service accepts. */ export enum KnownContainerAppProvisioningState { + /** InProgress */ InProgress = "InProgress", + /** Succeeded */ Succeeded = "Succeeded", + /** Failed */ Failed = "Failed", + /** Canceled */ Canceled = "Canceled" } @@ -1411,8 +1761,10 @@ export type ContainerAppProvisioningState = string; /** Known values of {@link ActiveRevisionsMode} that the service accepts. */ export enum KnownActiveRevisionsMode { - Multiple = "multiple", - Single = "single" + /** Multiple */ + Multiple = "Multiple", + /** Single */ + Single = "Single" } /** @@ -1420,15 +1772,18 @@ export enum KnownActiveRevisionsMode { * {@link KnownActiveRevisionsMode} can be used interchangeably with ActiveRevisionsMode, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **multiple** \ - * **single** + * **Multiple** \ + * **Single** */ export type ActiveRevisionsMode = string; /** Known values of {@link IngressTransportMethod} that the service accepts. */ export enum KnownIngressTransportMethod { + /** Auto */ Auto = "auto", + /** Http */ Http = "http", + /** Http2 */ Http2 = "http2" } @@ -1445,7 +1800,9 @@ export type IngressTransportMethod = string; /** Known values of {@link BindingType} that the service accepts. */ export enum KnownBindingType { + /** Disabled */ Disabled = "Disabled", + /** SniEnabled */ SniEnabled = "SniEnabled" } @@ -1461,7 +1818,9 @@ export type BindingType = string; /** Known values of {@link AppProtocol} that the service accepts. */ export enum KnownAppProtocol { + /** Http */ Http = "http", + /** Grpc */ Grpc = "grpc" } @@ -1475,11 +1834,32 @@ export enum KnownAppProtocol { */ export type AppProtocol = string; +/** Known values of {@link Scheme} that the service accepts. */ +export enum KnownScheme { + /** Http */ + Http = "HTTP", + /** Https */ + Https = "HTTPS" +} + +/** + * Defines values for Scheme. \ + * {@link KnownScheme} can be used interchangeably with Scheme, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **HTTP** \ + * **HTTPS** + */ +export type Scheme = string; + /** Known values of {@link Type} that the service accepts. */ export enum KnownType { - Liveness = "liveness", - Readiness = "readiness", - Startup = "startup" + /** Liveness */ + Liveness = "Liveness", + /** Readiness */ + Readiness = "Readiness", + /** Startup */ + Startup = "Startup" } /** @@ -1487,15 +1867,17 @@ export enum KnownType { * {@link KnownType} can be used interchangeably with Type, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **liveness** \ - * **readiness** \ - * **startup** + * **Liveness** \ + * **Readiness** \ + * **Startup** */ export type Type = string; /** Known values of {@link StorageType} that the service accepts. */ export enum KnownStorageType { + /** AzureFile */ AzureFile = "AzureFile", + /** EmptyDir */ EmptyDir = "EmptyDir" } @@ -1509,30 +1891,13 @@ export enum KnownStorageType { */ export type StorageType = string; -/** Known values of {@link CreatedByType} that the service accepts. */ -export enum KnownCreatedByType { - User = "User", - Application = "Application", - ManagedIdentity = "ManagedIdentity", - Key = "Key" -} - -/** - * Defines values for CreatedByType. \ - * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **User** \ - * **Application** \ - * **ManagedIdentity** \ - * **Key** - */ -export type CreatedByType = string; - /** Known values of {@link RevisionHealthState} that the service accepts. */ export enum KnownRevisionHealthState { + /** Healthy */ Healthy = "Healthy", + /** Unhealthy */ Unhealthy = "Unhealthy", + /** None */ None = "None" } @@ -1549,10 +1914,15 @@ export type RevisionHealthState = string; /** Known values of {@link RevisionProvisioningState} that the service accepts. */ export enum KnownRevisionProvisioningState { + /** Provisioning */ Provisioning = "Provisioning", + /** Provisioned */ Provisioned = "Provisioned", + /** Failed */ Failed = "Failed", + /** Deprovisioning */ Deprovisioning = "Deprovisioning", + /** Deprovisioned */ Deprovisioned = "Deprovisioned" } @@ -1571,15 +1941,25 @@ export type RevisionProvisioningState = string; /** Known values of {@link EnvironmentProvisioningState} that the service accepts. */ export enum KnownEnvironmentProvisioningState { + /** Succeeded */ Succeeded = "Succeeded", + /** Failed */ Failed = "Failed", + /** Canceled */ Canceled = "Canceled", + /** Waiting */ Waiting = "Waiting", + /** InitializationInProgress */ InitializationInProgress = "InitializationInProgress", + /** InfrastructureSetupInProgress */ InfrastructureSetupInProgress = "InfrastructureSetupInProgress", + /** InfrastructureSetupComplete */ InfrastructureSetupComplete = "InfrastructureSetupComplete", + /** ScheduledForDelete */ ScheduledForDelete = "ScheduledForDelete", + /** UpgradeRequested */ UpgradeRequested = "UpgradeRequested", + /** UpgradeFailed */ UpgradeFailed = "UpgradeFailed" } @@ -1603,10 +1983,15 @@ export type EnvironmentProvisioningState = string; /** Known values of {@link CertificateProvisioningState} that the service accepts. */ export enum KnownCertificateProvisioningState { + /** Succeeded */ Succeeded = "Succeeded", + /** Failed */ Failed = "Failed", + /** Canceled */ Canceled = "Canceled", + /** DeleteFailed */ DeleteFailed = "DeleteFailed", + /** Pending */ Pending = "Pending" } @@ -1623,11 +2008,51 @@ export enum KnownCertificateProvisioningState { */ export type CertificateProvisioningState = string; +/** Known values of {@link CheckNameAvailabilityReason} that the service accepts. */ +export enum KnownCheckNameAvailabilityReason { + /** Invalid */ + Invalid = "Invalid", + /** AlreadyExists */ + AlreadyExists = "AlreadyExists" +} + +/** + * Defines values for CheckNameAvailabilityReason. \ + * {@link KnownCheckNameAvailabilityReason} can be used interchangeably with CheckNameAvailabilityReason, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Invalid** \ + * **AlreadyExists** + */ +export type CheckNameAvailabilityReason = string; + +/** Known values of {@link AccessMode} that the service accepts. */ +export enum KnownAccessMode { + /** ReadOnly */ + ReadOnly = "ReadOnly", + /** ReadWrite */ + ReadWrite = "ReadWrite" +} + +/** + * Defines values for AccessMode. \ + * {@link KnownAccessMode} can be used interchangeably with AccessMode, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **ReadOnly** \ + * **ReadWrite** + */ +export type AccessMode = string; + /** Known values of {@link SourceControlOperationState} that the service accepts. */ export enum KnownSourceControlOperationState { + /** InProgress */ InProgress = "InProgress", + /** Succeeded */ Succeeded = "Succeeded", + /** Failed */ Failed = "Failed", + /** Canceled */ Canceled = "Canceled" } @@ -1643,23 +2068,41 @@ export enum KnownSourceControlOperationState { */ export type SourceControlOperationState = string; -/** Known values of {@link AccessMode} that the service accepts. */ -export enum KnownAccessMode { - ReadOnly = "ReadOnly", - ReadWrite = "ReadWrite" +/** Known values of {@link ConnectedEnvironmentProvisioningState} that the service accepts. */ +export enum KnownConnectedEnvironmentProvisioningState { + /** Succeeded */ + Succeeded = "Succeeded", + /** Failed */ + Failed = "Failed", + /** Canceled */ + Canceled = "Canceled", + /** Waiting */ + Waiting = "Waiting", + /** InitializationInProgress */ + InitializationInProgress = "InitializationInProgress", + /** InfrastructureSetupInProgress */ + InfrastructureSetupInProgress = "InfrastructureSetupInProgress", + /** InfrastructureSetupComplete */ + InfrastructureSetupComplete = "InfrastructureSetupComplete", + /** ScheduledForDelete */ + ScheduledForDelete = "ScheduledForDelete" } /** - * Defines values for AccessMode. \ - * {@link KnownAccessMode} can be used interchangeably with AccessMode, + * Defines values for ConnectedEnvironmentProvisioningState. \ + * {@link KnownConnectedEnvironmentProvisioningState} can be used interchangeably with ConnectedEnvironmentProvisioningState, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **ReadOnly** \ - * **ReadWrite** + * **Succeeded** \ + * **Failed** \ + * **Canceled** \ + * **Waiting** \ + * **InitializationInProgress** \ + * **InfrastructureSetupInProgress** \ + * **InfrastructureSetupComplete** \ + * **ScheduledForDelete** */ -export type AccessMode = string; -/** Defines values for DnsVerificationTestResult. */ -export type DnsVerificationTestResult = "Passed" | "Failed" | "Skipped"; +export type ConnectedEnvironmentProvisioningState = string; /** Defines values for UnauthenticatedClientActionV2. */ export type UnauthenticatedClientActionV2 = | "RedirectToLoginPage" @@ -1672,6 +2115,40 @@ export type CookieExpirationConvention = | "IdentityProviderDerived"; /** Defines values for ForwardProxyConvention. */ export type ForwardProxyConvention = "NoProxy" | "Standard" | "Custom"; +/** Defines values for DnsVerificationTestResult. */ +export type DnsVerificationTestResult = "Passed" | "Failed" | "Skipped"; + +/** Optional parameters. */ +export interface ContainerAppsAuthConfigsListByContainerAppOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByContainerApp operation. */ +export type ContainerAppsAuthConfigsListByContainerAppResponse = AuthConfigCollection; + +/** Optional parameters. */ +export interface ContainerAppsAuthConfigsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type ContainerAppsAuthConfigsGetResponse = AuthConfig; + +/** Optional parameters. */ +export interface ContainerAppsAuthConfigsCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type ContainerAppsAuthConfigsCreateOrUpdateResponse = AuthConfig; + +/** Optional parameters. */ +export interface ContainerAppsAuthConfigsDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface ContainerAppsAuthConfigsListByContainerAppNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByContainerAppNext operation. */ +export type ContainerAppsAuthConfigsListByContainerAppNextResponse = AuthConfigCollection; /** Optional parameters. */ export interface ContainerAppsListBySubscriptionOptionalParams @@ -1717,10 +2194,12 @@ export interface ContainerAppsDeleteOptionalParams /** Optional parameters. */ export interface ContainerAppsUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the update operation. */ -export type ContainerAppsUpdateResponse = ContainerApp; + 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 ContainerAppsListCustomHostNameAnalysisOptionalParams @@ -1755,7 +2234,10 @@ export type ContainerAppsListByResourceGroupNextResponse = ContainerAppCollectio /** Optional parameters. */ export interface ContainerAppsRevisionsListRevisionsOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** The filter to apply on the operation. */ + filter?: string; +} /** Contains response data for the listRevisions operation. */ export type ContainerAppsRevisionsListRevisionsResponse = RevisionCollection; @@ -1781,7 +2263,10 @@ export interface ContainerAppsRevisionsRestartRevisionOptionalParams /** Optional parameters. */ export interface ContainerAppsRevisionsListRevisionsNextOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** The filter to apply on the operation. */ + filter?: string; +} /** Contains response data for the listRevisionsNext operation. */ export type ContainerAppsRevisionsListRevisionsNextResponse = RevisionCollection; @@ -1800,6 +2285,135 @@ export interface ContainerAppsRevisionReplicasListReplicasOptionalParams /** Contains response data for the listReplicas operation. */ export type ContainerAppsRevisionReplicasListReplicasResponse = ReplicaCollection; +/** Optional parameters. */ +export interface DaprComponentsListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type DaprComponentsListResponse = DaprComponentsCollection; + +/** Optional parameters. */ +export interface DaprComponentsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type DaprComponentsGetResponse = DaprComponent; + +/** Optional parameters. */ +export interface DaprComponentsCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type DaprComponentsCreateOrUpdateResponse = DaprComponent; + +/** Optional parameters. */ +export interface DaprComponentsDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface DaprComponentsListSecretsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listSecrets operation. */ +export type DaprComponentsListSecretsResponse = DaprSecretsCollection; + +/** Optional parameters. */ +export interface DaprComponentsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type DaprComponentsListNextResponse = DaprComponentsCollection; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsListDetectorsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listDetectors operation. */ +export type ContainerAppsDiagnosticsListDetectorsResponse = DiagnosticsCollection; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsGetDetectorOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDetector operation. */ +export type ContainerAppsDiagnosticsGetDetectorResponse = Diagnostics; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsListRevisionsOptionalParams + extends coreClient.OperationOptions { + /** The filter to apply on the operation. */ + filter?: string; +} + +/** Contains response data for the listRevisions operation. */ +export type ContainerAppsDiagnosticsListRevisionsResponse = RevisionCollection; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsGetRevisionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getRevision operation. */ +export type ContainerAppsDiagnosticsGetRevisionResponse = Revision; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsGetRootOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getRoot operation. */ +export type ContainerAppsDiagnosticsGetRootResponse = ContainerApp; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsListDetectorsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listDetectorsNext operation. */ +export type ContainerAppsDiagnosticsListDetectorsNextResponse = DiagnosticsCollection; + +/** Optional parameters. */ +export interface ContainerAppsDiagnosticsListRevisionsNextOptionalParams + extends coreClient.OperationOptions { + /** The filter to apply on the operation. */ + filter?: string; +} + +/** Contains response data for the listRevisionsNext operation. */ +export type ContainerAppsDiagnosticsListRevisionsNextResponse = RevisionCollection; + +/** Optional parameters. */ +export interface ManagedEnvironmentDiagnosticsListDetectorsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listDetectors operation. */ +export type ManagedEnvironmentDiagnosticsListDetectorsResponse = DiagnosticsCollection; + +/** Optional parameters. */ +export interface ManagedEnvironmentDiagnosticsGetDetectorOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getDetector operation. */ +export type ManagedEnvironmentDiagnosticsGetDetectorResponse = Diagnostics; + +/** Optional parameters. */ +export interface ManagedEnvironmentsDiagnosticsGetRootOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getRoot operation. */ +export type ManagedEnvironmentsDiagnosticsGetRootResponse = ManagedEnvironment; + +/** Optional parameters. */ +export interface OperationsListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type OperationsListResponse = AvailableOperations; + +/** Optional parameters. */ +export interface OperationsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type OperationsListNextResponse = AvailableOperations; + /** Optional parameters. */ export interface ManagedEnvironmentsListBySubscriptionOptionalParams extends coreClient.OperationOptions {} @@ -1844,10 +2458,12 @@ export interface ManagedEnvironmentsDeleteOptionalParams /** Optional parameters. */ export interface ManagedEnvironmentsUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the update operation. */ -export type ManagedEnvironmentsUpdateResponse = ManagedEnvironment; + 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 ManagedEnvironmentsListBySubscriptionNextOptionalParams @@ -1906,18 +2522,36 @@ export interface CertificatesListNextOptionalParams export type CertificatesListNextResponse = CertificateCollection; /** Optional parameters. */ -export interface OperationsListOptionalParams +export interface NamespacesCheckNameAvailabilityOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the checkNameAvailability operation. */ +export type NamespacesCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; + +/** Optional parameters. */ +export interface ManagedEnvironmentsStoragesListOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the list operation. */ -export type OperationsListResponse = AvailableOperations; +export type ManagedEnvironmentsStoragesListResponse = ManagedEnvironmentStoragesCollection; /** Optional parameters. */ -export interface OperationsListNextOptionalParams +export interface ManagedEnvironmentsStoragesGetOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listNext operation. */ -export type OperationsListNextResponse = AvailableOperations; +/** Contains response data for the get operation. */ +export type ManagedEnvironmentsStoragesGetResponse = ManagedEnvironmentStorage; + +/** Optional parameters. */ +export interface ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type ManagedEnvironmentsStoragesCreateOrUpdateResponse = ManagedEnvironmentStorage; + +/** Optional parameters. */ +export interface ManagedEnvironmentsStoragesDeleteOptionalParams + extends coreClient.OperationOptions {} /** Optional parameters. */ export interface ContainerAppsSourceControlsListByContainerAppOptionalParams @@ -1962,92 +2596,179 @@ export interface ContainerAppsSourceControlsListByContainerAppNextOptionalParams export type ContainerAppsSourceControlsListByContainerAppNextResponse = SourceControlCollection; /** Optional parameters. */ -export interface DaprComponentsListOptionalParams +export interface ConnectedEnvironmentsListBySubscriptionOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the list operation. */ -export type DaprComponentsListResponse = DaprComponentsCollection; +/** Contains response data for the listBySubscription operation. */ +export type ConnectedEnvironmentsListBySubscriptionResponse = ConnectedEnvironmentCollection; /** Optional parameters. */ -export interface DaprComponentsGetOptionalParams +export interface ConnectedEnvironmentsListByResourceGroupOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByResourceGroup operation. */ +export type ConnectedEnvironmentsListByResourceGroupResponse = ConnectedEnvironmentCollection; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type DaprComponentsGetResponse = DaprComponent; +export type ConnectedEnvironmentsGetResponse = ConnectedEnvironment; /** Optional parameters. */ -export interface DaprComponentsCreateOrUpdateOptionalParams +export interface ConnectedEnvironmentsCreateOrUpdateOptionalParams + 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 ConnectedEnvironmentsCreateOrUpdateResponse = ConnectedEnvironment; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsDeleteOptionalParams + 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 ConnectedEnvironmentsUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the update operation. */ +export type ConnectedEnvironmentsUpdateResponse = ConnectedEnvironment; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsCheckNameAvailabilityOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the checkNameAvailability operation. */ +export type ConnectedEnvironmentsCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsListBySubscriptionNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySubscriptionNext operation. */ +export type ConnectedEnvironmentsListBySubscriptionNextResponse = ConnectedEnvironmentCollection; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsListByResourceGroupNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByResourceGroupNext operation. */ +export type ConnectedEnvironmentsListByResourceGroupNextResponse = ConnectedEnvironmentCollection; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsCertificatesListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type ConnectedEnvironmentsCertificatesListResponse = CertificateCollection; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsCertificatesGetOptionalParams extends coreClient.OperationOptions {} +/** Contains response data for the get operation. */ +export type ConnectedEnvironmentsCertificatesGetResponse = Certificate; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions { + /** Certificate to be created or updated */ + certificateEnvelope?: Certificate; +} + /** Contains response data for the createOrUpdate operation. */ -export type DaprComponentsCreateOrUpdateResponse = DaprComponent; +export type ConnectedEnvironmentsCertificatesCreateOrUpdateResponse = Certificate; /** Optional parameters. */ -export interface DaprComponentsDeleteOptionalParams +export interface ConnectedEnvironmentsCertificatesDeleteOptionalParams extends coreClient.OperationOptions {} /** Optional parameters. */ -export interface DaprComponentsListNextOptionalParams +export interface ConnectedEnvironmentsCertificatesUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the update operation. */ +export type ConnectedEnvironmentsCertificatesUpdateResponse = Certificate; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsCertificatesListNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ -export type DaprComponentsListNextResponse = DaprComponentsCollection; +export type ConnectedEnvironmentsCertificatesListNextResponse = CertificateCollection; /** Optional parameters. */ -export interface ContainerAppsAuthConfigsListByContainerAppOptionalParams +export interface ConnectedEnvironmentsDaprComponentsListOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listByContainerApp operation. */ -export type ContainerAppsAuthConfigsListByContainerAppResponse = AuthConfigCollection; +/** Contains response data for the list operation. */ +export type ConnectedEnvironmentsDaprComponentsListResponse = DaprComponentsCollection; /** Optional parameters. */ -export interface ContainerAppsAuthConfigsGetOptionalParams +export interface ConnectedEnvironmentsDaprComponentsGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type ContainerAppsAuthConfigsGetResponse = AuthConfig; +export type ConnectedEnvironmentsDaprComponentsGetResponse = DaprComponent; /** Optional parameters. */ -export interface ContainerAppsAuthConfigsCreateOrUpdateOptionalParams +export interface ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdate operation. */ -export type ContainerAppsAuthConfigsCreateOrUpdateResponse = AuthConfig; +export type ConnectedEnvironmentsDaprComponentsCreateOrUpdateResponse = DaprComponent; /** Optional parameters. */ -export interface ContainerAppsAuthConfigsDeleteOptionalParams +export interface ConnectedEnvironmentsDaprComponentsDeleteOptionalParams extends coreClient.OperationOptions {} /** Optional parameters. */ -export interface ContainerAppsAuthConfigsListByContainerAppNextOptionalParams +export interface ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listByContainerAppNext operation. */ -export type ContainerAppsAuthConfigsListByContainerAppNextResponse = AuthConfigCollection; +/** Contains response data for the listSecrets operation. */ +export type ConnectedEnvironmentsDaprComponentsListSecretsResponse = DaprSecretsCollection; /** Optional parameters. */ -export interface ManagedEnvironmentsStoragesListOptionalParams +export interface ConnectedEnvironmentsDaprComponentsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type ConnectedEnvironmentsDaprComponentsListNextResponse = DaprComponentsCollection; + +/** Optional parameters. */ +export interface ConnectedEnvironmentsStoragesListOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the list operation. */ -export type ManagedEnvironmentsStoragesListResponse = ManagedEnvironmentStoragesCollection; +export type ConnectedEnvironmentsStoragesListResponse = ConnectedEnvironmentStoragesCollection; /** Optional parameters. */ -export interface ManagedEnvironmentsStoragesGetOptionalParams +export interface ConnectedEnvironmentsStoragesGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type ManagedEnvironmentsStoragesGetResponse = ManagedEnvironmentStorage; +export type ConnectedEnvironmentsStoragesGetResponse = ConnectedEnvironmentStorage; /** Optional parameters. */ -export interface ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams +export interface ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdate operation. */ -export type ManagedEnvironmentsStoragesCreateOrUpdateResponse = ManagedEnvironmentStorage; +export type ConnectedEnvironmentsStoragesCreateOrUpdateResponse = ConnectedEnvironmentStorage; /** Optional parameters. */ -export interface ManagedEnvironmentsStoragesDeleteOptionalParams +export interface ConnectedEnvironmentsStoragesDeleteOptionalParams extends coreClient.OperationOptions {} /** Optional parameters. */ diff --git a/sdk/app/arm-app/src/models/mappers.ts b/sdk/app/arm-app/src/models/mappers.ts index 59fdb769f365..eb303bbb0290 100644 --- a/sdk/app/arm-app/src/models/mappers.ts +++ b/sdk/app/arm-app/src/models/mappers.ts @@ -8,10 +8,10 @@ import * as coreClient from "@azure/core-client"; -export const ContainerAppCollection: coreClient.CompositeMapper = { +export const AuthConfigCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppCollection", + className: "AuthConfigCollection", modelProperties: { value: { serializedName: "value", @@ -21,7 +21,7 @@ export const ContainerAppCollection: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ContainerApp" + className: "AuthConfig" } } } @@ -37,199 +37,240 @@ export const ContainerAppCollection: coreClient.CompositeMapper = { } }; -export const ManagedServiceIdentity: coreClient.CompositeMapper = { +export const AuthPlatform: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedServiceIdentity", + className: "AuthPlatform", modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, - type: { - name: "Uuid" - } - }, - tenantId: { - serializedName: "tenantId", - readOnly: true, + enabled: { + serializedName: "enabled", type: { - name: "Uuid" + name: "Boolean" } }, - type: { - serializedName: "type", - required: true, + runtimeVersion: { + serializedName: "runtimeVersion", type: { name: "String" } - }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", - type: { - name: "Dictionary", - value: { - type: { name: "Composite", className: "UserAssignedIdentity" } - } - } } } } }; -export const UserAssignedIdentity: coreClient.CompositeMapper = { +export const GlobalValidation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "UserAssignedIdentity", + className: "GlobalValidation", modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, + unauthenticatedClientAction: { + serializedName: "unauthenticatedClientAction", type: { - name: "Uuid" + name: "Enum", + allowedValues: [ + "RedirectToLoginPage", + "AllowAnonymous", + "Return401", + "Return403" + ] } }, - clientId: { - serializedName: "clientId", - readOnly: true, + redirectToProvider: { + serializedName: "redirectToProvider", type: { - name: "Uuid" + name: "String" + } + }, + excludedPaths: { + serializedName: "excludedPaths", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } } } } } }; -export const Configuration: coreClient.CompositeMapper = { +export const IdentityProviders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Configuration", + className: "IdentityProviders", modelProperties: { - secrets: { - serializedName: "secrets", + azureActiveDirectory: { + serializedName: "azureActiveDirectory", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Secret" - } - } + name: "Composite", + className: "AzureActiveDirectory" } }, - activeRevisionsMode: { - serializedName: "activeRevisionsMode", + facebook: { + serializedName: "facebook", type: { - name: "String" + name: "Composite", + className: "Facebook" } }, - ingress: { - serializedName: "ingress", + gitHub: { + serializedName: "gitHub", type: { name: "Composite", - className: "Ingress" + className: "GitHub" } }, - registries: { - serializedName: "registries", + google: { + serializedName: "google", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "RegistryCredentials" - } - } + name: "Composite", + className: "Google" } }, - dapr: { - serializedName: "dapr", + twitter: { + serializedName: "twitter", type: { name: "Composite", - className: "Dapr" + className: "Twitter" + } + }, + apple: { + serializedName: "apple", + type: { + name: "Composite", + className: "Apple" + } + }, + azureStaticWebApps: { + serializedName: "azureStaticWebApps", + type: { + name: "Composite", + className: "AzureStaticWebApps" + } + }, + customOpenIdConnectProviders: { + serializedName: "customOpenIdConnectProviders", + type: { + name: "Dictionary", + value: { + type: { + name: "Composite", + className: "CustomOpenIdConnectProvider" + } + } } } } } }; -export const Secret: coreClient.CompositeMapper = { +export const AzureActiveDirectory: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Secret", + className: "AzureActiveDirectory", modelProperties: { - name: { - serializedName: "name", + enabled: { + serializedName: "enabled", type: { - name: "String" + name: "Boolean" } }, - value: { - serializedName: "value", + registration: { + serializedName: "registration", type: { - name: "String" + name: "Composite", + className: "AzureActiveDirectoryRegistration" + } + }, + login: { + serializedName: "login", + type: { + name: "Composite", + className: "AzureActiveDirectoryLogin" + } + }, + validation: { + serializedName: "validation", + type: { + name: "Composite", + className: "AzureActiveDirectoryValidation" + } + }, + isAutoProvisioned: { + serializedName: "isAutoProvisioned", + type: { + name: "Boolean" } } } } }; -export const Ingress: coreClient.CompositeMapper = { +export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Ingress", + className: "AzureActiveDirectoryRegistration", modelProperties: { - fqdn: { - serializedName: "fqdn", - readOnly: true, + openIdIssuer: { + serializedName: "openIdIssuer", type: { name: "String" } }, - external: { - defaultValue: false, - serializedName: "external", + clientId: { + serializedName: "clientId", type: { - name: "Boolean" + name: "String" } }, - targetPort: { - serializedName: "targetPort", + clientSecretSettingName: { + serializedName: "clientSecretSettingName", type: { - name: "Number" + name: "String" } }, - transport: { - serializedName: "transport", + clientSecretCertificateThumbprint: { + serializedName: "clientSecretCertificateThumbprint", type: { name: "String" } }, - traffic: { - serializedName: "traffic", + clientSecretCertificateSubjectAlternativeName: { + serializedName: "clientSecretCertificateSubjectAlternativeName", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "TrafficWeight" - } - } + name: "String" } }, - customDomains: { - serializedName: "customDomains", + clientSecretCertificateIssuer: { + serializedName: "clientSecretCertificateIssuer", + type: { + name: "String" + } + } + } + } +}; + +export const AzureActiveDirectoryLogin: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AzureActiveDirectoryLogin", + modelProperties: { + loginParameters: { + serializedName: "loginParameters", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "CustomDomain" + name: "String" } } } }, - allowInsecure: { - serializedName: "allowInsecure", + disableWWWAuthenticate: { + serializedName: "disableWWWAuthenticate", type: { name: "Boolean" } @@ -238,55 +279,641 @@ export const Ingress: coreClient.CompositeMapper = { } }; -export const TrafficWeight: coreClient.CompositeMapper = { +export const AzureActiveDirectoryValidation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TrafficWeight", + className: "AzureActiveDirectoryValidation", modelProperties: { - revisionName: { - serializedName: "revisionName", - type: { + jwtClaimChecks: { + serializedName: "jwtClaimChecks", + type: { + name: "Composite", + className: "JwtClaimChecks" + } + }, + allowedAudiences: { + serializedName: "allowedAudiences", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + defaultAuthorizationPolicy: { + serializedName: "defaultAuthorizationPolicy", + type: { + name: "Composite", + className: "DefaultAuthorizationPolicy" + } + } + } + } +}; + +export const JwtClaimChecks: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "JwtClaimChecks", + modelProperties: { + allowedGroups: { + serializedName: "allowedGroups", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + allowedClientApplications: { + serializedName: "allowedClientApplications", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const DefaultAuthorizationPolicy: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DefaultAuthorizationPolicy", + modelProperties: { + allowedPrincipals: { + serializedName: "allowedPrincipals", + type: { + name: "Composite", + className: "AllowedPrincipals" + } + }, + allowedApplications: { + serializedName: "allowedApplications", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const AllowedPrincipals: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AllowedPrincipals", + modelProperties: { + groups: { + serializedName: "groups", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + identities: { + serializedName: "identities", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const Facebook: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Facebook", + modelProperties: { + enabled: { + serializedName: "enabled", + type: { + name: "Boolean" + } + }, + registration: { + serializedName: "registration", + type: { + name: "Composite", + className: "AppRegistration" + } + }, + graphApiVersion: { + serializedName: "graphApiVersion", + type: { + name: "String" + } + }, + login: { + serializedName: "login", + type: { + name: "Composite", + className: "LoginScopes" + } + } + } + } +}; + +export const AppRegistration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AppRegistration", + modelProperties: { + appId: { + serializedName: "appId", + type: { + name: "String" + } + }, + appSecretSettingName: { + serializedName: "appSecretSettingName", + type: { + name: "String" + } + } + } + } +}; + +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 = { + type: { + name: "Composite", + className: "GitHub", + modelProperties: { + enabled: { + serializedName: "enabled", + type: { + name: "Boolean" + } + }, + registration: { + serializedName: "registration", + type: { + name: "Composite", + className: "ClientRegistration" + } + }, + login: { + serializedName: "login", + type: { + name: "Composite", + className: "LoginScopes" + } + } + } + } +}; + +export const ClientRegistration: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ClientRegistration", + modelProperties: { + clientId: { + serializedName: "clientId", + type: { + name: "String" + } + }, + clientSecretSettingName: { + serializedName: "clientSecretSettingName", + type: { + name: "String" + } + } + } + } +}; + +export const Google: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Google", + modelProperties: { + enabled: { + serializedName: "enabled", + type: { + name: "Boolean" + } + }, + registration: { + serializedName: "registration", + type: { + name: "Composite", + className: "ClientRegistration" + } + }, + login: { + serializedName: "login", + type: { + name: "Composite", + className: "LoginScopes" + } + }, + validation: { + serializedName: "validation", + type: { + name: "Composite", + className: "AllowedAudiencesValidation" + } + } + } + } +}; + +export const AllowedAudiencesValidation: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AllowedAudiencesValidation", + modelProperties: { + allowedAudiences: { + serializedName: "allowedAudiences", + 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" } }, - weight: { - serializedName: "weight", + clientSecretSettingName: { + serializedName: "clientSecretSettingName", type: { - name: "Number" + name: "String" + } + } + } + } +}; + +export const AzureStaticWebApps: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AzureStaticWebApps", + modelProperties: { + enabled: { + serializedName: "enabled", + type: { + name: "Boolean" } }, - latestRevision: { - defaultValue: false, - serializedName: "latestRevision", + 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 CustomDomain: coreClient.CompositeMapper = { +export const OpenIdConnectRegistration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomDomain", + className: "OpenIdConnectRegistration", modelProperties: { - name: { - serializedName: "name", - required: true, + clientId: { + serializedName: "clientId", type: { name: "String" } }, - bindingType: { - serializedName: "bindingType", + clientCredential: { + serializedName: "clientCredential", + type: { + name: "Composite", + className: "OpenIdConnectClientCredential" + } + }, + openIdConnectConfiguration: { + serializedName: "openIdConnectConfiguration", + type: { + name: "Composite", + className: "OpenIdConnectConfig" + } + } + } + } +}; + +export const OpenIdConnectClientCredential: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OpenIdConnectClientCredential", + modelProperties: { + method: { + defaultValue: "ClientSecretPost", + isConstant: true, + serializedName: "method", type: { name: "String" } }, - certificateId: { - serializedName: "certificateId", - required: true, + clientSecretSettingName: { + serializedName: "clientSecretSettingName", + type: { + name: "String" + } + } + } + } +}; + +export const OpenIdConnectConfig: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OpenIdConnectConfig", + modelProperties: { + authorizationEndpoint: { + serializedName: "authorizationEndpoint", + type: { + name: "String" + } + }, + tokenEndpoint: { + serializedName: "tokenEndpoint", + type: { + name: "String" + } + }, + issuer: { + serializedName: "issuer", + type: { + name: "String" + } + }, + certificationUri: { + serializedName: "certificationUri", + type: { + name: "String" + } + }, + wellKnownOpenIdConfiguration: { + serializedName: "wellKnownOpenIdConfiguration", + type: { + name: "String" + } + } + } + } +}; + +export const OpenIdConnectLogin: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OpenIdConnectLogin", + modelProperties: { + nameClaimType: { + serializedName: "nameClaimType", + type: { + name: "String" + } + }, + scopes: { + serializedName: "scopes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const Login: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Login", + modelProperties: { + routes: { + serializedName: "routes", + type: { + name: "Composite", + className: "LoginRoutes" + } + }, + preserveUrlFragmentsForLogins: { + serializedName: "preserveUrlFragmentsForLogins", + type: { + name: "Boolean" + } + }, + allowedExternalRedirectUrls: { + serializedName: "allowedExternalRedirectUrls", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + cookieExpiration: { + serializedName: "cookieExpiration", + type: { + name: "Composite", + className: "CookieExpiration" + } + }, + nonce: { + serializedName: "nonce", + type: { + name: "Composite", + className: "Nonce" + } + } + } + } +}; + +export const LoginRoutes: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "LoginRoutes", + modelProperties: { + logoutEndpoint: { + serializedName: "logoutEndpoint", type: { name: "String" } @@ -295,25 +922,20 @@ export const CustomDomain: coreClient.CompositeMapper = { } }; -export const RegistryCredentials: coreClient.CompositeMapper = { +export const CookieExpiration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RegistryCredentials", + className: "CookieExpiration", modelProperties: { - server: { - serializedName: "server", - type: { - name: "String" - } - }, - username: { - serializedName: "username", + convention: { + serializedName: "convention", type: { - name: "String" + name: "Enum", + allowedValues: ["FixedTime", "IdentityProviderDerived"] } }, - passwordSecretRef: { - serializedName: "passwordSecretRef", + timeToExpiration: { + serializedName: "timeToExpiration", type: { name: "String" } @@ -322,190 +944,91 @@ export const RegistryCredentials: coreClient.CompositeMapper = { } }; -export const Dapr: coreClient.CompositeMapper = { +export const Nonce: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Dapr", + className: "Nonce", modelProperties: { - enabled: { - serializedName: "enabled", + validateNonce: { + serializedName: "validateNonce", type: { name: "Boolean" } }, - appId: { - serializedName: "appId", - type: { - name: "String" - } - }, - appProtocol: { - serializedName: "appProtocol", + nonceExpirationInterval: { + serializedName: "nonceExpirationInterval", type: { name: "String" } - }, - appPort: { - serializedName: "appPort", - type: { - name: "Number" - } } } } }; -export const Template: coreClient.CompositeMapper = { +export const HttpSettings: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Template", + className: "HttpSettings", modelProperties: { - revisionSuffix: { - serializedName: "revisionSuffix", - type: { - name: "String" - } - }, - containers: { - serializedName: "containers", + requireHttps: { + serializedName: "requireHttps", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Container" - } - } + name: "Boolean" } }, - scale: { - serializedName: "scale", + routes: { + serializedName: "routes", type: { name: "Composite", - className: "Scale" + className: "HttpSettingsRoutes" } }, - volumes: { - serializedName: "volumes", + forwardProxy: { + serializedName: "forwardProxy", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Volume" - } - } + name: "Composite", + className: "ForwardProxy" } } } } }; -export const Container: coreClient.CompositeMapper = { +export const HttpSettingsRoutes: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Container", + className: "HttpSettingsRoutes", modelProperties: { - image: { - serializedName: "image", - type: { - name: "String" - } - }, - name: { - serializedName: "name", + apiPrefix: { + serializedName: "apiPrefix", type: { name: "String" } - }, - command: { - serializedName: "command", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - args: { - serializedName: "args", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - env: { - serializedName: "env", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "EnvironmentVar" - } - } - } - }, - resources: { - serializedName: "resources", - type: { - name: "Composite", - className: "ContainerResources" - } - }, - probes: { - serializedName: "probes", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppProbe" - } - } - } - }, - volumeMounts: { - serializedName: "volumeMounts", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "VolumeMount" - } - } - } } } } }; -export const EnvironmentVar: coreClient.CompositeMapper = { +export const ForwardProxy: coreClient.CompositeMapper = { type: { name: "Composite", - className: "EnvironmentVar", + className: "ForwardProxy", modelProperties: { - name: { - serializedName: "name", + convention: { + serializedName: "convention", type: { - name: "String" + name: "Enum", + allowedValues: ["NoProxy", "Standard", "Custom"] } }, - value: { - serializedName: "value", + customHostHeaderName: { + serializedName: "customHostHeaderName", type: { name: "String" } }, - secretRef: { - serializedName: "secretRef", + customProtoHeaderName: { + serializedName: "customProtoHeaderName", type: { name: "String" } @@ -514,137 +1037,145 @@ export const EnvironmentVar: coreClient.CompositeMapper = { } }; -export const ContainerResources: coreClient.CompositeMapper = { +export const Resource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerResources", + className: "Resource", modelProperties: { - cpu: { - serializedName: "cpu", + id: { + serializedName: "id", + readOnly: true, type: { - name: "Number" + name: "String" } }, - memory: { - serializedName: "memory", + name: { + serializedName: "name", + readOnly: true, type: { name: "String" } }, - ephemeralStorage: { - serializedName: "ephemeralStorage", + type: { + serializedName: "type", readOnly: true, type: { name: "String" } + }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } } } } }; -export const ContainerAppProbe: coreClient.CompositeMapper = { +export const SystemData: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppProbe", + className: "SystemData", modelProperties: { - failureThreshold: { - serializedName: "failureThreshold", - type: { - name: "Number" - } - }, - httpGet: { - serializedName: "httpGet", - type: { - name: "Composite", - className: "ContainerAppProbeHttpGet" - } - }, - initialDelaySeconds: { - serializedName: "initialDelaySeconds", - type: { - name: "Number" - } - }, - periodSeconds: { - serializedName: "periodSeconds", + createdBy: { + serializedName: "createdBy", type: { - name: "Number" + name: "String" } }, - successThreshold: { - serializedName: "successThreshold", + createdByType: { + serializedName: "createdByType", type: { - name: "Number" + name: "String" } }, - tcpSocket: { - serializedName: "tcpSocket", + createdAt: { + serializedName: "createdAt", type: { - name: "Composite", - className: "ContainerAppProbeTcpSocket" + name: "DateTime" } }, - terminationGracePeriodSeconds: { - serializedName: "terminationGracePeriodSeconds", + lastModifiedBy: { + serializedName: "lastModifiedBy", type: { - name: "Number" + name: "String" } }, - timeoutSeconds: { - serializedName: "timeoutSeconds", + lastModifiedByType: { + serializedName: "lastModifiedByType", type: { - name: "Number" + name: "String" } }, - type: { - serializedName: "type", + lastModifiedAt: { + serializedName: "lastModifiedAt", type: { - name: "String" + name: "DateTime" } } } } }; -export const ContainerAppProbeHttpGet: coreClient.CompositeMapper = { +export const DefaultErrorResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppProbeHttpGet", + className: "DefaultErrorResponse", modelProperties: { - host: { - serializedName: "host", + error: { + serializedName: "error", + type: { + name: "Composite", + className: "DefaultErrorResponseError" + } + } + } + } +}; + +export const DefaultErrorResponseError: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DefaultErrorResponseError", + modelProperties: { + code: { + serializedName: "code", + readOnly: true, type: { name: "String" } }, - httpHeaders: { - serializedName: "httpHeaders", + message: { + serializedName: "message", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppProbeHttpGetHttpHeadersItem" - } - } + name: "String" } }, - path: { - serializedName: "path", + target: { + serializedName: "target", + readOnly: true, type: { name: "String" } }, - port: { - serializedName: "port", - required: true, + details: { + serializedName: "details", type: { - name: "Number" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DefaultErrorResponseErrorDetailsItem" + } + } } }, - scheme: { - serializedName: "scheme", + innererror: { + serializedName: "innererror", + readOnly: true, type: { name: "String" } @@ -653,21 +1184,28 @@ export const ContainerAppProbeHttpGet: coreClient.CompositeMapper = { } }; -export const ContainerAppProbeHttpGetHttpHeadersItem: coreClient.CompositeMapper = { +export const DefaultErrorResponseErrorDetailsItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppProbeHttpGetHttpHeadersItem", + className: "DefaultErrorResponseErrorDetailsItem", 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" } @@ -676,41 +1214,48 @@ export const ContainerAppProbeHttpGetHttpHeadersItem: coreClient.CompositeMapper } }; -export const ContainerAppProbeTcpSocket: coreClient.CompositeMapper = { +export const ContainerAppCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerAppProbeTcpSocket", + className: "ContainerAppCollection", modelProperties: { - host: { - serializedName: "host", + value: { + serializedName: "value", + required: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ContainerApp" + } + } } }, - port: { - serializedName: "port", - required: true, + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Number" + name: "String" } } } } }; -export const VolumeMount: coreClient.CompositeMapper = { +export const ExtendedLocation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "VolumeMount", + className: "ExtendedLocation", modelProperties: { - volumeName: { - serializedName: "volumeName", + name: { + serializedName: "name", type: { name: "String" } }, - mountPath: { - serializedName: "mountPath", + type: { + serializedName: "type", type: { name: "String" } @@ -719,32 +1264,38 @@ export const VolumeMount: coreClient.CompositeMapper = { } }; -export const Scale: coreClient.CompositeMapper = { +export const ManagedServiceIdentity: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Scale", + className: "ManagedServiceIdentity", modelProperties: { - minReplicas: { - serializedName: "minReplicas", + principalId: { + serializedName: "principalId", + readOnly: true, type: { - name: "Number" + name: "Uuid" } }, - maxReplicas: { - serializedName: "maxReplicas", + tenantId: { + serializedName: "tenantId", + readOnly: true, type: { - name: "Number" + name: "Uuid" } }, - rules: { - serializedName: "rules", + type: { + serializedName: "type", + required: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRule" - } + name: "String" + } + }, + userAssignedIdentities: { + serializedName: "userAssignedIdentities", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "UserAssignedIdentity" } } } } @@ -752,88 +1303,95 @@ export const Scale: coreClient.CompositeMapper = { } }; -export const ScaleRule: coreClient.CompositeMapper = { +export const UserAssignedIdentity: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ScaleRule", + className: "UserAssignedIdentity", modelProperties: { - name: { - serializedName: "name", - type: { - name: "String" - } - }, - azureQueue: { - serializedName: "azureQueue", - type: { - name: "Composite", - className: "QueueScaleRule" - } - }, - custom: { - serializedName: "custom", + principalId: { + serializedName: "principalId", + readOnly: true, type: { - name: "Composite", - className: "CustomScaleRule" + name: "Uuid" } }, - http: { - serializedName: "http", + clientId: { + serializedName: "clientId", + readOnly: true, type: { - name: "Composite", - className: "HttpScaleRule" + name: "Uuid" } } } } }; -export const QueueScaleRule: coreClient.CompositeMapper = { +export const Configuration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "QueueScaleRule", + className: "Configuration", modelProperties: { - queueName: { - serializedName: "queueName", + secrets: { + serializedName: "secrets", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Secret" + } + } + } + }, + activeRevisionsMode: { + serializedName: "activeRevisionsMode", type: { name: "String" } }, - queueLength: { - serializedName: "queueLength", + ingress: { + serializedName: "ingress", type: { - name: "Number" + name: "Composite", + className: "Ingress" } }, - auth: { - serializedName: "auth", + registries: { + serializedName: "registries", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ScaleRuleAuth" + className: "RegistryCredentials" } } } + }, + dapr: { + serializedName: "dapr", + type: { + name: "Composite", + className: "Dapr" + } } } } }; -export const ScaleRuleAuth: coreClient.CompositeMapper = { +export const Secret: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ScaleRuleAuth", + className: "Secret", modelProperties: { - secretRef: { - serializedName: "secretRef", + name: { + serializedName: "name", type: { name: "String" } }, - triggerParameter: { - serializedName: "triggerParameter", + value: { + serializedName: "value", type: { name: "String" } @@ -842,87 +1400,126 @@ export const ScaleRuleAuth: coreClient.CompositeMapper = { } }; -export const CustomScaleRule: coreClient.CompositeMapper = { +export const Ingress: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomScaleRule", + className: "Ingress", modelProperties: { - type: { - serializedName: "type", + fqdn: { + serializedName: "fqdn", + readOnly: true, type: { name: "String" } }, - metadata: { - serializedName: "metadata", + external: { + defaultValue: false, + serializedName: "external", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "Boolean" } }, - auth: { - serializedName: "auth", + targetPort: { + serializedName: "targetPort", + type: { + name: "Number" + } + }, + transport: { + serializedName: "transport", + type: { + name: "String" + } + }, + traffic: { + serializedName: "traffic", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ScaleRuleAuth" + className: "TrafficWeight" + } + } + } + }, + customDomains: { + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "CustomDomain" } } } + }, + allowInsecure: { + serializedName: "allowInsecure", + type: { + name: "Boolean" + } } } } }; -export const HttpScaleRule: coreClient.CompositeMapper = { +export const TrafficWeight: coreClient.CompositeMapper = { type: { name: "Composite", - className: "HttpScaleRule", + className: "TrafficWeight", modelProperties: { - metadata: { - serializedName: "metadata", + revisionName: { + serializedName: "revisionName", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "String" } }, - auth: { - serializedName: "auth", + weight: { + serializedName: "weight", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ScaleRuleAuth" - } - } + name: "Number" + } + }, + latestRevision: { + defaultValue: false, + serializedName: "latestRevision", + type: { + name: "Boolean" + } + }, + label: { + serializedName: "label", + type: { + name: "String" } } } } }; -export const Volume: coreClient.CompositeMapper = { +export const CustomDomain: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Volume", + className: "CustomDomain", modelProperties: { name: { serializedName: "name", + required: true, type: { name: "String" } }, - storageType: { - serializedName: "storageType", + bindingType: { + serializedName: "bindingType", type: { name: "String" } }, - storageName: { - serializedName: "storageName", + certificateId: { + serializedName: "certificateId", + required: true, type: { name: "String" } @@ -931,175 +1528,229 @@ export const Volume: coreClient.CompositeMapper = { } }; -export const Resource: coreClient.CompositeMapper = { +export const RegistryCredentials: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Resource", + className: "RegistryCredentials", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + server: { + serializedName: "server", type: { name: "String" } }, - name: { - serializedName: "name", - readOnly: true, + username: { + serializedName: "username", type: { name: "String" } }, - type: { - serializedName: "type", - readOnly: true, + passwordSecretRef: { + serializedName: "passwordSecretRef", type: { name: "String" } }, - systemData: { - serializedName: "systemData", + identity: { + serializedName: "identity", type: { - name: "Composite", - className: "SystemData" + name: "String" } } } } }; -export const SystemData: coreClient.CompositeMapper = { +export const Dapr: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SystemData", + className: "Dapr", modelProperties: { - createdBy: { - serializedName: "createdBy", + enabled: { + serializedName: "enabled", type: { - name: "String" + name: "Boolean" } }, - createdByType: { - serializedName: "createdByType", + appId: { + serializedName: "appId", type: { name: "String" } }, - createdAt: { - serializedName: "createdAt", - type: { - name: "DateTime" - } - }, - lastModifiedBy: { - serializedName: "lastModifiedBy", + appProtocol: { + serializedName: "appProtocol", type: { name: "String" } }, - lastModifiedByType: { - serializedName: "lastModifiedByType", + appPort: { + serializedName: "appPort", type: { - name: "String" + name: "Number" } }, - lastModifiedAt: { - serializedName: "lastModifiedAt", + httpReadBufferSize: { + serializedName: "httpReadBufferSize", type: { - name: "DateTime" + name: "Number" } } } } }; -export const DefaultErrorResponse: coreClient.CompositeMapper = { +export const Template: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultErrorResponse", + className: "Template", modelProperties: { - error: { - serializedName: "error", + revisionSuffix: { + serializedName: "revisionSuffix", + type: { + name: "String" + } + }, + containers: { + serializedName: "containers", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Container" + } + } + } + }, + scale: { + serializedName: "scale", type: { name: "Composite", - className: "DefaultErrorResponseError" + className: "Scale" + } + }, + volumes: { + serializedName: "volumes", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Volume" + } + } } } } } }; -export const DefaultErrorResponseError: coreClient.CompositeMapper = { +export const Container: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultErrorResponseError", + className: "Container", modelProperties: { - code: { - serializedName: "code", - readOnly: true, + image: { + serializedName: "image", type: { name: "String" } }, - message: { - serializedName: "message", - readOnly: true, + name: { + serializedName: "name", type: { name: "String" } }, - target: { - serializedName: "target", - readOnly: true, + command: { + serializedName: "command", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + args: { + serializedName: "args", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + env: { + serializedName: "env", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "EnvironmentVar" + } + } + } + }, + resources: { + serializedName: "resources", type: { - name: "String" + name: "Composite", + className: "ContainerResources" } }, - details: { - serializedName: "details", + probes: { + serializedName: "probes", type: { name: "Sequence", element: { type: { name: "Composite", - className: "DefaultErrorResponseErrorDetailsItem" + className: "ContainerAppProbe" } } } }, - innererror: { - serializedName: "innererror", - readOnly: true, + volumeMounts: { + serializedName: "volumeMounts", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "VolumeMount" + } + } } } } } }; -export const DefaultErrorResponseErrorDetailsItem: coreClient.CompositeMapper = { +export const EnvironmentVar: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultErrorResponseErrorDetailsItem", + className: "EnvironmentVar", modelProperties: { - code: { - serializedName: "code", - readOnly: true, + name: { + serializedName: "name", type: { name: "String" } }, - message: { - serializedName: "message", - readOnly: true, + value: { + serializedName: "value", type: { name: "String" } }, - target: { - serializedName: "target", - readOnly: true, + secretRef: { + serializedName: "secretRef", type: { name: "String" } @@ -1108,58 +1759,25 @@ export const DefaultErrorResponseErrorDetailsItem: coreClient.CompositeMapper = } }; -export const ContainerAppPatch: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppPatch", - modelProperties: { - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } -}; - -export const SecretsCollection: coreClient.CompositeMapper = { +export const ContainerResources: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SecretsCollection", + className: "ContainerResources", modelProperties: { - value: { - serializedName: "value", - required: true, + cpu: { + serializedName: "cpu", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ContainerAppSecret" - } - } + name: "Number" } - } - } - } -}; - -export const ContainerAppSecret: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerAppSecret", - modelProperties: { - name: { - serializedName: "name", - readOnly: true, + }, + memory: { + serializedName: "memory", type: { name: "String" } }, - value: { - serializedName: "value", + ephemeralStorage: { + serializedName: "ephemeralStorage", readOnly: true, type: { name: "String" @@ -1169,117 +1787,109 @@ export const ContainerAppSecret: coreClient.CompositeMapper = { } }; -export const RevisionCollection: coreClient.CompositeMapper = { +export const ContainerAppProbe: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RevisionCollection", + className: "ContainerAppProbe", modelProperties: { - value: { - serializedName: "value", - required: true, + failureThreshold: { + serializedName: "failureThreshold", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Revision" - } - } + name: "Number" } }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + httpGet: { + serializedName: "httpGet", type: { - name: "String" + name: "Composite", + className: "ContainerAppProbeHttpGet" } - } - } - } -}; - -export const ReplicaContainer: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ReplicaContainer", - modelProperties: { - name: { - serializedName: "name", + }, + initialDelaySeconds: { + serializedName: "initialDelaySeconds", type: { - name: "String" + name: "Number" } }, - containerId: { - serializedName: "containerId", + periodSeconds: { + serializedName: "periodSeconds", type: { - name: "String" + name: "Number" } }, - ready: { - serializedName: "ready", + successThreshold: { + serializedName: "successThreshold", type: { - name: "Boolean" + name: "Number" } }, - started: { - serializedName: "started", + tcpSocket: { + serializedName: "tcpSocket", type: { - name: "Boolean" + name: "Composite", + className: "ContainerAppProbeTcpSocket" } }, - restartCount: { - serializedName: "restartCount", + terminationGracePeriodSeconds: { + serializedName: "terminationGracePeriodSeconds", type: { name: "Number" } + }, + timeoutSeconds: { + serializedName: "timeoutSeconds", + type: { + name: "Number" + } + }, + type: { + serializedName: "type", + type: { + name: "String" + } } } } }; -export const ReplicaCollection: coreClient.CompositeMapper = { +export const ContainerAppProbeHttpGet: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ReplicaCollection", + className: "ContainerAppProbeHttpGet", modelProperties: { - value: { - serializedName: "value", - required: true, + host: { + serializedName: "host", + type: { + name: "String" + } + }, + httpHeaders: { + serializedName: "httpHeaders", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Replica" + className: "ContainerAppProbeHttpGetHttpHeadersItem" } } } - } - } - } -}; - -export const ManagedEnvironmentsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ManagedEnvironmentsCollection", - modelProperties: { - value: { - serializedName: "value", + }, + path: { + serializedName: "path", + type: { + name: "String" + } + }, + port: { + serializedName: "port", required: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ManagedEnvironment" - } - } + name: "Number" } }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + scheme: { + serializedName: "scheme", type: { name: "String" } @@ -1288,43 +1898,21 @@ export const ManagedEnvironmentsCollection: coreClient.CompositeMapper = { } }; -export const VnetConfiguration: coreClient.CompositeMapper = { +export const ContainerAppProbeHttpGetHttpHeadersItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "VnetConfiguration", + className: "ContainerAppProbeHttpGetHttpHeadersItem", modelProperties: { - internal: { - serializedName: "internal", - type: { - name: "Boolean" - } - }, - infrastructureSubnetId: { - serializedName: "infrastructureSubnetId", - type: { - name: "String" - } - }, - runtimeSubnetId: { - serializedName: "runtimeSubnetId", - type: { - name: "String" - } - }, - dockerBridgeCidr: { - serializedName: "dockerBridgeCidr", - type: { - name: "String" - } - }, - platformReservedCidr: { - serializedName: "platformReservedCidr", + name: { + serializedName: "name", + required: true, type: { name: "String" } }, - platformReservedDnsIP: { - serializedName: "platformReservedDnsIP", + value: { + serializedName: "value", + required: true, type: { name: "String" } @@ -1333,41 +1921,41 @@ export const VnetConfiguration: coreClient.CompositeMapper = { } }; -export const AppLogsConfiguration: coreClient.CompositeMapper = { +export const ContainerAppProbeTcpSocket: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AppLogsConfiguration", + className: "ContainerAppProbeTcpSocket", modelProperties: { - destination: { - serializedName: "destination", + host: { + serializedName: "host", type: { name: "String" } }, - logAnalyticsConfiguration: { - serializedName: "logAnalyticsConfiguration", + port: { + serializedName: "port", + required: true, type: { - name: "Composite", - className: "LogAnalyticsConfiguration" + name: "Number" } } } } }; -export const LogAnalyticsConfiguration: coreClient.CompositeMapper = { +export const VolumeMount: coreClient.CompositeMapper = { type: { name: "Composite", - className: "LogAnalyticsConfiguration", + className: "VolumeMount", modelProperties: { - customerId: { - serializedName: "customerId", + volumeName: { + serializedName: "volumeName", type: { name: "String" } }, - sharedKey: { - serializedName: "sharedKey", + mountPath: { + serializedName: "mountPath", type: { name: "String" } @@ -1376,163 +1964,121 @@ export const LogAnalyticsConfiguration: coreClient.CompositeMapper = { } }; -export const ManagedEnvironmentPatch: coreClient.CompositeMapper = { +export const Scale: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedEnvironmentPatch", + className: "Scale", modelProperties: { - tags: { - serializedName: "tags", + minReplicas: { + serializedName: "minReplicas", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "Number" } - } - } - } -}; - -export const CertificateCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CertificateCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + }, + maxReplicas: { + serializedName: "maxReplicas", + type: { + name: "Number" + } + }, + rules: { + serializedName: "rules", type: { name: "Sequence", element: { type: { name: "Composite", - className: "Certificate" + className: "ScaleRule" } } } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } } } } }; -export const CertificateProperties: coreClient.CompositeMapper = { +export const ScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificateProperties", + className: "ScaleRule", modelProperties: { - provisioningState: { - serializedName: "provisioningState", - readOnly: true, - type: { - name: "String" - } - }, - password: { - serializedName: "password", - type: { - name: "String" - } - }, - subjectName: { - serializedName: "subjectName", - readOnly: true, - type: { - name: "String" - } - }, - value: { - serializedName: "value", - type: { - name: "ByteArray" - } - }, - issuer: { - serializedName: "issuer", - readOnly: true, + name: { + serializedName: "name", type: { name: "String" } }, - issueDate: { - serializedName: "issueDate", - readOnly: true, - type: { - name: "DateTime" - } - }, - expirationDate: { - serializedName: "expirationDate", - readOnly: true, - type: { - name: "DateTime" - } - }, - thumbprint: { - serializedName: "thumbprint", - readOnly: true, + azureQueue: { + serializedName: "azureQueue", type: { - name: "String" + name: "Composite", + className: "QueueScaleRule" } }, - valid: { - serializedName: "valid", - readOnly: true, + custom: { + serializedName: "custom", type: { - name: "Boolean" + name: "Composite", + className: "CustomScaleRule" } }, - publicKeyHash: { - serializedName: "publicKeyHash", - readOnly: true, + http: { + serializedName: "http", type: { - name: "String" + name: "Composite", + className: "HttpScaleRule" } } } } }; -export const CertificatePatch: coreClient.CompositeMapper = { +export const QueueScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CertificatePatch", + className: "QueueScaleRule", modelProperties: { - tags: { - serializedName: "tags", + queueName: { + serializedName: "queueName", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "String" + } + }, + queueLength: { + serializedName: "queueLength", + type: { + name: "Number" + } + }, + auth: { + serializedName: "auth", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ScaleRuleAuth" + } + } } } } } }; -export const AvailableOperations: coreClient.CompositeMapper = { +export const ScaleRuleAuth: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AvailableOperations", + className: "ScaleRuleAuth", modelProperties: { - value: { - serializedName: "value", + secretRef: { + serializedName: "secretRef", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "OperationDetail" - } - } + name: "String" } }, - nextLink: { - serializedName: "nextLink", + triggerParameter: { + serializedName: "triggerParameter", type: { name: "String" } @@ -1541,94 +2087,87 @@ export const AvailableOperations: coreClient.CompositeMapper = { } }; -export const OperationDetail: coreClient.CompositeMapper = { +export const CustomScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OperationDetail", + className: "CustomScaleRule", modelProperties: { - name: { - serializedName: "name", + type: { + serializedName: "type", type: { name: "String" } }, - isDataAction: { - serializedName: "isDataAction", - type: { - name: "Boolean" - } - }, - display: { - serializedName: "display", + metadata: { + serializedName: "metadata", type: { - name: "Composite", - className: "OperationDisplay" + name: "Dictionary", + value: { type: { name: "String" } } } }, - origin: { - serializedName: "origin", + auth: { + serializedName: "auth", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ScaleRuleAuth" + } + } } } } } }; -export const OperationDisplay: coreClient.CompositeMapper = { +export const HttpScaleRule: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OperationDisplay", + className: "HttpScaleRule", modelProperties: { - provider: { - serializedName: "provider", - type: { - name: "String" - } - }, - resource: { - serializedName: "resource", - type: { - name: "String" - } - }, - operation: { - serializedName: "operation", + metadata: { + serializedName: "metadata", type: { - name: "String" + name: "Dictionary", + value: { type: { name: "String" } } } }, - description: { - serializedName: "description", + auth: { + serializedName: "auth", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ScaleRuleAuth" + } + } } } } } }; -export const SourceControlCollection: coreClient.CompositeMapper = { +export const Volume: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SourceControlCollection", + className: "Volume", modelProperties: { - value: { - serializedName: "value", - required: true, + name: { + serializedName: "name", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SourceControl" - } - } + name: "String" } }, - nextLink: { - serializedName: "nextLink", - readOnly: true, + storageType: { + serializedName: "storageType", + type: { + name: "String" + } + }, + storageName: { + serializedName: "storageName", type: { name: "String" } @@ -1637,167 +2176,181 @@ export const SourceControlCollection: coreClient.CompositeMapper = { } }; -export const GithubActionConfiguration: coreClient.CompositeMapper = { +export const CustomHostnameAnalysisResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GithubActionConfiguration", + className: "CustomHostnameAnalysisResult", modelProperties: { - registryInfo: { - serializedName: "registryInfo", + hostName: { + serializedName: "hostName", + readOnly: true, type: { - name: "Composite", - className: "RegistryInfo" + name: "String" } }, - azureCredentials: { - serializedName: "azureCredentials", + isHostnameAlreadyVerified: { + serializedName: "isHostnameAlreadyVerified", + readOnly: true, type: { - name: "Composite", - className: "AzureCredentials" + name: "Boolean" } }, - dockerfilePath: { - serializedName: "dockerfilePath", + customDomainVerificationTest: { + serializedName: "customDomainVerificationTest", + readOnly: true, type: { - name: "String" + name: "Enum", + allowedValues: ["Passed", "Failed", "Skipped"] } }, - publishType: { - serializedName: "publishType", + customDomainVerificationFailureInfo: { + serializedName: "customDomainVerificationFailureInfo", type: { - name: "String" + name: "Composite", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo" } }, - os: { - serializedName: "os", + hasConflictOnManagedEnvironment: { + serializedName: "hasConflictOnManagedEnvironment", + readOnly: true, type: { - name: "String" + name: "Boolean" } }, - runtimeStack: { - serializedName: "runtimeStack", + conflictingContainerAppResourceId: { + serializedName: "conflictingContainerAppResourceId", + readOnly: true, type: { name: "String" } }, - runtimeVersion: { - serializedName: "runtimeVersion", + cNameRecords: { + serializedName: "cNameRecords", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } - } - } - } -}; - -export const RegistryInfo: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RegistryInfo", - modelProperties: { - registryUrl: { - serializedName: "registryUrl", + }, + txtRecords: { + serializedName: "txtRecords", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - registryUserName: { - serializedName: "registryUserName", + aRecords: { + serializedName: "aRecords", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - registryPassword: { - serializedName: "registryPassword", + alternateCNameRecords: { + serializedName: "alternateCNameRecords", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + alternateTxtRecords: { + serializedName: "alternateTxtRecords", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } } } } } }; -export const AzureCredentials: coreClient.CompositeMapper = { +export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureCredentials", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfo", modelProperties: { - clientId: { - serializedName: "clientId", + code: { + serializedName: "code", + readOnly: true, type: { name: "String" } }, - clientSecret: { - serializedName: "clientSecret", + message: { + serializedName: "message", + readOnly: true, type: { name: "String" } }, - tenantId: { - serializedName: "tenantId", + target: { + serializedName: "target", + readOnly: true, type: { name: "String" } }, - subscriptionId: { - serializedName: "subscriptionId", - type: { - name: "String" - } - } - } - } -}; - -export const DaprComponentsCollection: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DaprComponentsCollection", - modelProperties: { - value: { - serializedName: "value", - required: true, + details: { + serializedName: "details", type: { name: "Sequence", element: { type: { name: "Composite", - className: "DaprComponent" + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem" } } } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } } } } }; -export const DaprMetadata: coreClient.CompositeMapper = { +export const CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprMetadata", + className: + "CustomHostnameAnalysisResultCustomDomainVerificationFailureInfoDetailsItem", modelProperties: { - name: { - serializedName: "name", + code: { + serializedName: "code", + readOnly: true, type: { name: "String" } }, - value: { - serializedName: "value", + message: { + serializedName: "message", + readOnly: true, type: { name: "String" } }, - secretRef: { - serializedName: "secretRef", + target: { + serializedName: "target", + readOnly: true, type: { name: "String" } @@ -1806,10 +2359,10 @@ export const DaprMetadata: coreClient.CompositeMapper = { } }; -export const AuthConfigCollection: coreClient.CompositeMapper = { +export const SecretsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AuthConfigCollection", + className: "SecretsCollection", modelProperties: { value: { serializedName: "value", @@ -1819,35 +2372,30 @@ export const AuthConfigCollection: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "AuthConfig" + className: "ContainerAppSecret" } } } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } } } } }; -export const AuthPlatform: coreClient.CompositeMapper = { +export const ContainerAppSecret: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AuthPlatform", + className: "ContainerAppSecret", modelProperties: { - enabled: { - serializedName: "enabled", + name: { + serializedName: "name", + readOnly: true, type: { - name: "Boolean" + name: "String" } }, - runtimeVersion: { - serializedName: "runtimeVersion", + value: { + serializedName: "value", + readOnly: true, type: { name: "String" } @@ -1856,106 +2404,111 @@ export const AuthPlatform: coreClient.CompositeMapper = { } }; -export const GlobalValidation: coreClient.CompositeMapper = { +export const RevisionCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GlobalValidation", + className: "RevisionCollection", modelProperties: { - unauthenticatedClientAction: { - serializedName: "unauthenticatedClientAction", - type: { - name: "Enum", - allowedValues: [ - "RedirectToLoginPage", - "AllowAnonymous", - "Return401", - "Return403" - ] - } - }, - redirectToProvider: { - serializedName: "redirectToProvider", - type: { - name: "String" - } - }, - excludedPaths: { - serializedName: "excludedPaths", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "Revision" } } } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String" + } } } } }; -export const IdentityProviders: coreClient.CompositeMapper = { +export const TrafficLabel: coreClient.CompositeMapper = { type: { name: "Composite", - className: "IdentityProviders", + className: "TrafficLabel", modelProperties: { - azureActiveDirectory: { - serializedName: "azureActiveDirectory", + label: { + serializedName: "label", + readOnly: true, type: { - name: "Composite", - className: "AzureActiveDirectory" + name: "String" } }, - facebook: { - serializedName: "facebook", + fqdn: { + serializedName: "fqdn", + readOnly: true, type: { - name: "Composite", - className: "Facebook" + name: "String" } - }, - gitHub: { - serializedName: "gitHub", + } + } + } +}; + +export const ReplicaContainer: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ReplicaContainer", + modelProperties: { + name: { + serializedName: "name", type: { - name: "Composite", - className: "GitHub" + name: "String" } }, - google: { - serializedName: "google", + containerId: { + serializedName: "containerId", type: { - name: "Composite", - className: "Google" + name: "String" } }, - twitter: { - serializedName: "twitter", + ready: { + serializedName: "ready", type: { - name: "Composite", - className: "Twitter" + name: "Boolean" } }, - apple: { - serializedName: "apple", + started: { + serializedName: "started", type: { - name: "Composite", - className: "Apple" + name: "Boolean" } }, - azureStaticWebApps: { - serializedName: "azureStaticWebApps", + restartCount: { + serializedName: "restartCount", type: { - name: "Composite", - className: "AzureStaticWebApps" + name: "Number" } - }, - customOpenIdConnectProviders: { - serializedName: "customOpenIdConnectProviders", + } + } + } +}; + +export const ReplicaCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ReplicaCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, type: { - name: "Dictionary", - value: { + name: "Sequence", + element: { type: { name: "Composite", - className: "CustomOpenIdConnectProvider" + className: "Replica" } } } @@ -1964,85 +2517,54 @@ export const IdentityProviders: coreClient.CompositeMapper = { } }; -export const AzureActiveDirectory: coreClient.CompositeMapper = { +export const DaprComponentsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectory", + className: "DaprComponentsCollection", modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean" - } - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "AzureActiveDirectoryRegistration" - } - }, - login: { - serializedName: "login", - type: { - name: "Composite", - className: "AzureActiveDirectoryLogin" - } - }, - validation: { - serializedName: "validation", + value: { + serializedName: "value", + required: true, type: { - name: "Composite", - className: "AzureActiveDirectoryValidation" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DaprComponent" + } + } } }, - isAutoProvisioned: { - serializedName: "isAutoProvisioned", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Boolean" + name: "String" } } } } }; -export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { +export const DaprMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectoryRegistration", + className: "DaprMetadata", modelProperties: { - openIdIssuer: { - serializedName: "openIdIssuer", - type: { - name: "String" - } - }, - clientId: { - serializedName: "clientId", - type: { - name: "String" - } - }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", - type: { - name: "String" - } - }, - clientSecretCertificateThumbprint: { - serializedName: "clientSecretCertificateThumbprint", + name: { + serializedName: "name", type: { name: "String" } }, - clientSecretCertificateSubjectAlternativeName: { - serializedName: "clientSecretCertificateSubjectAlternativeName", + value: { + serializedName: "value", type: { name: "String" } }, - clientSecretCertificateIssuer: { - serializedName: "clientSecretCertificateIssuer", + secretRef: { + serializedName: "secretRef", type: { name: "String" } @@ -2051,142 +2573,153 @@ export const AzureActiveDirectoryRegistration: coreClient.CompositeMapper = { } }; -export const AzureActiveDirectoryLogin: coreClient.CompositeMapper = { +export const DaprSecretsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectoryLogin", + className: "DaprSecretsCollection", modelProperties: { - loginParameters: { - serializedName: "loginParameters", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "Secret" } } } - }, - disableWWWAuthenticate: { - serializedName: "disableWWWAuthenticate", - type: { - name: "Boolean" - } } } } }; -export const AzureActiveDirectoryValidation: coreClient.CompositeMapper = { +export const DiagnosticsCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureActiveDirectoryValidation", + className: "DiagnosticsCollection", modelProperties: { - jwtClaimChecks: { - serializedName: "jwtClaimChecks", - type: { - name: "Composite", - className: "JwtClaimChecks" - } - }, - allowedAudiences: { - serializedName: "allowedAudiences", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "Diagnostics" } } } }, - defaultAuthorizationPolicy: { - serializedName: "defaultAuthorizationPolicy", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { - name: "Composite", - className: "DefaultAuthorizationPolicy" + name: "String" } } } } }; -export const JwtClaimChecks: coreClient.CompositeMapper = { +export const DiagnosticsProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JwtClaimChecks", + className: "DiagnosticsProperties", modelProperties: { - allowedGroups: { - serializedName: "allowedGroups", + metadata: { + serializedName: "metadata", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "Composite", + className: "DiagnosticsDefinition" } }, - allowedClientApplications: { - serializedName: "allowedClientApplications", + dataset: { + serializedName: "dataset", type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "DiagnosticsDataApiResponse" } } } + }, + status: { + serializedName: "status", + type: { + name: "Composite", + className: "DiagnosticsStatus" + } + }, + dataProviderMetadata: { + serializedName: "dataProviderMetadata", + type: { + name: "Composite", + className: "DiagnosticDataProviderMetadata" + } } } } }; -export const DefaultAuthorizationPolicy: coreClient.CompositeMapper = { +export const DiagnosticsDefinition: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DefaultAuthorizationPolicy", + className: "DiagnosticsDefinition", modelProperties: { - allowedPrincipals: { - serializedName: "allowedPrincipals", + id: { + serializedName: "id", + readOnly: true, + type: { + name: "String" + } + }, + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "description", + readOnly: true, type: { - name: "Composite", - className: "AllowedPrincipals" + name: "String" } }, - allowedApplications: { - serializedName: "allowedApplications", + author: { + serializedName: "author", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } - } - } - } -}; - -export const AllowedPrincipals: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AllowedPrincipals", - modelProperties: { - groups: { - serializedName: "groups", + }, + category: { + serializedName: "category", + readOnly: true, + type: { + name: "String" + } + }, + supportTopicList: { + serializedName: "supportTopicList", type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "DiagnosticSupportTopic" } } } }, - identities: { - serializedName: "identities", + analysisTypes: { + serializedName: "analysisTypes", type: { name: "Sequence", element: { @@ -2195,59 +2728,40 @@ export const AllowedPrincipals: coreClient.CompositeMapper = { } } } - } - } - } -}; - -export const Facebook: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Facebook", - modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean" - } - }, - registration: { - serializedName: "registration", - type: { - name: "Composite", - className: "AppRegistration" - } }, - graphApiVersion: { - serializedName: "graphApiVersion", + type: { + serializedName: "type", + readOnly: true, type: { name: "String" } }, - login: { - serializedName: "login", + score: { + serializedName: "score", + readOnly: true, type: { - name: "Composite", - className: "LoginScopes" + name: "Number" } } } } }; -export const AppRegistration: coreClient.CompositeMapper = { +export const DiagnosticSupportTopic: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AppRegistration", + className: "DiagnosticSupportTopic", modelProperties: { - appId: { - serializedName: "appId", + id: { + serializedName: "id", + readOnly: true, type: { name: "String" } }, - appSecretSettingName: { - serializedName: "appSecretSettingName", + pesId: { + serializedName: "pesId", + readOnly: true, type: { name: "String" } @@ -2256,68 +2770,87 @@ export const AppRegistration: coreClient.CompositeMapper = { } }; -export const LoginScopes: coreClient.CompositeMapper = { +export const DiagnosticsDataApiResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "LoginScopes", + className: "DiagnosticsDataApiResponse", modelProperties: { - scopes: { - serializedName: "scopes", + table: { + serializedName: "table", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "Composite", + className: "DiagnosticDataTableResponseObject" + } + }, + renderingProperties: { + serializedName: "renderingProperties", + type: { + name: "Composite", + className: "DiagnosticRendering" } } } } }; -export const GitHub: coreClient.CompositeMapper = { +export const DiagnosticDataTableResponseObject: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GitHub", + className: "DiagnosticDataTableResponseObject", modelProperties: { - enabled: { - serializedName: "enabled", + tableName: { + serializedName: "tableName", type: { - name: "Boolean" + name: "String" } }, - registration: { - serializedName: "registration", + columns: { + serializedName: "columns", type: { - name: "Composite", - className: "ClientRegistration" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DiagnosticDataTableResponseColumn" + } + } } }, - login: { - serializedName: "login", + rows: { + serializedName: "rows", type: { - name: "Composite", - className: "LoginScopes" + name: "Sequence", + element: { + type: { + name: "Dictionary", + value: { type: { name: "any" } } + } + } } } } } }; -export const ClientRegistration: coreClient.CompositeMapper = { +export const DiagnosticDataTableResponseColumn: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ClientRegistration", + className: "DiagnosticDataTableResponseColumn", modelProperties: { - clientId: { - serializedName: "clientId", + columnName: { + serializedName: "columnName", type: { name: "String" } }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", + dataType: { + serializedName: "dataType", + type: { + name: "String" + } + }, + columnType: { + serializedName: "columnType", type: { name: "String" } @@ -2326,97 +2859,100 @@ export const ClientRegistration: coreClient.CompositeMapper = { } }; -export const Google: coreClient.CompositeMapper = { +export const DiagnosticRendering: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Google", + className: "DiagnosticRendering", modelProperties: { - enabled: { - serializedName: "enabled", + type: { + serializedName: "type", type: { - name: "Boolean" + name: "Number" } }, - registration: { - serializedName: "registration", + title: { + serializedName: "title", type: { - name: "Composite", - className: "ClientRegistration" + name: "String" } }, - login: { - serializedName: "login", + description: { + serializedName: "description", type: { - name: "Composite", - className: "LoginScopes" + name: "String" } }, - validation: { - serializedName: "validation", + isVisible: { + serializedName: "isVisible", type: { - name: "Composite", - className: "AllowedAudiencesValidation" + name: "Boolean" } } } } }; -export const AllowedAudiencesValidation: coreClient.CompositeMapper = { +export const DiagnosticsStatus: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AllowedAudiencesValidation", + className: "DiagnosticsStatus", modelProperties: { - allowedAudiences: { - serializedName: "allowedAudiences", + message: { + serializedName: "message", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" + } + }, + statusId: { + serializedName: "statusId", + type: { + name: "Number" } } } } }; -export const Twitter: coreClient.CompositeMapper = { +export const DiagnosticDataProviderMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Twitter", + className: "DiagnosticDataProviderMetadata", modelProperties: { - enabled: { - serializedName: "enabled", + providerName: { + serializedName: "providerName", type: { - name: "Boolean" + name: "String" } }, - registration: { - serializedName: "registration", + propertyBag: { + serializedName: "propertyBag", type: { - name: "Composite", - className: "TwitterRegistration" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DiagnosticDataProviderMetadataPropertyBagItem" + } + } } } } } }; -export const TwitterRegistration: coreClient.CompositeMapper = { +export const DiagnosticDataProviderMetadataPropertyBagItem: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TwitterRegistration", + className: "DiagnosticDataProviderMetadataPropertyBagItem", modelProperties: { - consumerKey: { - serializedName: "consumerKey", + name: { + serializedName: "name", type: { name: "String" } }, - consumerSecretSettingName: { - serializedName: "consumerSecretSettingName", + value: { + serializedName: "value", type: { name: "String" } @@ -2425,166 +2961,147 @@ export const TwitterRegistration: coreClient.CompositeMapper = { } }; -export const Apple: coreClient.CompositeMapper = { +export const VnetConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Apple", + className: "VnetConfiguration", modelProperties: { - enabled: { - serializedName: "enabled", + internal: { + serializedName: "internal", type: { name: "Boolean" } }, - registration: { - serializedName: "registration", + infrastructureSubnetId: { + serializedName: "infrastructureSubnetId", type: { - name: "Composite", - className: "AppleRegistration" + name: "String" } }, - login: { - serializedName: "login", - type: { - name: "Composite", - className: "LoginScopes" - } - } - } - } -}; - -export const AppleRegistration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AppleRegistration", - modelProperties: { - clientId: { - serializedName: "clientId", + runtimeSubnetId: { + serializedName: "runtimeSubnetId", type: { name: "String" } }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", + dockerBridgeCidr: { + serializedName: "dockerBridgeCidr", type: { name: "String" } - } - } - } -}; - -export const AzureStaticWebApps: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AzureStaticWebApps", - modelProperties: { - enabled: { - serializedName: "enabled", + }, + platformReservedCidr: { + serializedName: "platformReservedCidr", type: { - name: "Boolean" + name: "String" } }, - registration: { - serializedName: "registration", + platformReservedDnsIP: { + serializedName: "platformReservedDnsIP", type: { - name: "Composite", - className: "AzureStaticWebAppsRegistration" + name: "String" } } } } }; -export const AzureStaticWebAppsRegistration: coreClient.CompositeMapper = { +export const AppLogsConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AzureStaticWebAppsRegistration", + className: "AppLogsConfiguration", modelProperties: { - clientId: { - serializedName: "clientId", + destination: { + serializedName: "destination", type: { name: "String" } + }, + logAnalyticsConfiguration: { + serializedName: "logAnalyticsConfiguration", + type: { + name: "Composite", + className: "LogAnalyticsConfiguration" + } } } } }; -export const CustomOpenIdConnectProvider: coreClient.CompositeMapper = { +export const LogAnalyticsConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomOpenIdConnectProvider", + className: "LogAnalyticsConfiguration", modelProperties: { - enabled: { - serializedName: "enabled", - type: { - name: "Boolean" - } - }, - registration: { - serializedName: "registration", + customerId: { + serializedName: "customerId", type: { - name: "Composite", - className: "OpenIdConnectRegistration" + name: "String" } }, - login: { - serializedName: "login", + sharedKey: { + serializedName: "sharedKey", type: { - name: "Composite", - className: "OpenIdConnectLogin" + name: "String" } } } } }; -export const OpenIdConnectRegistration: coreClient.CompositeMapper = { +export const AvailableOperations: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OpenIdConnectRegistration", + className: "AvailableOperations", modelProperties: { - clientId: { - serializedName: "clientId", - type: { - name: "String" - } - }, - clientCredential: { - serializedName: "clientCredential", + value: { + serializedName: "value", type: { - name: "Composite", - className: "OpenIdConnectClientCredential" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "OperationDetail" + } + } } }, - openIdConnectConfiguration: { - serializedName: "openIdConnectConfiguration", + nextLink: { + serializedName: "nextLink", type: { - name: "Composite", - className: "OpenIdConnectConfig" + name: "String" } } } } }; -export const OpenIdConnectClientCredential: coreClient.CompositeMapper = { +export const OperationDetail: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OpenIdConnectClientCredential", + className: "OperationDetail", modelProperties: { - method: { - defaultValue: "ClientSecretPost", - isConstant: true, - serializedName: "method", + name: { + serializedName: "name", type: { name: "String" } }, - clientSecretSettingName: { - serializedName: "clientSecretSettingName", + isDataAction: { + serializedName: "isDataAction", + type: { + name: "Boolean" + } + }, + display: { + serializedName: "display", + type: { + name: "Composite", + className: "OperationDisplay" + } + }, + origin: { + serializedName: "origin", type: { name: "String" } @@ -2593,37 +3110,60 @@ export const OpenIdConnectClientCredential: coreClient.CompositeMapper = { } }; -export const OpenIdConnectConfig: coreClient.CompositeMapper = { +export const OperationDisplay: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OpenIdConnectConfig", + className: "OperationDisplay", modelProperties: { - authorizationEndpoint: { - serializedName: "authorizationEndpoint", + provider: { + serializedName: "provider", type: { name: "String" } }, - tokenEndpoint: { - serializedName: "tokenEndpoint", + resource: { + serializedName: "resource", type: { name: "String" } }, - issuer: { - serializedName: "issuer", + operation: { + serializedName: "operation", type: { name: "String" } }, - certificationUri: { - serializedName: "certificationUri", + description: { + serializedName: "description", type: { name: "String" } + } + } + } +}; + +export const ManagedEnvironmentsCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ManagedEnvironmentsCollection", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ManagedEnvironment" + } + } + } }, - wellKnownOpenIdConfiguration: { - serializedName: "wellKnownOpenIdConfiguration", + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String" } @@ -2632,52 +3172,63 @@ export const OpenIdConnectConfig: coreClient.CompositeMapper = { } }; -export const OpenIdConnectLogin: coreClient.CompositeMapper = { +export const CertificateCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OpenIdConnectLogin", + className: "CertificateCollection", modelProperties: { - nameClaimType: { - serializedName: "nameClaimType", - type: { - name: "String" - } - }, - scopes: { - serializedName: "scopes", + value: { + serializedName: "value", + required: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "Certificate" } } } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String" + } } } } }; -export const Login: coreClient.CompositeMapper = { +export const CertificateProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Login", + className: "CertificateProperties", modelProperties: { - routes: { - serializedName: "routes", + provisioningState: { + serializedName: "provisioningState", + readOnly: true, type: { - name: "Composite", - className: "LoginRoutes" + name: "String" } }, - preserveUrlFragmentsForLogins: { - serializedName: "preserveUrlFragmentsForLogins", + password: { + serializedName: "password", type: { - name: "Boolean" + name: "String" } }, - allowedExternalRedirectUrls: { - serializedName: "allowedExternalRedirectUrls", + subjectName: { + serializedName: "subjectName", + readOnly: true, + type: { + name: "String" + } + }, + subjectAlternativeNames: { + serializedName: "subjectAlternativeNames", + readOnly: true, type: { name: "Sequence", element: { @@ -2687,74 +3238,50 @@ export const Login: coreClient.CompositeMapper = { } } }, - cookieExpiration: { - serializedName: "cookieExpiration", + value: { + serializedName: "value", type: { - name: "Composite", - className: "CookieExpiration" + name: "ByteArray" } }, - nonce: { - serializedName: "nonce", + issuer: { + serializedName: "issuer", + readOnly: true, type: { - name: "Composite", - className: "Nonce" + name: "String" } - } - } - } -}; - -export const LoginRoutes: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "LoginRoutes", - modelProperties: { - logoutEndpoint: { - serializedName: "logoutEndpoint", + }, + issueDate: { + serializedName: "issueDate", + readOnly: true, type: { - name: "String" + name: "DateTime" } - } - } - } -}; - -export const CookieExpiration: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CookieExpiration", - modelProperties: { - convention: { - serializedName: "convention", + }, + expirationDate: { + serializedName: "expirationDate", + readOnly: true, type: { - name: "Enum", - allowedValues: ["FixedTime", "IdentityProviderDerived"] + name: "DateTime" } }, - timeToExpiration: { - serializedName: "timeToExpiration", + thumbprint: { + serializedName: "thumbprint", + readOnly: true, type: { name: "String" } - } - } - } -}; - -export const Nonce: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Nonce", - modelProperties: { - validateNonce: { - serializedName: "validateNonce", + }, + valid: { + serializedName: "valid", + readOnly: true, type: { name: "Boolean" } }, - nonceExpirationInterval: { - serializedName: "nonceExpirationInterval", + publicKeyHash: { + serializedName: "publicKeyHash", + readOnly: true, type: { name: "String" } @@ -2763,42 +3290,35 @@ export const Nonce: coreClient.CompositeMapper = { } }; -export const HttpSettings: coreClient.CompositeMapper = { +export const CertificatePatch: coreClient.CompositeMapper = { type: { name: "Composite", - className: "HttpSettings", + className: "CertificatePatch", modelProperties: { - requireHttps: { - serializedName: "requireHttps", - type: { - name: "Boolean" - } - }, - routes: { - serializedName: "routes", - type: { - name: "Composite", - className: "HttpSettingsRoutes" - } - }, - forwardProxy: { - serializedName: "forwardProxy", + tags: { + serializedName: "tags", type: { - name: "Composite", - className: "ForwardProxy" + name: "Dictionary", + value: { type: { name: "String" } } } } } } }; -export const HttpSettingsRoutes: coreClient.CompositeMapper = { +export const CheckNameAvailabilityRequest: coreClient.CompositeMapper = { type: { name: "Composite", - className: "HttpSettingsRoutes", + className: "CheckNameAvailabilityRequest", modelProperties: { - apiPrefix: { - serializedName: "apiPrefix", + name: { + serializedName: "name", + type: { + name: "String" + } + }, + type: { + serializedName: "type", type: { name: "String" } @@ -2807,26 +3327,25 @@ export const HttpSettingsRoutes: coreClient.CompositeMapper = { } }; -export const ForwardProxy: coreClient.CompositeMapper = { +export const CheckNameAvailabilityResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ForwardProxy", + className: "CheckNameAvailabilityResponse", modelProperties: { - convention: { - serializedName: "convention", + nameAvailable: { + serializedName: "nameAvailable", type: { - name: "Enum", - allowedValues: ["NoProxy", "Standard", "Custom"] + name: "Boolean" } }, - customHostHeaderName: { - serializedName: "customHostHeaderName", + reason: { + serializedName: "reason", type: { name: "String" } }, - customProtoHeaderName: { - serializedName: "customProtoHeaderName", + message: { + serializedName: "message", type: { name: "String" } @@ -2906,22 +3425,27 @@ export const AzureFileProperties: coreClient.CompositeMapper = { } }; -export const TrackedResource: coreClient.CompositeMapper = { +export const SourceControlCollection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TrackedResource", + className: "SourceControlCollection", modelProperties: { - ...Resource.type.modelProperties, - tags: { - serializedName: "tags", + value: { + serializedName: "value", + required: true, type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SourceControl" + } + } } }, - location: { - serializedName: "location", - required: true, + nextLink: { + serializedName: "nextLink", + readOnly: true, type: { name: "String" } @@ -2930,85 +3454,167 @@ export const TrackedResource: coreClient.CompositeMapper = { } }; -export const ProxyResource: coreClient.CompositeMapper = { +export const GithubActionConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ProxyResource", + className: "GithubActionConfiguration", modelProperties: { - ...Resource.type.modelProperties + registryInfo: { + serializedName: "registryInfo", + type: { + name: "Composite", + className: "RegistryInfo" + } + }, + azureCredentials: { + serializedName: "azureCredentials", + type: { + name: "Composite", + className: "AzureCredentials" + } + }, + contextPath: { + serializedName: "contextPath", + type: { + name: "String" + } + }, + image: { + serializedName: "image", + type: { + name: "String" + } + }, + publishType: { + serializedName: "publishType", + type: { + name: "String" + } + }, + os: { + serializedName: "os", + type: { + name: "String" + } + }, + runtimeStack: { + serializedName: "runtimeStack", + type: { + name: "String" + } + }, + runtimeVersion: { + serializedName: "runtimeVersion", + type: { + name: "String" + } + } } } }; -export const ContainerApp: coreClient.CompositeMapper = { +export const RegistryInfo: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ContainerApp", + className: "RegistryInfo", modelProperties: { - ...TrackedResource.type.modelProperties, - identity: { - serializedName: "identity", + registryUrl: { + serializedName: "registryUrl", type: { - name: "Composite", - className: "ManagedServiceIdentity" + name: "String" } }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, + registryUserName: { + serializedName: "registryUserName", type: { name: "String" } }, - managedEnvironmentId: { - serializedName: "properties.managedEnvironmentId", + registryPassword: { + serializedName: "registryPassword", type: { name: "String" } - }, - latestRevisionName: { - serializedName: "properties.latestRevisionName", - readOnly: true, + } + } + } +}; + +export const AzureCredentials: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AzureCredentials", + modelProperties: { + clientId: { + serializedName: "clientId", type: { name: "String" } }, - latestRevisionFqdn: { - serializedName: "properties.latestRevisionFqdn", - readOnly: true, + clientSecret: { + serializedName: "clientSecret", type: { name: "String" } }, - customDomainVerificationId: { - serializedName: "properties.customDomainVerificationId", - readOnly: true, + tenantId: { + serializedName: "tenantId", type: { name: "String" } }, - configuration: { - serializedName: "properties.configuration", + subscriptionId: { + serializedName: "subscriptionId", type: { - name: "Composite", - className: "Configuration" + name: "String" } - }, - template: { - serializedName: "properties.template", + } + } + } +}; + +export const ConnectedEnvironmentCollection: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ConnectedEnvironmentCollection", + modelProperties: { + value: { + serializedName: "value", type: { - name: "Composite", - className: "Template" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ConnectedEnvironment" + } + } } }, - outboundIPAddresses: { - serializedName: "properties.outboundIPAddresses", + nextLink: { + serializedName: "nextLink", readOnly: true, + 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: "String" + name: "Composite", + className: "ConnectedEnvironmentStorage" } } } @@ -3017,193 +3623,191 @@ export const ContainerApp: coreClient.CompositeMapper = { } }; -export const ManagedEnvironment: coreClient.CompositeMapper = { +export const ConnectedEnvironmentStorageProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ConnectedEnvironmentStorageProperties", + modelProperties: { + azureFile: { + serializedName: "azureFile", + type: { + name: "Composite", + className: "AzureFileProperties" + } + } + } + } +}; + +export const ProxyResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedEnvironment", + className: "ProxyResource", modelProperties: { - ...TrackedResource.type.modelProperties, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, + ...Resource.type.modelProperties + } + } +}; + +export const TrackedResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackedResource", + modelProperties: { + ...Resource.type.modelProperties, + tags: { + serializedName: "tags", type: { - name: "String" + name: "Dictionary", + value: { type: { name: "String" } } } }, - daprAIInstrumentationKey: { - serializedName: "properties.daprAIInstrumentationKey", + location: { + serializedName: "location", + required: true, type: { name: "String" } - }, - vnetConfiguration: { - serializedName: "properties.vnetConfiguration", + } + } + } +}; + +export const AuthConfig: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AuthConfig", + modelProperties: { + ...ProxyResource.type.modelProperties, + platform: { + serializedName: "properties.platform", type: { name: "Composite", - className: "VnetConfiguration" - } - }, - deploymentErrors: { - serializedName: "properties.deploymentErrors", - readOnly: true, - type: { - name: "String" + className: "AuthPlatform" } }, - defaultDomain: { - serializedName: "properties.defaultDomain", - readOnly: true, + globalValidation: { + serializedName: "properties.globalValidation", type: { - name: "String" + name: "Composite", + className: "GlobalValidation" } }, - staticIp: { - serializedName: "properties.staticIp", - readOnly: true, + identityProviders: { + serializedName: "properties.identityProviders", type: { - name: "String" + name: "Composite", + className: "IdentityProviders" } }, - appLogsConfiguration: { - serializedName: "properties.appLogsConfiguration", + login: { + serializedName: "properties.login", type: { name: "Composite", - className: "AppLogsConfiguration" + className: "Login" } - } - } - } -}; - -export const Certificate: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Certificate", - modelProperties: { - ...TrackedResource.type.modelProperties, - properties: { - serializedName: "properties", + }, + httpSettings: { + serializedName: "properties.httpSettings", type: { name: "Composite", - className: "CertificateProperties" + className: "HttpSettings" } } } } }; -export const CustomHostnameAnalysisResult: coreClient.CompositeMapper = { +export const Revision: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CustomHostnameAnalysisResult", + className: "Revision", modelProperties: { ...ProxyResource.type.modelProperties, - hostName: { - serializedName: "properties.hostName", - readOnly: true, - type: { - name: "String" - } - }, - isHostnameAlreadyVerified: { - serializedName: "properties.isHostnameAlreadyVerified", + createdTime: { + serializedName: "properties.createdTime", readOnly: true, type: { - name: "Boolean" + name: "DateTime" } }, - customDomainVerificationTest: { - serializedName: "properties.customDomainVerificationTest", + fqdn: { + serializedName: "properties.fqdn", readOnly: true, type: { - name: "Enum", - allowedValues: ["Passed", "Failed", "Skipped"] + name: "String" } }, - customDomainVerificationFailureInfo: { - serializedName: "properties.customDomainVerificationFailureInfo", + template: { + serializedName: "properties.template", type: { name: "Composite", - className: "DefaultErrorResponse" + className: "Template" } }, - hasConflictOnManagedEnvironment: { - serializedName: "properties.hasConflictOnManagedEnvironment", + active: { + serializedName: "properties.active", readOnly: true, type: { name: "Boolean" } }, - conflictingContainerAppResourceId: { - serializedName: "properties.conflictingContainerAppResourceId", + replicas: { + serializedName: "properties.replicas", readOnly: true, type: { - name: "String" + name: "Number" } }, - cNameRecords: { - serializedName: "properties.cNameRecords", + trafficWeight: { + serializedName: "properties.trafficWeight", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "Number" } }, - txtRecords: { - serializedName: "properties.txtRecords", + trafficLabels: { + serializedName: "properties.trafficLabels", + readOnly: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "TrafficLabel" } } } }, - aRecords: { - serializedName: "properties.aRecords", + provisioningError: { + serializedName: "properties.provisioningError", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } }, - alternateCNameRecords: { - serializedName: "properties.alternateCNameRecords", + healthState: { + serializedName: "properties.healthState", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } }, - alternateTxtRecords: { - serializedName: "properties.alternateTxtRecords", + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } } } } }; -export const Revision: coreClient.CompositeMapper = { +export const Replica: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Revision", + className: "Replica", modelProperties: { ...ProxyResource.type.modelProperties, createdTime: { @@ -3213,89 +3817,119 @@ export const Revision: coreClient.CompositeMapper = { name: "DateTime" } }, - fqdn: { - serializedName: "properties.fqdn", - readOnly: true, + containers: { + serializedName: "properties.containers", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ReplicaContainer" + } + } } - }, - template: { - serializedName: "properties.template", + } + } + } +}; + +export const DaprComponent: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DaprComponent", + modelProperties: { + ...ProxyResource.type.modelProperties, + componentType: { + serializedName: "properties.componentType", type: { - name: "Composite", - className: "Template" + name: "String" } }, - active: { - serializedName: "properties.active", - readOnly: true, + version: { + serializedName: "properties.version", type: { - name: "Boolean" + name: "String" } }, - replicas: { - serializedName: "properties.replicas", - readOnly: true, + ignoreErrors: { + serializedName: "properties.ignoreErrors", type: { - name: "Number" + name: "Boolean" } }, - trafficWeight: { - serializedName: "properties.trafficWeight", - readOnly: true, + initTimeout: { + serializedName: "properties.initTimeout", type: { - name: "Number" + name: "String" } }, - provisioningError: { - serializedName: "properties.provisioningError", - readOnly: true, + secrets: { + serializedName: "properties.secrets", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Secret" + } + } } }, - healthState: { - serializedName: "properties.healthState", - readOnly: true, + metadata: { + serializedName: "properties.metadata", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DaprMetadata" + } + } } }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, + scopes: { + serializedName: "properties.scopes", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } } } } }; -export const Replica: coreClient.CompositeMapper = { +export const Diagnostics: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Replica", + className: "Diagnostics", modelProperties: { ...ProxyResource.type.modelProperties, - createdTime: { - serializedName: "properties.createdTime", - readOnly: true, + properties: { + serializedName: "properties", type: { - name: "DateTime" + name: "Composite", + className: "DiagnosticsProperties" } - }, - containers: { - serializedName: "properties.containers", + } + } + } +}; + +export const ManagedEnvironmentStorage: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ManagedEnvironmentStorage", + modelProperties: { + ...ProxyResource.type.modelProperties, + properties: { + serializedName: "properties", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ReplicaContainer" - } - } + name: "Composite", + className: "ManagedEnvironmentStorageProperties" } } } @@ -3338,62 +3972,100 @@ export const SourceControl: coreClient.CompositeMapper = { } }; -export const DaprComponent: coreClient.CompositeMapper = { +export const ConnectedEnvironmentStorage: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DaprComponent", + className: "ConnectedEnvironmentStorage", modelProperties: { ...ProxyResource.type.modelProperties, - componentType: { - serializedName: "properties.componentType", + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "ConnectedEnvironmentStorageProperties" + } + } + } + } +}; + +export const ContainerApp: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ContainerApp", + modelProperties: { + ...TrackedResource.type.modelProperties, + extendedLocation: { + serializedName: "extendedLocation", + type: { + name: "Composite", + className: "ExtendedLocation" + } + }, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ManagedServiceIdentity" + } + }, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, type: { name: "String" } }, - version: { - serializedName: "properties.version", + managedEnvironmentId: { + serializedName: "properties.managedEnvironmentId", type: { name: "String" } }, - ignoreErrors: { - serializedName: "properties.ignoreErrors", + environmentId: { + serializedName: "properties.environmentId", type: { - name: "Boolean" + name: "String" } }, - initTimeout: { - serializedName: "properties.initTimeout", + latestRevisionName: { + serializedName: "properties.latestRevisionName", + readOnly: true, type: { name: "String" } }, - secrets: { - serializedName: "properties.secrets", + latestRevisionFqdn: { + serializedName: "properties.latestRevisionFqdn", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Secret" - } - } + name: "String" } }, - metadata: { - serializedName: "properties.metadata", + customDomainVerificationId: { + serializedName: "properties.customDomainVerificationId", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DaprMetadata" - } - } + name: "String" } }, - scopes: { - serializedName: "properties.scopes", + configuration: { + serializedName: "properties.configuration", + type: { + name: "Composite", + className: "Configuration" + } + }, + template: { + serializedName: "properties.template", + type: { + name: "Composite", + className: "Template" + } + }, + outboundIPAddresses: { + serializedName: "properties.outboundIPAddresses", + readOnly: true, type: { name: "Sequence", element: { @@ -3407,62 +4079,137 @@ export const DaprComponent: coreClient.CompositeMapper = { } }; -export const AuthConfig: coreClient.CompositeMapper = { +export const ManagedEnvironment: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AuthConfig", + className: "ManagedEnvironment", modelProperties: { - ...ProxyResource.type.modelProperties, - platform: { - serializedName: "properties.platform", + ...TrackedResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, type: { - name: "Composite", - className: "AuthPlatform" + name: "String" } }, - globalValidation: { - serializedName: "properties.globalValidation", + daprAIInstrumentationKey: { + serializedName: "properties.daprAIInstrumentationKey", type: { - name: "Composite", - className: "GlobalValidation" + name: "String" } }, - identityProviders: { - serializedName: "properties.identityProviders", + daprAIConnectionString: { + serializedName: "properties.daprAIConnectionString", type: { - name: "Composite", - className: "IdentityProviders" + name: "String" } }, - login: { - serializedName: "properties.login", + vnetConfiguration: { + serializedName: "properties.vnetConfiguration", type: { name: "Composite", - className: "Login" + className: "VnetConfiguration" } }, - httpSettings: { - serializedName: "properties.httpSettings", + deploymentErrors: { + serializedName: "properties.deploymentErrors", + readOnly: true, + type: { + name: "String" + } + }, + defaultDomain: { + serializedName: "properties.defaultDomain", + readOnly: true, + type: { + name: "String" + } + }, + staticIp: { + serializedName: "properties.staticIp", + readOnly: true, + type: { + name: "String" + } + }, + appLogsConfiguration: { + serializedName: "properties.appLogsConfiguration", type: { name: "Composite", - className: "HttpSettings" + className: "AppLogsConfiguration" + } + }, + zoneRedundant: { + serializedName: "properties.zoneRedundant", + type: { + name: "Boolean" } } } } }; -export const ManagedEnvironmentStorage: coreClient.CompositeMapper = { +export const Certificate: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedEnvironmentStorage", + className: "Certificate", modelProperties: { - ...ProxyResource.type.modelProperties, + ...TrackedResource.type.modelProperties, properties: { serializedName: "properties", type: { name: "Composite", - className: "ManagedEnvironmentStorageProperties" + className: "CertificateProperties" + } + } + } + } +}; + +export const ConnectedEnvironment: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ConnectedEnvironment", + modelProperties: { + ...TrackedResource.type.modelProperties, + extendedLocation: { + serializedName: "extendedLocation", + type: { + name: "Composite", + className: "ExtendedLocation" + } + }, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + deploymentErrors: { + serializedName: "properties.deploymentErrors", + readOnly: true, + type: { + name: "String" + } + }, + defaultDomain: { + serializedName: "properties.defaultDomain", + readOnly: true, + type: { + name: "String" + } + }, + staticIp: { + serializedName: "properties.staticIp", + type: { + name: "String" + } + }, + daprAIConnectionString: { + serializedName: "properties.daprAIConnectionString", + type: { + name: "String" } } } diff --git a/sdk/app/arm-app/src/models/parameters.ts b/sdk/app/arm-app/src/models/parameters.ts index a6906ce53457..add028e808ce 100644 --- a/sdk/app/arm-app/src/models/parameters.ts +++ b/sdk/app/arm-app/src/models/parameters.ts @@ -12,16 +12,17 @@ import { OperationQueryParameter } from "@azure/core-client"; import { + AuthConfig as AuthConfigMapper, ContainerApp as ContainerAppMapper, - ContainerAppPatch as ContainerAppPatchMapper, + DaprComponent as DaprComponentMapper, ManagedEnvironment as ManagedEnvironmentMapper, - ManagedEnvironmentPatch as ManagedEnvironmentPatchMapper, Certificate as CertificateMapper, CertificatePatch as CertificatePatchMapper, + CheckNameAvailabilityRequest as CheckNameAvailabilityRequestMapper, + ManagedEnvironmentStorage as ManagedEnvironmentStorageMapper, SourceControl as SourceControlMapper, - DaprComponent as DaprComponentMapper, - AuthConfig as AuthConfigMapper, - ManagedEnvironmentStorage as ManagedEnvironmentStorageMapper + ConnectedEnvironment as ConnectedEnvironmentMapper, + ConnectedEnvironmentStorage as ConnectedEnvironmentStorageMapper } from "../models/mappers"; export const accept: OperationParameter = { @@ -62,18 +63,6 @@ export const subscriptionId: OperationURLParameter = { } }; -export const apiVersion: OperationQueryParameter = { - parameterPath: "apiVersion", - mapper: { - defaultValue: "2022-01-01-preview", - isConstant: true, - serializedName: "api-version", - type: { - name: "String" - } - } -}; - export const resourceGroupName: OperationURLParameter = { parameterPath: "resourceGroupName", mapper: { @@ -89,10 +78,33 @@ export const resourceGroupName: OperationURLParameter = { } }; -export const name: OperationURLParameter = { - parameterPath: "name", +export const containerAppName: OperationURLParameter = { + parameterPath: "containerAppName", mapper: { - serializedName: "name", + serializedName: "containerAppName", + required: true, + type: { + name: "String" + } + } +}; + +export const apiVersion: OperationQueryParameter = { + parameterPath: "apiVersion", + mapper: { + defaultValue: "2022-06-01-preview", + isConstant: true, + serializedName: "api-version", + type: { + name: "String" + } + } +}; + +export const authConfigName: OperationURLParameter = { + parameterPath: "authConfigName", + mapper: { + serializedName: "authConfigName", required: true, type: { name: "String" @@ -112,20 +124,52 @@ export const contentType: OperationParameter = { } }; +export const authConfigEnvelope: OperationParameter = { + parameterPath: "authConfigEnvelope", + mapper: AuthConfigMapper +}; + +export const nextLink: OperationURLParameter = { + parameterPath: "nextLink", + mapper: { + serializedName: "nextLink", + required: true, + type: { + name: "String" + } + }, + skipEncoding: true +}; + export const containerAppEnvelope: OperationParameter = { parameterPath: "containerAppEnvelope", mapper: ContainerAppMapper }; -export const containerAppEnvelope1: OperationParameter = { - parameterPath: "containerAppEnvelope", - mapper: ContainerAppPatchMapper +export const customHostname: OperationQueryParameter = { + parameterPath: ["options", "customHostname"], + mapper: { + serializedName: "customHostname", + type: { + name: "String" + } + } }; -export const containerAppName: OperationURLParameter = { - parameterPath: "containerAppName", +export const filter: OperationQueryParameter = { + parameterPath: ["options", "filter"], mapper: { - serializedName: "containerAppName", + serializedName: "$filter", + type: { + name: "String" + } + } +}; + +export const revisionName: OperationURLParameter = { + parameterPath: "revisionName", + mapper: { + serializedName: "revisionName", required: true, type: { name: "String" @@ -133,32 +177,32 @@ export const containerAppName: OperationURLParameter = { } }; -export const customHostname: OperationQueryParameter = { - parameterPath: ["options", "customHostname"], +export const replicaName: OperationURLParameter = { + parameterPath: "replicaName", mapper: { - serializedName: "customHostname", + serializedName: "replicaName", + required: true, type: { name: "String" } } }; -export const nextLink: OperationURLParameter = { - parameterPath: "nextLink", +export const environmentName: OperationURLParameter = { + parameterPath: "environmentName", mapper: { - serializedName: "nextLink", + serializedName: "environmentName", required: true, type: { name: "String" } - }, - skipEncoding: true + } }; -export const revisionName: OperationURLParameter = { - parameterPath: "revisionName", +export const componentName: OperationURLParameter = { + parameterPath: "componentName", mapper: { - serializedName: "revisionName", + serializedName: "componentName", required: true, type: { name: "String" @@ -166,20 +210,31 @@ export const revisionName: OperationURLParameter = { } }; -export const environmentEnvelope: OperationParameter = { - parameterPath: "environmentEnvelope", - mapper: ManagedEnvironmentMapper +export const daprComponentEnvelope: OperationParameter = { + parameterPath: "daprComponentEnvelope", + mapper: DaprComponentMapper }; -export const environmentEnvelope1: OperationParameter = { +export const detectorName: OperationURLParameter = { + parameterPath: "detectorName", + mapper: { + serializedName: "detectorName", + required: true, + type: { + name: "String" + } + } +}; + +export const environmentEnvelope: OperationParameter = { parameterPath: "environmentEnvelope", - mapper: ManagedEnvironmentPatchMapper + mapper: ManagedEnvironmentMapper }; -export const managedEnvironmentName: OperationURLParameter = { - parameterPath: "managedEnvironmentName", +export const certificateName: OperationURLParameter = { + parameterPath: "certificateName", mapper: { - serializedName: "managedEnvironmentName", + serializedName: "certificateName", required: true, type: { name: "String" @@ -197,15 +252,15 @@ export const certificateEnvelope1: OperationParameter = { mapper: CertificatePatchMapper }; -export const sourceControlEnvelope: OperationParameter = { - parameterPath: "sourceControlEnvelope", - mapper: SourceControlMapper +export const checkNameAvailabilityRequest: OperationParameter = { + parameterPath: "checkNameAvailabilityRequest", + mapper: CheckNameAvailabilityRequestMapper }; -export const environmentName: OperationURLParameter = { - parameterPath: "environmentName", +export const storageName: OperationURLParameter = { + parameterPath: "storageName", mapper: { - serializedName: "environmentName", + serializedName: "storageName", required: true, type: { name: "String" @@ -213,20 +268,31 @@ export const environmentName: OperationURLParameter = { } }; -export const daprComponentEnvelope: OperationParameter = { - parameterPath: "daprComponentEnvelope", - mapper: DaprComponentMapper +export const storageEnvelope: OperationParameter = { + parameterPath: "storageEnvelope", + mapper: ManagedEnvironmentStorageMapper }; -export const authConfigEnvelope: OperationParameter = { - parameterPath: "authConfigEnvelope", - mapper: AuthConfigMapper +export const sourceControlName: OperationURLParameter = { + parameterPath: "sourceControlName", + mapper: { + serializedName: "sourceControlName", + required: true, + type: { + name: "String" + } + } }; -export const envName: OperationURLParameter = { - parameterPath: "envName", +export const sourceControlEnvelope: OperationParameter = { + parameterPath: "sourceControlEnvelope", + mapper: SourceControlMapper +}; + +export const connectedEnvironmentName: OperationURLParameter = { + parameterPath: "connectedEnvironmentName", mapper: { - serializedName: "envName", + serializedName: "connectedEnvironmentName", required: true, type: { name: "String" @@ -234,7 +300,12 @@ export const envName: OperationURLParameter = { } }; -export const storageEnvelope: OperationParameter = { +export const environmentEnvelope1: OperationParameter = { + parameterPath: "environmentEnvelope", + mapper: ConnectedEnvironmentMapper +}; + +export const storageEnvelope1: OperationParameter = { parameterPath: "storageEnvelope", - mapper: ManagedEnvironmentStorageMapper + mapper: ConnectedEnvironmentStorageMapper }; diff --git a/sdk/app/arm-app/src/operations/certificates.ts b/sdk/app/arm-app/src/operations/certificates.ts index 3ab40f888e93..8dda7b4fc8b1 100644 --- a/sdk/app/arm-app/src/operations/certificates.ts +++ b/sdk/app/arm-app/src/operations/certificates.ts @@ -44,17 +44,17 @@ export class CertificatesImpl implements Certificates { /** * Get the Certificates in a given managed environment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. + * @param environmentName Name of the Managed Environment. * @param options The options parameters. */ public list( resourceGroupName: string, - managedEnvironmentName: string, + environmentName: string, options?: CertificatesListOptionalParams ): PagedAsyncIterableIterator { const iter = this.listPagingAll( resourceGroupName, - managedEnvironmentName, + environmentName, options ); return { @@ -65,31 +65,23 @@ export class CertificatesImpl implements Certificates { return this; }, byPage: () => { - return this.listPagingPage( - resourceGroupName, - managedEnvironmentName, - options - ); + return this.listPagingPage(resourceGroupName, environmentName, options); } }; } private async *listPagingPage( resourceGroupName: string, - managedEnvironmentName: string, + environmentName: string, options?: CertificatesListOptionalParams ): AsyncIterableIterator { - let result = await this._list( - resourceGroupName, - managedEnvironmentName, - options - ); + let result = await this._list(resourceGroupName, environmentName, options); yield result.value || []; let continuationToken = result.nextLink; while (continuationToken) { result = await this._listNext( resourceGroupName, - managedEnvironmentName, + environmentName, continuationToken, options ); @@ -100,12 +92,12 @@ export class CertificatesImpl implements Certificates { private async *listPagingAll( resourceGroupName: string, - managedEnvironmentName: string, + environmentName: string, options?: CertificatesListOptionalParams ): AsyncIterableIterator { for await (const page of this.listPagingPage( resourceGroupName, - managedEnvironmentName, + environmentName, options )) { yield* page; @@ -115,16 +107,16 @@ export class CertificatesImpl implements Certificates { /** * Get the Certificates in a given managed environment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. + * @param environmentName Name of the Managed Environment. * @param options The options parameters. */ private _list( resourceGroupName: string, - managedEnvironmentName: string, + environmentName: string, options?: CertificatesListOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, managedEnvironmentName, options }, + { resourceGroupName, environmentName, options }, listOperationSpec ); } @@ -132,18 +124,18 @@ export class CertificatesImpl implements Certificates { /** * Get the specified Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ get( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, managedEnvironmentName, name, options }, + { resourceGroupName, environmentName, certificateName, options }, getOperationSpec ); } @@ -151,18 +143,18 @@ export class CertificatesImpl implements Certificates { /** * Create or Update a Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesCreateOrUpdateOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, managedEnvironmentName, name, options }, + { resourceGroupName, environmentName, certificateName, options }, createOrUpdateOperationSpec ); } @@ -170,18 +162,18 @@ export class CertificatesImpl implements Certificates { /** * Deletes the specified Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ delete( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesDeleteOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, managedEnvironmentName, name, options }, + { resourceGroupName, environmentName, certificateName, options }, deleteOperationSpec ); } @@ -189,23 +181,23 @@ export class CertificatesImpl implements Certificates { /** * Patches a certificate. Currently only patching of tags is supported * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param certificateEnvelope Properties of a certificate that need to be updated * @param options The options parameters. */ update( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, certificateEnvelope: CertificatePatch, options?: CertificatesUpdateOptionalParams ): Promise { return this.client.sendOperationRequest( { resourceGroupName, - managedEnvironmentName, - name, + environmentName, + certificateName, certificateEnvelope, options }, @@ -216,18 +208,18 @@ export class CertificatesImpl implements Certificates { /** * ListNext * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. + * @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, - managedEnvironmentName: string, + environmentName: string, nextLink: string, options?: CertificatesListNextOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, managedEnvironmentName, nextLink, options }, + { resourceGroupName, environmentName, nextLink, options }, listNextOperationSpec ); } @@ -237,7 +229,7 @@ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName}/certificates", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/certificates", httpMethod: "GET", responses: { 200: { @@ -252,14 +244,14 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.managedEnvironmentName + Parameters.environmentName ], headerParameters: [Parameters.accept], serializer }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName}/certificates/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/certificates/{certificateName}", httpMethod: "GET", responses: { 200: { @@ -274,15 +266,15 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.managedEnvironmentName + Parameters.environmentName, + Parameters.certificateName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName}/certificates/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/certificates/{certificateName}", httpMethod: "PUT", responses: { 200: { @@ -298,8 +290,8 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.managedEnvironmentName + Parameters.environmentName, + Parameters.certificateName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -307,7 +299,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName}/certificates/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/certificates/{certificateName}", httpMethod: "DELETE", responses: { 200: {}, @@ -321,15 +313,15 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.managedEnvironmentName + Parameters.environmentName, + Parameters.certificateName ], headerParameters: [Parameters.accept], serializer }; const updateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{managedEnvironmentName}/certificates/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/certificates/{certificateName}", httpMethod: "PATCH", responses: { 200: { @@ -345,8 +337,8 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.managedEnvironmentName + Parameters.environmentName, + Parameters.certificateName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -369,7 +361,7 @@ const listNextOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.nextLink, - Parameters.managedEnvironmentName + Parameters.environmentName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/connectedEnvironments.ts b/sdk/app/arm-app/src/operations/connectedEnvironments.ts new file mode 100644 index 000000000000..238500ce39f0 --- /dev/null +++ b/sdk/app/arm-app/src/operations/connectedEnvironments.ts @@ -0,0 +1,649 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { ConnectedEnvironments } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro"; +import { LroImpl } from "../lroImpl"; +import { + ConnectedEnvironment, + ConnectedEnvironmentsListBySubscriptionNextOptionalParams, + ConnectedEnvironmentsListBySubscriptionOptionalParams, + ConnectedEnvironmentsListByResourceGroupNextOptionalParams, + ConnectedEnvironmentsListByResourceGroupOptionalParams, + ConnectedEnvironmentsListBySubscriptionResponse, + ConnectedEnvironmentsListByResourceGroupResponse, + ConnectedEnvironmentsGetOptionalParams, + ConnectedEnvironmentsGetResponse, + ConnectedEnvironmentsCreateOrUpdateOptionalParams, + ConnectedEnvironmentsCreateOrUpdateResponse, + ConnectedEnvironmentsDeleteOptionalParams, + ConnectedEnvironmentsUpdateOptionalParams, + ConnectedEnvironmentsUpdateResponse, + CheckNameAvailabilityRequest, + ConnectedEnvironmentsCheckNameAvailabilityOptionalParams, + ConnectedEnvironmentsCheckNameAvailabilityResponse, + ConnectedEnvironmentsListBySubscriptionNextResponse, + ConnectedEnvironmentsListByResourceGroupNextResponse +} from "../models"; + +/// +/** Class containing ConnectedEnvironments operations. */ +export class ConnectedEnvironmentsImpl implements ConnectedEnvironments { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ConnectedEnvironments class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get all connectedEnvironments for a subscription. + * @param options The options parameters. + */ + public listBySubscription( + options?: ConnectedEnvironmentsListBySubscriptionOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listBySubscriptionPagingAll(options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listBySubscriptionPagingPage(options); + } + }; + } + + private async *listBySubscriptionPagingPage( + options?: ConnectedEnvironmentsListBySubscriptionOptionalParams + ): AsyncIterableIterator { + let result = await this._listBySubscription(options); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listBySubscriptionNext(continuationToken, options); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listBySubscriptionPagingAll( + options?: ConnectedEnvironmentsListBySubscriptionOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listBySubscriptionPagingPage(options)) { + yield* page; + } + } + + /** + * Get all connectedEnvironments in a 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?: ConnectedEnvironmentsListByResourceGroupOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listByResourceGroupPagingPage(resourceGroupName, options); + } + }; + } + + private async *listByResourceGroupPagingPage( + resourceGroupName: string, + options?: ConnectedEnvironmentsListByResourceGroupOptionalParams + ): AsyncIterableIterator { + let result = await this._listByResourceGroup(resourceGroupName, options); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listByResourceGroupNext( + resourceGroupName, + continuationToken, + options + ); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listByResourceGroupPagingAll( + resourceGroupName: string, + options?: ConnectedEnvironmentsListByResourceGroupOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listByResourceGroupPagingPage( + resourceGroupName, + options + )) { + yield* page; + } + } + + /** + * Get all connectedEnvironments for a subscription. + * @param options The options parameters. + */ + private _listBySubscription( + options?: ConnectedEnvironmentsListBySubscriptionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { options }, + listBySubscriptionOperationSpec + ); + } + + /** + * Get all connectedEnvironments in a 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?: ConnectedEnvironmentsListByResourceGroupOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, options }, + listByResourceGroupOperationSpec + ); + } + + /** + * Get the properties of an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, options }, + getOperationSpec + ); + } + + /** + * Creates or updates an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param environmentEnvelope Configuration details of the connectedEnvironment. + * @param options The options parameters. + */ + async beginCreateOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + environmentEnvelope: ConnectedEnvironment, + options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams + ): Promise< + PollerLike< + PollOperationState, + ConnectedEnvironmentsCreateOrUpdateResponse + > + > { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperation = 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 = new LroImpl( + sendOperation, + { + resourceGroupName, + connectedEnvironmentName, + environmentEnvelope, + options + }, + createOrUpdateOperationSpec + ); + const poller = new LroEngine(lro, { + resumeFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs + }); + await poller.poll(); + return poller; + } + + /** + * Creates or updates an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param environmentEnvelope Configuration details of the connectedEnvironment. + * @param options The options parameters. + */ + async beginCreateOrUpdateAndWait( + resourceGroupName: string, + connectedEnvironmentName: string, + environmentEnvelope: ConnectedEnvironment, + options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams + ): Promise { + const poller = await this.beginCreateOrUpdate( + resourceGroupName, + connectedEnvironmentName, + environmentEnvelope, + options + ); + return poller.pollUntilDone(); + } + + /** + * Delete an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + async beginDelete( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDeleteOptionalParams + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperation = 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 = new LroImpl( + sendOperation, + { resourceGroupName, connectedEnvironmentName, options }, + deleteOperationSpec + ); + const poller = new LroEngine(lro, { + resumeFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs + }); + await poller.poll(); + return poller; + } + + /** + * Delete an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + async beginDeleteAndWait( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDeleteOptionalParams + ): Promise { + const poller = await this.beginDelete( + resourceGroupName, + connectedEnvironmentName, + options + ); + return poller.pollUntilDone(); + } + + /** + * Patches a Managed Environment. Only patching of tags is supported currently + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + update( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, options }, + updateOperationSpec + ); + } + + /** + * Checks if resource connectedEnvironmentName is available. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Managed Environment. + * @param checkNameAvailabilityRequest The check connectedEnvironmentName availability request. + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + connectedEnvironmentName: string, + checkNameAvailabilityRequest: CheckNameAvailabilityRequest, + options?: ConnectedEnvironmentsCheckNameAvailabilityOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + connectedEnvironmentName, + checkNameAvailabilityRequest, + options + }, + checkNameAvailabilityOperationSpec + ); + } + + /** + * ListBySubscriptionNext + * @param nextLink The nextLink from the previous successful call to the ListBySubscription method. + * @param options The options parameters. + */ + private _listBySubscriptionNext( + nextLink: string, + options?: ConnectedEnvironmentsListBySubscriptionNextOptionalParams + ): 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?: ConnectedEnvironmentsListByResourceGroupNextOptionalParams + ): 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/connectedEnvironments", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.subscriptionId], + headerParameters: [Parameters.accept], + serializer +}; +const listByResourceGroupOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + 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/connectedEnvironments/{connectedEnvironmentName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironment + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironment + }, + 201: { + bodyMapper: Mappers.ConnectedEnvironment + }, + 202: { + bodyMapper: Mappers.ConnectedEnvironment + }, + 204: { + bodyMapper: Mappers.ConnectedEnvironment + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.environmentEnvelope1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 201: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const updateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironment + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/checkNameAvailability", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.CheckNameAvailabilityResponse + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.checkNameAvailabilityRequest, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/connectedEnvironmentsCertificates.ts b/sdk/app/arm-app/src/operations/connectedEnvironmentsCertificates.ts new file mode 100644 index 000000000000..4cd06d61f734 --- /dev/null +++ b/sdk/app/arm-app/src/operations/connectedEnvironmentsCertificates.ts @@ -0,0 +1,377 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { ConnectedEnvironmentsCertificates } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + Certificate, + ConnectedEnvironmentsCertificatesListNextOptionalParams, + ConnectedEnvironmentsCertificatesListOptionalParams, + ConnectedEnvironmentsCertificatesListResponse, + ConnectedEnvironmentsCertificatesGetOptionalParams, + ConnectedEnvironmentsCertificatesGetResponse, + ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams, + ConnectedEnvironmentsCertificatesCreateOrUpdateResponse, + ConnectedEnvironmentsCertificatesDeleteOptionalParams, + CertificatePatch, + ConnectedEnvironmentsCertificatesUpdateOptionalParams, + ConnectedEnvironmentsCertificatesUpdateResponse, + ConnectedEnvironmentsCertificatesListNextResponse +} from "../models"; + +/// +/** Class containing ConnectedEnvironmentsCertificates operations. */ +export class ConnectedEnvironmentsCertificatesImpl + implements ConnectedEnvironmentsCertificates { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ConnectedEnvironmentsCertificates class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get the Certificates in a given connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param options The options parameters. + */ + public list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsCertificatesListOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll( + resourceGroupName, + connectedEnvironmentName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listPagingPage( + resourceGroupName, + connectedEnvironmentName, + options + ); + } + }; + } + + private async *listPagingPage( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsCertificatesListOptionalParams + ): AsyncIterableIterator { + let result = await this._list( + resourceGroupName, + connectedEnvironmentName, + options + ); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listNext( + resourceGroupName, + connectedEnvironmentName, + continuationToken, + options + ); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listPagingAll( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsCertificatesListOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + resourceGroupName, + connectedEnvironmentName, + options + )) { + yield* page; + } + } + + /** + * Get the Certificates in a given connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param options The options parameters. + */ + private _list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsCertificatesListOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, options }, + listOperationSpec + ); + } + + /** + * Get the specified Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, certificateName, options }, + getOperationSpec + ); + } + + /** + * Create or Update a Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, certificateName, options }, + createOrUpdateOperationSpec + ); + } + + /** + * Deletes the specified Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, certificateName, options }, + deleteOperationSpec + ); + } + + /** + * Patches a certificate. Currently only patching of tags is supported + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param certificateEnvelope Properties of a certificate that need to be updated + * @param options The options parameters. + */ + update( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + certificateEnvelope: CertificatePatch, + options?: ConnectedEnvironmentsCertificatesUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + connectedEnvironmentName, + certificateName, + certificateEnvelope, + options + }, + updateOperationSpec + ); + } + + /** + * ListNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + resourceGroupName: string, + connectedEnvironmentName: string, + nextLink: string, + options?: ConnectedEnvironmentsCertificatesListNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, nextLink, options }, + listNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/certificates", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.CertificateCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/certificates/{certificateName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Certificate + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.certificateName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/certificates/{certificateName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Certificate + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.certificateEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.certificateName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/certificates/{certificateName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.certificateName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const updateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/certificates/{certificateName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.Certificate + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.certificateEnvelope1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.certificateName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.CertificateCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.nextLink, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/connectedEnvironmentsDaprComponents.ts b/sdk/app/arm-app/src/operations/connectedEnvironmentsDaprComponents.ts new file mode 100644 index 000000000000..31e35fc554a9 --- /dev/null +++ b/sdk/app/arm-app/src/operations/connectedEnvironmentsDaprComponents.ts @@ -0,0 +1,374 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { ConnectedEnvironmentsDaprComponents } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + DaprComponent, + ConnectedEnvironmentsDaprComponentsListNextOptionalParams, + ConnectedEnvironmentsDaprComponentsListOptionalParams, + ConnectedEnvironmentsDaprComponentsListResponse, + ConnectedEnvironmentsDaprComponentsGetOptionalParams, + ConnectedEnvironmentsDaprComponentsGetResponse, + ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams, + ConnectedEnvironmentsDaprComponentsCreateOrUpdateResponse, + ConnectedEnvironmentsDaprComponentsDeleteOptionalParams, + ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams, + ConnectedEnvironmentsDaprComponentsListSecretsResponse, + ConnectedEnvironmentsDaprComponentsListNextResponse +} from "../models"; + +/// +/** Class containing ConnectedEnvironmentsDaprComponents operations. */ +export class ConnectedEnvironmentsDaprComponentsImpl + implements ConnectedEnvironmentsDaprComponents { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ConnectedEnvironmentsDaprComponents class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get the Dapr Components for a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param options The options parameters. + */ + public list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDaprComponentsListOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll( + resourceGroupName, + connectedEnvironmentName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listPagingPage( + resourceGroupName, + connectedEnvironmentName, + options + ); + } + }; + } + + private async *listPagingPage( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDaprComponentsListOptionalParams + ): AsyncIterableIterator { + let result = await this._list( + resourceGroupName, + connectedEnvironmentName, + options + ); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listNext( + resourceGroupName, + connectedEnvironmentName, + continuationToken, + options + ); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listPagingAll( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDaprComponentsListOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + resourceGroupName, + connectedEnvironmentName, + options + )) { + yield* page; + } + } + + /** + * Get the Dapr Components for a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param options The options parameters. + */ + private _list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDaprComponentsListOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, options }, + listOperationSpec + ); + } + + /** + * Get a dapr component. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, componentName, options }, + getOperationSpec + ); + } + + /** + * Creates or updates a Dapr Component in a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param daprComponentEnvelope Configuration details of the Dapr Component. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + daprComponentEnvelope: DaprComponent, + options?: ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + connectedEnvironmentName, + componentName, + daprComponentEnvelope, + options + }, + createOrUpdateOperationSpec + ); + } + + /** + * Delete a Dapr Component from a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, componentName, options }, + deleteOperationSpec + ); + } + + /** + * List secrets for a dapr component + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + listSecrets( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, componentName, options }, + listSecretsOperationSpec + ); + } + + /** + * ListNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + resourceGroupName: string, + connectedEnvironmentName: string, + nextLink: string, + options?: ConnectedEnvironmentsDaprComponentsListNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, nextLink, options }, + listNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/daprComponents", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DaprComponentsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/daprComponents/{componentName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DaprComponent + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.componentName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/daprComponents/{componentName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.DaprComponent + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.daprComponentEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.componentName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/daprComponents/{componentName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.componentName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listSecretsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/daprComponents/{componentName}/listSecrets", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DaprSecretsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.componentName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DaprComponentsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.nextLink, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/connectedEnvironmentsStorages.ts b/sdk/app/arm-app/src/operations/connectedEnvironmentsStorages.ts new file mode 100644 index 000000000000..e1f12b3c7f33 --- /dev/null +++ b/sdk/app/arm-app/src/operations/connectedEnvironmentsStorages.ts @@ -0,0 +1,214 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { ConnectedEnvironmentsStorages } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + ConnectedEnvironmentsStoragesListOptionalParams, + ConnectedEnvironmentsStoragesListResponse, + ConnectedEnvironmentsStoragesGetOptionalParams, + ConnectedEnvironmentsStoragesGetResponse, + ConnectedEnvironmentStorage, + ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams, + ConnectedEnvironmentsStoragesCreateOrUpdateResponse, + ConnectedEnvironmentsStoragesDeleteOptionalParams +} from "../models"; + +/** Class containing ConnectedEnvironmentsStorages operations. */ +export class ConnectedEnvironmentsStoragesImpl + implements ConnectedEnvironmentsStorages { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ConnectedEnvironmentsStorages class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get all storages for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsStoragesListOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, options }, + listOperationSpec + ); + } + + /** + * Get storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + options?: ConnectedEnvironmentsStoragesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, storageName, options }, + getOperationSpec + ); + } + + /** + * Create or update storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param storageEnvelope Configuration details of storage. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + storageEnvelope: ConnectedEnvironmentStorage, + options?: ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + connectedEnvironmentName, + storageName, + storageEnvelope, + options + }, + createOrUpdateOperationSpec + ); + } + + /** + * Delete storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + options?: ConnectedEnvironmentsStoragesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, connectedEnvironmentName, storageName, options }, + deleteOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/storages", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentStoragesCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/storages/{storageName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentStorage + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.storageName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/storages/{storageName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.ConnectedEnvironmentStorage + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.storageEnvelope1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.storageName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/connectedEnvironments/{connectedEnvironmentName}/storages/{storageName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.storageName, + Parameters.connectedEnvironmentName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/containerApps.ts b/sdk/app/arm-app/src/operations/containerApps.ts index 5dd86d9c6702..8bdfb89a7856 100644 --- a/sdk/app/arm-app/src/operations/containerApps.ts +++ b/sdk/app/arm-app/src/operations/containerApps.ts @@ -27,9 +27,7 @@ import { ContainerAppsCreateOrUpdateOptionalParams, ContainerAppsCreateOrUpdateResponse, ContainerAppsDeleteOptionalParams, - ContainerAppPatch, ContainerAppsUpdateOptionalParams, - ContainerAppsUpdateResponse, ContainerAppsListCustomHostNameAnalysisOptionalParams, ContainerAppsListCustomHostNameAnalysisResponse, ContainerAppsListSecretsOptionalParams, @@ -177,30 +175,30 @@ export class ContainerAppsImpl implements ContainerApps { /** * Get the properties of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ get( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, options }, + { resourceGroupName, containerAppName, options }, getOperationSpec ); } /** - * Description for Create or update a Container App. + * Create or update a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param containerAppEnvelope Properties used to create a container app * @param options The options parameters. */ async beginCreateOrUpdate( resourceGroupName: string, - name: string, + containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise< @@ -250,7 +248,7 @@ export class ContainerAppsImpl implements ContainerApps { const lro = new LroImpl( sendOperation, - { resourceGroupName, name, containerAppEnvelope, options }, + { resourceGroupName, containerAppName, containerAppEnvelope, options }, createOrUpdateOperationSpec ); const poller = new LroEngine(lro, { @@ -262,21 +260,21 @@ export class ContainerAppsImpl implements ContainerApps { } /** - * Description for Create or update a Container App. + * Create or update a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param containerAppEnvelope Properties used to create a container app * @param options The options parameters. */ async beginCreateOrUpdateAndWait( resourceGroupName: string, - name: string, + containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, - name, + containerAppName, containerAppEnvelope, options ); @@ -284,14 +282,14 @@ export class ContainerAppsImpl implements ContainerApps { } /** - * Description for Delete a Container App. + * Delete a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ async beginDelete( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsDeleteOptionalParams ): Promise, void>> { const directSendOperation = async ( @@ -335,7 +333,7 @@ export class ContainerAppsImpl implements ContainerApps { const lro = new LroImpl( sendOperation, - { resourceGroupName, name, options }, + { resourceGroupName, containerAppName, options }, deleteOperationSpec ); const poller = new LroEngine(lro, { @@ -347,37 +345,109 @@ export class ContainerAppsImpl implements ContainerApps { } /** - * Description for Delete a Container App. + * Delete a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ async beginDeleteAndWait( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsDeleteOptionalParams ): Promise { - const poller = await this.beginDelete(resourceGroupName, name, options); + const poller = await this.beginDelete( + resourceGroupName, + containerAppName, + options + ); return poller.pollUntilDone(); } /** - * Patches a Container App. Currently only patching of tags is supported + * Patches a Container App using JSON Merge Patch * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. - * @param containerAppEnvelope Properties of a container app that need to be updated + * @param containerAppName Name of the Container App. + * @param containerAppEnvelope Properties of a Container App that need to be updated * @param options The options parameters. */ - update( + async beginUpdate( resourceGroupName: string, - name: string, - containerAppEnvelope: ContainerAppPatch, + containerAppName: string, + containerAppEnvelope: ContainerApp, options?: ContainerAppsUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, name, containerAppEnvelope, options }, + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperation = 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 = new LroImpl( + sendOperation, + { resourceGroupName, containerAppName, containerAppEnvelope, options }, updateOperationSpec ); + const poller = new LroEngine(lro, { + resumeFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs + }); + await poller.poll(); + return poller; + } + + /** + * Patches a Container App using JSON Merge Patch + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param containerAppEnvelope Properties of a Container App that need to be updated + * @param options The options parameters. + */ + async beginUpdateAndWait( + resourceGroupName: string, + containerAppName: string, + containerAppEnvelope: ContainerApp, + options?: ContainerAppsUpdateOptionalParams + ): Promise { + const poller = await this.beginUpdate( + resourceGroupName, + containerAppName, + containerAppEnvelope, + options + ); + return poller.pollUntilDone(); } /** @@ -400,16 +470,16 @@ export class ContainerAppsImpl implements ContainerApps { /** * List secrets for a container app * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ listSecrets( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsListSecretsOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, options }, + { resourceGroupName, containerAppName, options }, listSecretsOperationSpec ); } @@ -488,7 +558,7 @@ const listByResourceGroupOperationSpec: coreClient.OperationSpec = { }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}", httpMethod: "GET", responses: { 200: { @@ -506,14 +576,14 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.containerAppName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}", httpMethod: "PUT", responses: { 200: { @@ -538,7 +608,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.containerAppName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -546,7 +616,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}", httpMethod: "DELETE", responses: { 200: {}, @@ -562,30 +632,31 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.containerAppName ], headerParameters: [Parameters.accept], serializer }; const updateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}", httpMethod: "PATCH", responses: { - 200: { - bodyMapper: Mappers.ContainerApp - }, + 200: {}, + 201: {}, + 202: {}, + 204: {}, default: { bodyMapper: Mappers.DefaultErrorResponse } }, - requestBody: Parameters.containerAppEnvelope1, + requestBody: Parameters.containerAppEnvelope, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.containerAppName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -615,7 +686,7 @@ const listCustomHostNameAnalysisOperationSpec: coreClient.OperationSpec = { }; const listSecretsOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{name}/listSecrets", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/listSecrets", httpMethod: "POST", responses: { 200: { @@ -630,7 +701,7 @@ const listSecretsOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.containerAppName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/containerAppsAuthConfigs.ts b/sdk/app/arm-app/src/operations/containerAppsAuthConfigs.ts index f93d931aa6b8..eb5da145c1e1 100644 --- a/sdk/app/arm-app/src/operations/containerAppsAuthConfigs.ts +++ b/sdk/app/arm-app/src/operations/containerAppsAuthConfigs.ts @@ -130,33 +130,33 @@ export class ContainerAppsAuthConfigsImpl implements ContainerAppsAuthConfigs { * Get a AuthConfig of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param options The options parameters. */ get( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, options?: ContainerAppsAuthConfigsGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, authConfigName, options }, getOperationSpec ); } /** - * Description for Create or update the AuthConfig for a Container App. + * Create or update the AuthConfig for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param authConfigEnvelope Properties used to create a Container App AuthConfig * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, authConfigEnvelope: AuthConfig, options?: ContainerAppsAuthConfigsCreateOrUpdateOptionalParams ): Promise { @@ -164,7 +164,7 @@ export class ContainerAppsAuthConfigsImpl implements ContainerAppsAuthConfigs { { resourceGroupName, containerAppName, - name, + authConfigName, authConfigEnvelope, options }, @@ -173,20 +173,20 @@ export class ContainerAppsAuthConfigsImpl implements ContainerAppsAuthConfigs { } /** - * Description for Delete a Container App AuthConfig. + * Delete a Container App AuthConfig. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param options The options parameters. */ delete( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, options?: ContainerAppsAuthConfigsDeleteOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, authConfigName, options }, deleteOperationSpec ); } @@ -237,7 +237,7 @@ const listByContainerAppOperationSpec: coreClient.OperationSpec = { }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{authConfigName}", httpMethod: "GET", responses: { 200: { @@ -252,15 +252,15 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.authConfigName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{authConfigName}", httpMethod: "PUT", responses: { 200: { @@ -276,8 +276,8 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.authConfigName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -285,7 +285,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/authConfigs/{authConfigName}", httpMethod: "DELETE", responses: { 200: {}, @@ -299,8 +299,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.authConfigName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/containerAppsDiagnostics.ts b/sdk/app/arm-app/src/operations/containerAppsDiagnostics.ts new file mode 100644 index 000000000000..adeff5ff113d --- /dev/null +++ b/sdk/app/arm-app/src/operations/containerAppsDiagnostics.ts @@ -0,0 +1,477 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { ContainerAppsDiagnostics } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + Diagnostics, + ContainerAppsDiagnosticsListDetectorsNextOptionalParams, + ContainerAppsDiagnosticsListDetectorsOptionalParams, + Revision, + ContainerAppsDiagnosticsListRevisionsNextOptionalParams, + ContainerAppsDiagnosticsListRevisionsOptionalParams, + ContainerAppsDiagnosticsListDetectorsResponse, + ContainerAppsDiagnosticsGetDetectorOptionalParams, + ContainerAppsDiagnosticsGetDetectorResponse, + ContainerAppsDiagnosticsListRevisionsResponse, + ContainerAppsDiagnosticsGetRevisionOptionalParams, + ContainerAppsDiagnosticsGetRevisionResponse, + ContainerAppsDiagnosticsGetRootOptionalParams, + ContainerAppsDiagnosticsGetRootResponse, + ContainerAppsDiagnosticsListDetectorsNextResponse, + ContainerAppsDiagnosticsListRevisionsNextResponse +} from "../models"; + +/// +/** Class containing ContainerAppsDiagnostics operations. */ +export class ContainerAppsDiagnosticsImpl implements ContainerAppsDiagnostics { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ContainerAppsDiagnostics class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get the list of diagnostics for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which detector info is needed. + * @param options The options parameters. + */ + public listDetectors( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListDetectorsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listDetectorsPagingAll( + resourceGroupName, + containerAppName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listDetectorsPagingPage( + resourceGroupName, + containerAppName, + options + ); + } + }; + } + + private async *listDetectorsPagingPage( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListDetectorsOptionalParams + ): AsyncIterableIterator { + let result = await this._listDetectors( + resourceGroupName, + containerAppName, + options + ); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listDetectorsNext( + resourceGroupName, + containerAppName, + continuationToken, + options + ); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listDetectorsPagingAll( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListDetectorsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listDetectorsPagingPage( + resourceGroupName, + containerAppName, + options + )) { + yield* page; + } + } + + /** + * Get the Revisions for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which Revisions are needed. + * @param options The options parameters. + */ + public listRevisions( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListRevisionsOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listRevisionsPagingAll( + resourceGroupName, + containerAppName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: () => { + return this.listRevisionsPagingPage( + resourceGroupName, + containerAppName, + options + ); + } + }; + } + + private async *listRevisionsPagingPage( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListRevisionsOptionalParams + ): AsyncIterableIterator { + let result = await this._listRevisions( + resourceGroupName, + containerAppName, + options + ); + yield result.value || []; + let continuationToken = result.nextLink; + while (continuationToken) { + result = await this._listRevisionsNext( + resourceGroupName, + containerAppName, + continuationToken, + options + ); + continuationToken = result.nextLink; + yield result.value || []; + } + } + + private async *listRevisionsPagingAll( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListRevisionsOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listRevisionsPagingPage( + resourceGroupName, + containerAppName, + options + )) { + yield* page; + } + } + + /** + * Get the list of diagnostics for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which detector info is needed. + * @param options The options parameters. + */ + private _listDetectors( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListDetectorsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, options }, + listDetectorsOperationSpec + ); + } + + /** + * Get a diagnostics result of a Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param detectorName Name of the Container App Detector. + * @param options The options parameters. + */ + getDetector( + resourceGroupName: string, + containerAppName: string, + detectorName: string, + options?: ContainerAppsDiagnosticsGetDetectorOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, detectorName, options }, + getDetectorOperationSpec + ); + } + + /** + * Get the Revisions for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which Revisions are needed. + * @param options The options parameters. + */ + private _listRevisions( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListRevisionsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, options }, + listRevisionsOperationSpec + ); + } + + /** + * Get a revision of a 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. + * @param options The options parameters. + */ + getRevision( + resourceGroupName: string, + containerAppName: string, + revisionName: string, + options?: ContainerAppsDiagnosticsGetRevisionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, revisionName, options }, + getRevisionOperationSpec + ); + } + + /** + * Get the properties of a Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param options The options parameters. + */ + getRoot( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsGetRootOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, options }, + getRootOperationSpec + ); + } + + /** + * ListDetectorsNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which detector info is needed. + * @param nextLink The nextLink from the previous successful call to the ListDetectors method. + * @param options The options parameters. + */ + private _listDetectorsNext( + resourceGroupName: string, + containerAppName: string, + nextLink: string, + options?: ContainerAppsDiagnosticsListDetectorsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, nextLink, options }, + listDetectorsNextOperationSpec + ); + } + + /** + * ListRevisionsNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which Revisions are needed. + * @param nextLink The nextLink from the previous successful call to the ListRevisions method. + * @param options The options parameters. + */ + private _listRevisionsNext( + resourceGroupName: string, + containerAppName: string, + nextLink: string, + options?: ContainerAppsDiagnosticsListRevisionsNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, containerAppName, nextLink, options }, + listRevisionsNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listDetectorsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/detectors", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DiagnosticsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getDetectorOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/detectors/{detectorName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Diagnostics + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName, + Parameters.detectorName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listRevisionsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/detectorProperties/revisionsApi/revisions/", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.RevisionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion, Parameters.filter], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getRevisionOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/detectorProperties/revisionsApi/revisions/{revisionName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Revision + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName, + Parameters.revisionName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getRootOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/detectorProperties/rootApi/", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ContainerApp + }, + 404: { + isError: true + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listDetectorsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DiagnosticsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const listRevisionsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.RevisionCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion, Parameters.filter], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerAppName, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/containerAppsRevisionReplicas.ts b/sdk/app/arm-app/src/operations/containerAppsRevisionReplicas.ts index efb4bfc2191a..1367a4c2210a 100644 --- a/sdk/app/arm-app/src/operations/containerAppsRevisionReplicas.ts +++ b/sdk/app/arm-app/src/operations/containerAppsRevisionReplicas.ts @@ -36,18 +36,24 @@ export class ContainerAppsRevisionReplicasImpl * @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. - * @param name Name of the Container App Revision Replica. + * @param replicaName Name of the Container App Revision Replica. * @param options The options parameters. */ getReplica( resourceGroupName: string, containerAppName: string, revisionName: string, - name: string, + replicaName: string, options?: ContainerAppsRevisionReplicasGetReplicaOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, revisionName, name, options }, + { + resourceGroupName, + containerAppName, + revisionName, + replicaName, + options + }, getReplicaOperationSpec ); } @@ -76,7 +82,7 @@ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const getReplicaOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/replicas/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/replicas/{replicaName}", httpMethod: "GET", responses: { 200: { @@ -91,9 +97,9 @@ const getReplicaOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, Parameters.containerAppName, - Parameters.revisionName + Parameters.revisionName, + Parameters.replicaName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/containerAppsRevisions.ts b/sdk/app/arm-app/src/operations/containerAppsRevisions.ts index a84edd6c1fea..b110d86064a2 100644 --- a/sdk/app/arm-app/src/operations/containerAppsRevisions.ts +++ b/sdk/app/arm-app/src/operations/containerAppsRevisions.ts @@ -130,17 +130,17 @@ export class ContainerAppsRevisionsImpl implements ContainerAppsRevisions { * Get a revision of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ getRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsGetRevisionOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, revisionName, options }, getRevisionOperationSpec ); } @@ -149,17 +149,17 @@ export class ContainerAppsRevisionsImpl implements ContainerAppsRevisions { * Activates a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ activateRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsActivateRevisionOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, revisionName, options }, activateRevisionOperationSpec ); } @@ -168,17 +168,17 @@ export class ContainerAppsRevisionsImpl implements ContainerAppsRevisions { * Deactivates a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ deactivateRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsDeactivateRevisionOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, revisionName, options }, deactivateRevisionOperationSpec ); } @@ -187,17 +187,17 @@ export class ContainerAppsRevisionsImpl implements ContainerAppsRevisions { * Restarts a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ restartRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsRestartRevisionOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, revisionName, options }, restartRevisionOperationSpec ); } @@ -236,7 +236,7 @@ const listRevisionsOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], + queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -248,7 +248,7 @@ const listRevisionsOperationSpec: coreClient.OperationSpec = { }; const getRevisionOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}", httpMethod: "GET", responses: { 200: { @@ -263,15 +263,15 @@ const getRevisionOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.revisionName ], headerParameters: [Parameters.accept], serializer }; const activateRevisionOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{name}/activate", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/activate", httpMethod: "POST", responses: { 200: {}, @@ -284,15 +284,15 @@ const activateRevisionOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.revisionName ], headerParameters: [Parameters.accept], serializer }; const deactivateRevisionOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{name}/deactivate", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/deactivate", httpMethod: "POST", responses: { 200: {}, @@ -305,15 +305,15 @@ const deactivateRevisionOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.revisionName ], headerParameters: [Parameters.accept], serializer }; const restartRevisionOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{name}/restart", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/revisions/{revisionName}/restart", httpMethod: "POST", responses: { 200: {}, @@ -326,8 +326,8 @@ const restartRevisionOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.revisionName ], headerParameters: [Parameters.accept], serializer @@ -343,7 +343,7 @@ const listRevisionsNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.DefaultErrorResponse } }, - queryParameters: [Parameters.apiVersion], + queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/app/arm-app/src/operations/containerAppsSourceControls.ts b/sdk/app/arm-app/src/operations/containerAppsSourceControls.ts index 9861d0ebaa04..ab681c635ff1 100644 --- a/sdk/app/arm-app/src/operations/containerAppsSourceControls.ts +++ b/sdk/app/arm-app/src/operations/containerAppsSourceControls.ts @@ -133,33 +133,33 @@ export class ContainerAppsSourceControlsImpl * Get a SourceControl of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ get( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, sourceControlName, options }, getOperationSpec ); } /** - * Description for Create or update the SourceControl for a Container App. + * Create or update the SourceControl for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param sourceControlEnvelope Properties used to create a Container App SourceControl * @param options The options parameters. */ async beginCreateOrUpdate( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams ): Promise< @@ -212,7 +212,7 @@ export class ContainerAppsSourceControlsImpl { resourceGroupName, containerAppName, - name, + sourceControlName, sourceControlEnvelope, options }, @@ -227,24 +227,24 @@ export class ContainerAppsSourceControlsImpl } /** - * Description for Create or update the SourceControl for a Container App. + * Create or update the SourceControl for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param sourceControlEnvelope Properties used to create a Container App SourceControl * @param options The options parameters. */ async beginCreateOrUpdateAndWait( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, containerAppName, - name, + sourceControlName, sourceControlEnvelope, options ); @@ -252,16 +252,16 @@ export class ContainerAppsSourceControlsImpl } /** - * Description for Delete a Container App SourceControl. + * Delete a Container App SourceControl. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ async beginDelete( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams ): Promise, void>> { const directSendOperation = async ( @@ -305,7 +305,7 @@ export class ContainerAppsSourceControlsImpl const lro = new LroImpl( sendOperation, - { resourceGroupName, containerAppName, name, options }, + { resourceGroupName, containerAppName, sourceControlName, options }, deleteOperationSpec ); const poller = new LroEngine(lro, { @@ -317,22 +317,22 @@ export class ContainerAppsSourceControlsImpl } /** - * Description for Delete a Container App SourceControl. + * Delete a Container App SourceControl. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ async beginDeleteAndWait( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams ): Promise { const poller = await this.beginDelete( resourceGroupName, containerAppName, - name, + sourceControlName, options ); return poller.pollUntilDone(); @@ -384,7 +384,7 @@ const listByContainerAppOperationSpec: coreClient.OperationSpec = { }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{sourceControlName}", httpMethod: "GET", responses: { 200: { @@ -399,15 +399,15 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.sourceControlName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{sourceControlName}", httpMethod: "PUT", responses: { 200: { @@ -432,8 +432,8 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.sourceControlName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -441,7 +441,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{sourceControlName}", httpMethod: "DELETE", responses: { 200: {}, @@ -457,8 +457,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.containerAppName + Parameters.containerAppName, + Parameters.sourceControlName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/daprComponents.ts b/sdk/app/arm-app/src/operations/daprComponents.ts index 679e1501ec99..527966427907 100644 --- a/sdk/app/arm-app/src/operations/daprComponents.ts +++ b/sdk/app/arm-app/src/operations/daprComponents.ts @@ -22,6 +22,8 @@ import { DaprComponentsCreateOrUpdateOptionalParams, DaprComponentsCreateOrUpdateResponse, DaprComponentsDeleteOptionalParams, + DaprComponentsListSecretsOptionalParams, + DaprComponentsListSecretsResponse, DaprComponentsListNextResponse } from "../models"; @@ -122,17 +124,17 @@ export class DaprComponentsImpl implements DaprComponents { * Get a dapr 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 Dapr Component. + * @param componentName Name of the Dapr Component. * @param options The options parameters. */ get( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, options?: DaprComponentsGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, environmentName, name, options }, + { resourceGroupName, environmentName, componentName, options }, getOperationSpec ); } @@ -141,14 +143,14 @@ export class DaprComponentsImpl implements DaprComponents { * Creates or updates a Dapr 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 Dapr Component. + * @param componentName Name of the Dapr Component. * @param daprComponentEnvelope Configuration details of the Dapr Component. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, daprComponentEnvelope: DaprComponent, options?: DaprComponentsCreateOrUpdateOptionalParams ): Promise { @@ -156,7 +158,7 @@ export class DaprComponentsImpl implements DaprComponents { { resourceGroupName, environmentName, - name, + componentName, daprComponentEnvelope, options }, @@ -168,21 +170,40 @@ export class DaprComponentsImpl implements DaprComponents { * Delete a Dapr Component 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 Component. + * @param componentName Name of the Dapr Component. * @param options The options parameters. */ delete( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, options?: DaprComponentsDeleteOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, environmentName, name, options }, + { resourceGroupName, environmentName, componentName, options }, deleteOperationSpec ); } + /** + * List secrets 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. + */ + listSecrets( + resourceGroupName: string, + environmentName: string, + componentName: string, + options?: DaprComponentsListSecretsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, environmentName, componentName, options }, + listSecretsOperationSpec + ); + } + /** * ListNext * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -229,7 +250,7 @@ const listOperationSpec: coreClient.OperationSpec = { }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}", httpMethod: "GET", responses: { 200: { @@ -244,15 +265,15 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName + Parameters.environmentName, + Parameters.componentName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}", httpMethod: "PUT", responses: { 200: { @@ -268,8 +289,8 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName + Parameters.environmentName, + Parameters.componentName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -277,7 +298,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}", httpMethod: "DELETE", responses: { 200: {}, @@ -291,8 +312,31 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.environmentName + Parameters.environmentName, + Parameters.componentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listSecretsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/daprComponents/{componentName}/listSecrets", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DaprSecretsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.environmentName, + Parameters.componentName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/index.ts b/sdk/app/arm-app/src/operations/index.ts index 5dc5208b4575..be3cf8e34a81 100644 --- a/sdk/app/arm-app/src/operations/index.ts +++ b/sdk/app/arm-app/src/operations/index.ts @@ -6,13 +6,21 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +export * from "./containerAppsAuthConfigs"; export * from "./containerApps"; export * from "./containerAppsRevisions"; export * from "./containerAppsRevisionReplicas"; +export * from "./daprComponents"; +export * from "./containerAppsDiagnostics"; +export * from "./managedEnvironmentDiagnostics"; +export * from "./managedEnvironmentsDiagnostics"; +export * from "./operations"; export * from "./managedEnvironments"; export * from "./certificates"; -export * from "./operations"; -export * from "./containerAppsSourceControls"; -export * from "./daprComponents"; -export * from "./containerAppsAuthConfigs"; +export * from "./namespaces"; export * from "./managedEnvironmentsStorages"; +export * from "./containerAppsSourceControls"; +export * from "./connectedEnvironments"; +export * from "./connectedEnvironmentsCertificates"; +export * from "./connectedEnvironmentsDaprComponents"; +export * from "./connectedEnvironmentsStorages"; diff --git a/sdk/app/arm-app/src/operations/managedEnvironmentDiagnostics.ts b/sdk/app/arm-app/src/operations/managedEnvironmentDiagnostics.ts new file mode 100644 index 000000000000..a74c66507b36 --- /dev/null +++ b/sdk/app/arm-app/src/operations/managedEnvironmentDiagnostics.ts @@ -0,0 +1,117 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { ManagedEnvironmentDiagnostics } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + ManagedEnvironmentDiagnosticsListDetectorsOptionalParams, + ManagedEnvironmentDiagnosticsListDetectorsResponse, + ManagedEnvironmentDiagnosticsGetDetectorOptionalParams, + ManagedEnvironmentDiagnosticsGetDetectorResponse +} from "../models"; + +/** Class containing ManagedEnvironmentDiagnostics operations. */ +export class ManagedEnvironmentDiagnosticsImpl + implements ManagedEnvironmentDiagnostics { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ManagedEnvironmentDiagnostics class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get the list of diagnostics for a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param options The options parameters. + */ + listDetectors( + resourceGroupName: string, + environmentName: string, + options?: ManagedEnvironmentDiagnosticsListDetectorsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, environmentName, options }, + listDetectorsOperationSpec + ); + } + + /** + * Get the diagnostics data for a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param detectorName Name of the Managed Environment detector. + * @param options The options parameters. + */ + getDetector( + resourceGroupName: string, + environmentName: string, + detectorName: string, + options?: ManagedEnvironmentDiagnosticsGetDetectorOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, environmentName, detectorName, options }, + getDetectorOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listDetectorsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/detectors", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.DiagnosticsCollection + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.environmentName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getDetectorOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/detectors/{detectorName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Diagnostics + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.environmentName, + Parameters.detectorName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/managedEnvironments.ts b/sdk/app/arm-app/src/operations/managedEnvironments.ts index e1340d924ede..c474dd1cc701 100644 --- a/sdk/app/arm-app/src/operations/managedEnvironments.ts +++ b/sdk/app/arm-app/src/operations/managedEnvironments.ts @@ -27,9 +27,7 @@ import { ManagedEnvironmentsCreateOrUpdateOptionalParams, ManagedEnvironmentsCreateOrUpdateResponse, ManagedEnvironmentsDeleteOptionalParams, - ManagedEnvironmentPatch, ManagedEnvironmentsUpdateOptionalParams, - ManagedEnvironmentsUpdateResponse, ManagedEnvironmentsListBySubscriptionNextResponse, ManagedEnvironmentsListByResourceGroupNextResponse } from "../models"; @@ -173,16 +171,16 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { /** * Get the properties of a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ get( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, name, options }, + { resourceGroupName, environmentName, options }, getOperationSpec ); } @@ -190,13 +188,13 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { /** * Creates or updates a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ async beginCreateOrUpdate( resourceGroupName: string, - name: string, + environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams ): Promise< @@ -246,7 +244,7 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { const lro = new LroImpl( sendOperation, - { resourceGroupName, name, environmentEnvelope, options }, + { resourceGroupName, environmentName, environmentEnvelope, options }, createOrUpdateOperationSpec ); const poller = new LroEngine(lro, { @@ -260,19 +258,19 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { /** * Creates or updates a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ async beginCreateOrUpdateAndWait( resourceGroupName: string, - name: string, + environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, - name, + environmentName, environmentEnvelope, options ); @@ -282,12 +280,12 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { /** * Delete a Managed Environment if it does not have any container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ async beginDelete( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams ): Promise, void>> { const directSendOperation = async ( @@ -331,7 +329,7 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { const lro = new LroImpl( sendOperation, - { resourceGroupName, name, options }, + { resourceGroupName, environmentName, options }, deleteOperationSpec ); const poller = new LroEngine(lro, { @@ -345,35 +343,107 @@ export class ManagedEnvironmentsImpl implements ManagedEnvironments { /** * Delete a Managed Environment if it does not have any container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ async beginDeleteAndWait( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams ): Promise { - const poller = await this.beginDelete(resourceGroupName, name, options); + const poller = await this.beginDelete( + resourceGroupName, + environmentName, + options + ); return poller.pollUntilDone(); } /** - * Patches a Managed Environment. Only patching of tags is supported currently + * Patches a Managed Environment using JSON Merge Patch * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ - update( + async beginUpdate( resourceGroupName: string, - name: string, - environmentEnvelope: ManagedEnvironmentPatch, + environmentName: string, + environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, name, environmentEnvelope, options }, + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperation = 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 = new LroImpl( + sendOperation, + { resourceGroupName, environmentName, environmentEnvelope, options }, updateOperationSpec ); + const poller = new LroEngine(lro, { + resumeFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs + }); + await poller.poll(); + return poller; + } + + /** + * Patches a Managed Environment using JSON Merge Patch + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param environmentEnvelope Configuration details of the Environment. + * @param options The options parameters. + */ + async beginUpdateAndWait( + resourceGroupName: string, + environmentName: string, + environmentEnvelope: ManagedEnvironment, + options?: ManagedEnvironmentsUpdateOptionalParams + ): Promise { + const poller = await this.beginUpdate( + resourceGroupName, + environmentName, + environmentEnvelope, + options + ); + return poller.pollUntilDone(); } /** @@ -451,7 +521,7 @@ const listByResourceGroupOperationSpec: coreClient.OperationSpec = { }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}", httpMethod: "GET", responses: { 200: { @@ -466,14 +536,14 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.environmentName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}", httpMethod: "PUT", responses: { 200: { @@ -498,7 +568,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.environmentName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -506,7 +576,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}", httpMethod: "DELETE", responses: { 200: {}, @@ -522,30 +592,31 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.environmentName ], headerParameters: [Parameters.accept], serializer }; const updateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}", httpMethod: "PATCH", responses: { - 200: { - bodyMapper: Mappers.ManagedEnvironment - }, + 200: {}, + 201: {}, + 202: {}, + 204: {}, default: { bodyMapper: Mappers.DefaultErrorResponse } }, - requestBody: Parameters.environmentEnvelope1, + requestBody: Parameters.environmentEnvelope, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name + Parameters.environmentName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", diff --git a/sdk/app/arm-app/src/operations/managedEnvironmentsDiagnostics.ts b/sdk/app/arm-app/src/operations/managedEnvironmentsDiagnostics.ts new file mode 100644 index 000000000000..a075b565a3ad --- /dev/null +++ b/sdk/app/arm-app/src/operations/managedEnvironmentsDiagnostics.ts @@ -0,0 +1,73 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { ManagedEnvironmentsDiagnostics } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + ManagedEnvironmentsDiagnosticsGetRootOptionalParams, + ManagedEnvironmentsDiagnosticsGetRootResponse +} from "../models"; + +/** Class containing ManagedEnvironmentsDiagnostics operations. */ +export class ManagedEnvironmentsDiagnosticsImpl + implements ManagedEnvironmentsDiagnostics { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class ManagedEnvironmentsDiagnostics class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Get the properties of a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param options The options parameters. + */ + getRoot( + resourceGroupName: string, + environmentName: string, + options?: ManagedEnvironmentsDiagnosticsGetRootOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, environmentName, options }, + getRootOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const getRootOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/detectorProperties/rootApi/", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ManagedEnvironment + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.environmentName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/app/arm-app/src/operations/managedEnvironmentsStorages.ts b/sdk/app/arm-app/src/operations/managedEnvironmentsStorages.ts index d656633ec4e6..ed330cba0b98 100644 --- a/sdk/app/arm-app/src/operations/managedEnvironmentsStorages.ts +++ b/sdk/app/arm-app/src/operations/managedEnvironmentsStorages.ts @@ -38,16 +38,16 @@ export class ManagedEnvironmentsStoragesImpl /** * Get all storages for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ list( resourceGroupName: string, - envName: string, + environmentName: string, options?: ManagedEnvironmentsStoragesListOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, envName, options }, + { resourceGroupName, environmentName, options }, listOperationSpec ); } @@ -55,18 +55,18 @@ export class ManagedEnvironmentsStoragesImpl /** * Get storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param options The options parameters. */ get( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, options?: ManagedEnvironmentsStoragesGetOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, envName, name, options }, + { resourceGroupName, environmentName, storageName, options }, getOperationSpec ); } @@ -74,20 +74,26 @@ export class ManagedEnvironmentsStoragesImpl /** * Create or update storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param storageEnvelope Configuration details of storage. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, storageEnvelope: ManagedEnvironmentStorage, options?: ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, envName, name, storageEnvelope, options }, + { + resourceGroupName, + environmentName, + storageName, + storageEnvelope, + options + }, createOrUpdateOperationSpec ); } @@ -95,18 +101,18 @@ export class ManagedEnvironmentsStoragesImpl /** * Delete storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param options The options parameters. */ delete( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, options?: ManagedEnvironmentsStoragesDeleteOptionalParams ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, envName, name, options }, + { resourceGroupName, environmentName, storageName, options }, deleteOperationSpec ); } @@ -116,7 +122,7 @@ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{envName}/storages", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/storages", httpMethod: "GET", responses: { 200: { @@ -131,14 +137,14 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.envName + Parameters.environmentName ], headerParameters: [Parameters.accept], serializer }; const getOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{envName}/storages/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/storages/{storageName}", httpMethod: "GET", responses: { 200: { @@ -153,15 +159,15 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.envName + Parameters.environmentName, + Parameters.storageName ], headerParameters: [Parameters.accept], serializer }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{envName}/storages/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/storages/{storageName}", httpMethod: "PUT", responses: { 200: { @@ -177,8 +183,8 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.envName + Parameters.environmentName, + Parameters.storageName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -186,7 +192,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { }; const deleteOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{envName}/storages/{name}", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/storages/{storageName}", httpMethod: "DELETE", responses: { 200: {}, @@ -200,8 +206,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.name, - Parameters.envName + Parameters.environmentName, + Parameters.storageName ], headerParameters: [Parameters.accept], serializer diff --git a/sdk/app/arm-app/src/operations/namespaces.ts b/sdk/app/arm-app/src/operations/namespaces.ts new file mode 100644 index 000000000000..2f2ed80b203c --- /dev/null +++ b/sdk/app/arm-app/src/operations/namespaces.ts @@ -0,0 +1,82 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { Namespaces } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { ContainerAppsAPIClient } from "../containerAppsAPIClient"; +import { + CheckNameAvailabilityRequest, + NamespacesCheckNameAvailabilityOptionalParams, + NamespacesCheckNameAvailabilityResponse +} from "../models"; + +/** Class containing Namespaces operations. */ +export class NamespacesImpl implements Namespaces { + private readonly client: ContainerAppsAPIClient; + + /** + * Initialize a new instance of the class Namespaces class. + * @param client Reference to the service client + */ + constructor(client: ContainerAppsAPIClient) { + this.client = client; + } + + /** + * Checks if resource name is available. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Managed Environment. + * @param checkNameAvailabilityRequest The check name availability request. + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + environmentName: string, + checkNameAvailabilityRequest: CheckNameAvailabilityRequest, + options?: NamespacesCheckNameAvailabilityOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + environmentName, + checkNameAvailabilityRequest, + options + }, + checkNameAvailabilityOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/checkNameAvailability", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.CheckNameAvailabilityResponse + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse + } + }, + requestBody: Parameters.checkNameAvailabilityRequest, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.environmentName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; diff --git a/sdk/app/arm-app/src/operationsInterfaces/certificates.ts b/sdk/app/arm-app/src/operationsInterfaces/certificates.ts index edd52749749b..a0a7a35d7be1 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/certificates.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/certificates.ts @@ -26,65 +26,65 @@ export interface Certificates { /** * Get the Certificates in a given managed environment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. + * @param environmentName Name of the Managed Environment. * @param options The options parameters. */ list( resourceGroupName: string, - managedEnvironmentName: string, + environmentName: string, options?: CertificatesListOptionalParams ): PagedAsyncIterableIterator; /** * Get the specified Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ get( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesGetOptionalParams ): Promise; /** * Create or Update a Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesCreateOrUpdateOptionalParams ): Promise; /** * Deletes the specified Certificate. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param options The options parameters. */ delete( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, options?: CertificatesDeleteOptionalParams ): Promise; /** * Patches a certificate. Currently only patching of tags is supported * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param managedEnvironmentName Name of the Managed Environment. - * @param name Name of the Certificate. + * @param environmentName Name of the Managed Environment. + * @param certificateName Name of the Certificate. * @param certificateEnvelope Properties of a certificate that need to be updated * @param options The options parameters. */ update( resourceGroupName: string, - managedEnvironmentName: string, - name: string, + environmentName: string, + certificateName: string, certificateEnvelope: CertificatePatch, options?: CertificatesUpdateOptionalParams ): Promise; diff --git a/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironments.ts b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironments.ts new file mode 100644 index 000000000000..7770413e4575 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironments.ts @@ -0,0 +1,134 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { PollerLike, PollOperationState } from "@azure/core-lro"; +import { + ConnectedEnvironment, + ConnectedEnvironmentsListBySubscriptionOptionalParams, + ConnectedEnvironmentsListByResourceGroupOptionalParams, + ConnectedEnvironmentsGetOptionalParams, + ConnectedEnvironmentsGetResponse, + ConnectedEnvironmentsCreateOrUpdateOptionalParams, + ConnectedEnvironmentsCreateOrUpdateResponse, + ConnectedEnvironmentsDeleteOptionalParams, + ConnectedEnvironmentsUpdateOptionalParams, + ConnectedEnvironmentsUpdateResponse, + CheckNameAvailabilityRequest, + ConnectedEnvironmentsCheckNameAvailabilityOptionalParams, + ConnectedEnvironmentsCheckNameAvailabilityResponse +} from "../models"; + +/// +/** Interface representing a ConnectedEnvironments. */ +export interface ConnectedEnvironments { + /** + * Get all connectedEnvironments for a subscription. + * @param options The options parameters. + */ + listBySubscription( + options?: ConnectedEnvironmentsListBySubscriptionOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get all connectedEnvironments in a resource group. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param options The options parameters. + */ + listByResourceGroup( + resourceGroupName: string, + options?: ConnectedEnvironmentsListByResourceGroupOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get the properties of an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsGetOptionalParams + ): Promise; + /** + * Creates or updates an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param environmentEnvelope Configuration details of the connectedEnvironment. + * @param options The options parameters. + */ + beginCreateOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + environmentEnvelope: ConnectedEnvironment, + options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams + ): Promise< + PollerLike< + PollOperationState, + ConnectedEnvironmentsCreateOrUpdateResponse + > + >; + /** + * Creates or updates an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param environmentEnvelope Configuration details of the connectedEnvironment. + * @param options The options parameters. + */ + beginCreateOrUpdateAndWait( + resourceGroupName: string, + connectedEnvironmentName: string, + environmentEnvelope: ConnectedEnvironment, + options?: ConnectedEnvironmentsCreateOrUpdateOptionalParams + ): Promise; + /** + * Delete an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + beginDelete( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDeleteOptionalParams + ): Promise, void>>; + /** + * Delete an connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + beginDeleteAndWait( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDeleteOptionalParams + ): Promise; + /** + * Patches a Managed Environment. Only patching of tags is supported currently + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connectedEnvironment. + * @param options The options parameters. + */ + update( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsUpdateOptionalParams + ): Promise; + /** + * Checks if resource connectedEnvironmentName is available. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Managed Environment. + * @param checkNameAvailabilityRequest The check connectedEnvironmentName availability request. + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + connectedEnvironmentName: string, + checkNameAvailabilityRequest: CheckNameAvailabilityRequest, + options?: ConnectedEnvironmentsCheckNameAvailabilityOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsCertificates.ts b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsCertificates.ts new file mode 100644 index 000000000000..046c23eced28 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsCertificates.ts @@ -0,0 +1,91 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + Certificate, + ConnectedEnvironmentsCertificatesListOptionalParams, + ConnectedEnvironmentsCertificatesGetOptionalParams, + ConnectedEnvironmentsCertificatesGetResponse, + ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams, + ConnectedEnvironmentsCertificatesCreateOrUpdateResponse, + ConnectedEnvironmentsCertificatesDeleteOptionalParams, + CertificatePatch, + ConnectedEnvironmentsCertificatesUpdateOptionalParams, + ConnectedEnvironmentsCertificatesUpdateResponse +} from "../models"; + +/// +/** Interface representing a ConnectedEnvironmentsCertificates. */ +export interface ConnectedEnvironmentsCertificates { + /** + * Get the Certificates in a given connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsCertificatesListOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get the specified Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesGetOptionalParams + ): Promise; + /** + * Create or Update a Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesCreateOrUpdateOptionalParams + ): Promise; + /** + * Deletes the specified Certificate. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + options?: ConnectedEnvironmentsCertificatesDeleteOptionalParams + ): Promise; + /** + * Patches a certificate. Currently only patching of tags is supported + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Connected Environment. + * @param certificateName Name of the Certificate. + * @param certificateEnvelope Properties of a certificate that need to be updated + * @param options The options parameters. + */ + update( + resourceGroupName: string, + connectedEnvironmentName: string, + certificateName: string, + certificateEnvelope: CertificatePatch, + options?: ConnectedEnvironmentsCertificatesUpdateOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsDaprComponents.ts b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsDaprComponents.ts new file mode 100644 index 000000000000..ff513aad5163 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsDaprComponents.ts @@ -0,0 +1,90 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { + DaprComponent, + ConnectedEnvironmentsDaprComponentsListOptionalParams, + ConnectedEnvironmentsDaprComponentsGetOptionalParams, + ConnectedEnvironmentsDaprComponentsGetResponse, + ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams, + ConnectedEnvironmentsDaprComponentsCreateOrUpdateResponse, + ConnectedEnvironmentsDaprComponentsDeleteOptionalParams, + ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams, + ConnectedEnvironmentsDaprComponentsListSecretsResponse +} from "../models"; + +/// +/** Interface representing a ConnectedEnvironmentsDaprComponents. */ +export interface ConnectedEnvironmentsDaprComponents { + /** + * Get the Dapr Components for a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsDaprComponentsListOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a dapr component. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsGetOptionalParams + ): Promise; + /** + * Creates or updates a Dapr Component in a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param daprComponentEnvelope Configuration details of the Dapr Component. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + daprComponentEnvelope: DaprComponent, + options?: ConnectedEnvironmentsDaprComponentsCreateOrUpdateOptionalParams + ): Promise; + /** + * Delete a Dapr Component from a connected environment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsDeleteOptionalParams + ): Promise; + /** + * List secrets for a dapr component + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the connected environment. + * @param componentName Name of the Dapr Component. + * @param options The options parameters. + */ + listSecrets( + resourceGroupName: string, + connectedEnvironmentName: string, + componentName: string, + options?: ConnectedEnvironmentsDaprComponentsListSecretsOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsStorages.ts b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsStorages.ts new file mode 100644 index 000000000000..caa3b49e4af7 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/connectedEnvironmentsStorages.ts @@ -0,0 +1,74 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + ConnectedEnvironmentsStoragesListOptionalParams, + ConnectedEnvironmentsStoragesListResponse, + ConnectedEnvironmentsStoragesGetOptionalParams, + ConnectedEnvironmentsStoragesGetResponse, + ConnectedEnvironmentStorage, + ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams, + ConnectedEnvironmentsStoragesCreateOrUpdateResponse, + ConnectedEnvironmentsStoragesDeleteOptionalParams +} from "../models"; + +/** Interface representing a ConnectedEnvironmentsStorages. */ +export interface ConnectedEnvironmentsStorages { + /** + * Get all storages for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + connectedEnvironmentName: string, + options?: ConnectedEnvironmentsStoragesListOptionalParams + ): Promise; + /** + * Get storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + options?: ConnectedEnvironmentsStoragesGetOptionalParams + ): Promise; + /** + * Create or update storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param storageEnvelope Configuration details of storage. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + storageEnvelope: ConnectedEnvironmentStorage, + options?: ConnectedEnvironmentsStoragesCreateOrUpdateOptionalParams + ): Promise; + /** + * Delete storage for a connectedEnvironment. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param connectedEnvironmentName Name of the Environment. + * @param storageName Name of the storage. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + connectedEnvironmentName: string, + storageName: string, + options?: ConnectedEnvironmentsStoragesDeleteOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerApps.ts b/sdk/app/arm-app/src/operationsInterfaces/containerApps.ts index 982f3d283d74..abbeaa8edd1e 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/containerApps.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/containerApps.ts @@ -17,9 +17,7 @@ import { ContainerAppsCreateOrUpdateOptionalParams, ContainerAppsCreateOrUpdateResponse, ContainerAppsDeleteOptionalParams, - ContainerAppPatch, ContainerAppsUpdateOptionalParams, - ContainerAppsUpdateResponse, ContainerAppsListCustomHostNameAnalysisOptionalParams, ContainerAppsListCustomHostNameAnalysisResponse, ContainerAppsListSecretsOptionalParams, @@ -48,24 +46,24 @@ export interface ContainerApps { /** * Get the properties of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ get( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsGetOptionalParams ): Promise; /** - * Description for Create or update a Container App. + * Create or update a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param containerAppEnvelope Properties used to create a container app * @param options The options parameters. */ beginCreateOrUpdate( resourceGroupName: string, - name: string, + containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise< @@ -75,53 +73,66 @@ export interface ContainerApps { > >; /** - * Description for Create or update a Container App. + * Create or update a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param containerAppEnvelope Properties used to create a container app * @param options The options parameters. */ beginCreateOrUpdateAndWait( resourceGroupName: string, - name: string, + containerAppName: string, containerAppEnvelope: ContainerApp, options?: ContainerAppsCreateOrUpdateOptionalParams ): Promise; /** - * Description for Delete a Container App. + * Delete a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ beginDelete( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsDeleteOptionalParams ): Promise, void>>; /** - * Description for Delete a Container App. + * Delete a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ beginDeleteAndWait( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsDeleteOptionalParams ): Promise; /** - * Patches a Container App. Currently only patching of tags is supported + * Patches a Container App using JSON Merge Patch + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param containerAppEnvelope Properties of a Container App that need to be updated + * @param options The options parameters. + */ + beginUpdate( + resourceGroupName: string, + containerAppName: string, + containerAppEnvelope: ContainerApp, + options?: ContainerAppsUpdateOptionalParams + ): Promise, void>>; + /** + * Patches a Container App using JSON Merge Patch * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. - * @param containerAppEnvelope Properties of a container app that need to be updated + * @param containerAppName Name of the Container App. + * @param containerAppEnvelope Properties of a Container App that need to be updated * @param options The options parameters. */ - update( + beginUpdateAndWait( resourceGroupName: string, - name: string, - containerAppEnvelope: ContainerAppPatch, + containerAppName: string, + containerAppEnvelope: ContainerApp, options?: ContainerAppsUpdateOptionalParams - ): Promise; + ): Promise; /** * Analyzes a custom hostname for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -136,12 +147,12 @@ export interface ContainerApps { /** * List secrets for a container app * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Container App. + * @param containerAppName Name of the Container App. * @param options The options parameters. */ listSecrets( resourceGroupName: string, - name: string, + containerAppName: string, options?: ContainerAppsListSecretsOptionalParams ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerAppsAuthConfigs.ts b/sdk/app/arm-app/src/operationsInterfaces/containerAppsAuthConfigs.ts index 0974e04f1235..35e76fdda014 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/containerAppsAuthConfigs.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/containerAppsAuthConfigs.ts @@ -35,41 +35,41 @@ export interface ContainerAppsAuthConfigs { * Get a AuthConfig of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param options The options parameters. */ get( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, options?: ContainerAppsAuthConfigsGetOptionalParams ): Promise; /** - * Description for Create or update the AuthConfig for a Container App. + * Create or update the AuthConfig for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param authConfigEnvelope Properties used to create a Container App AuthConfig * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, authConfigEnvelope: AuthConfig, options?: ContainerAppsAuthConfigsCreateOrUpdateOptionalParams ): Promise; /** - * Description for Delete a Container App AuthConfig. + * Delete a Container App AuthConfig. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App AuthConfig. + * @param authConfigName Name of the Container App AuthConfig. * @param options The options parameters. */ delete( resourceGroupName: string, containerAppName: string, - name: string, + authConfigName: string, options?: ContainerAppsAuthConfigsDeleteOptionalParams ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerAppsDiagnostics.ts b/sdk/app/arm-app/src/operationsInterfaces/containerAppsDiagnostics.ts new file mode 100644 index 000000000000..dc92fee57eb2 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/containerAppsDiagnostics.ts @@ -0,0 +1,85 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + Diagnostics, + ContainerAppsDiagnosticsListDetectorsOptionalParams, + Revision, + ContainerAppsDiagnosticsListRevisionsOptionalParams, + ContainerAppsDiagnosticsGetDetectorOptionalParams, + ContainerAppsDiagnosticsGetDetectorResponse, + ContainerAppsDiagnosticsGetRevisionOptionalParams, + ContainerAppsDiagnosticsGetRevisionResponse, + ContainerAppsDiagnosticsGetRootOptionalParams, + ContainerAppsDiagnosticsGetRootResponse +} from "../models"; + +/// +/** Interface representing a ContainerAppsDiagnostics. */ +export interface ContainerAppsDiagnostics { + /** + * Get the list of diagnostics for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which detector info is needed. + * @param options The options parameters. + */ + listDetectors( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListDetectorsOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get the Revisions for a given Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App for which Revisions are needed. + * @param options The options parameters. + */ + listRevisions( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsListRevisionsOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a diagnostics result of a Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param detectorName Name of the Container App Detector. + * @param options The options parameters. + */ + getDetector( + resourceGroupName: string, + containerAppName: string, + detectorName: string, + options?: ContainerAppsDiagnosticsGetDetectorOptionalParams + ): Promise; + /** + * Get a revision of a 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. + * @param options The options parameters. + */ + getRevision( + resourceGroupName: string, + containerAppName: string, + revisionName: string, + options?: ContainerAppsDiagnosticsGetRevisionOptionalParams + ): Promise; + /** + * Get the properties of a Container App. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param containerAppName Name of the Container App. + * @param options The options parameters. + */ + getRoot( + resourceGroupName: string, + containerAppName: string, + options?: ContainerAppsDiagnosticsGetRootOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisionReplicas.ts b/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisionReplicas.ts index 95d27477a2a5..e582a12a99ad 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisionReplicas.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisionReplicas.ts @@ -20,14 +20,14 @@ export interface ContainerAppsRevisionReplicas { * @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. - * @param name Name of the Container App Revision Replica. + * @param replicaName Name of the Container App Revision Replica. * @param options The options parameters. */ getReplica( resourceGroupName: string, containerAppName: string, revisionName: string, - name: string, + replicaName: string, options?: ContainerAppsRevisionReplicasGetReplicaOptionalParams ): Promise; /** diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisions.ts b/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisions.ts index 7bd9ecc80c1e..de0c4751919e 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisions.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/containerAppsRevisions.ts @@ -35,52 +35,52 @@ export interface ContainerAppsRevisions { * Get a revision of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ getRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsGetRevisionOptionalParams ): Promise; /** * Activates a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ activateRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsActivateRevisionOptionalParams ): Promise; /** * Deactivates a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ deactivateRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsDeactivateRevisionOptionalParams ): Promise; /** * Restarts a revision for a Container App * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App Revision. + * @param revisionName Name of the Container App Revision. * @param options The options parameters. */ restartRevision( resourceGroupName: string, containerAppName: string, - name: string, + revisionName: string, options?: ContainerAppsRevisionsRestartRevisionOptionalParams ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/containerAppsSourceControls.ts b/sdk/app/arm-app/src/operationsInterfaces/containerAppsSourceControls.ts index 6d778a486e79..d276be2eaa6d 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/containerAppsSourceControls.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/containerAppsSourceControls.ts @@ -36,27 +36,27 @@ export interface ContainerAppsSourceControls { * Get a SourceControl of a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ get( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsGetOptionalParams ): Promise; /** - * Description for Create or update the SourceControl for a Container App. + * Create or update the SourceControl for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param sourceControlEnvelope Properties used to create a Container App SourceControl * @param options The options parameters. */ beginCreateOrUpdate( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams ): Promise< @@ -66,44 +66,44 @@ export interface ContainerAppsSourceControls { > >; /** - * Description for Create or update the SourceControl for a Container App. + * Create or update the SourceControl for a Container App. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param sourceControlEnvelope Properties used to create a Container App SourceControl * @param options The options parameters. */ beginCreateOrUpdateAndWait( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, sourceControlEnvelope: SourceControl, options?: ContainerAppsSourceControlsCreateOrUpdateOptionalParams ): Promise; /** - * Description for Delete a Container App SourceControl. + * Delete a Container App SourceControl. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ beginDelete( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams ): Promise, void>>; /** - * Description for Delete a Container App SourceControl. + * Delete a Container App SourceControl. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param containerAppName Name of the Container App. - * @param name Name of the Container App SourceControl. + * @param sourceControlName Name of the Container App SourceControl. * @param options The options parameters. */ beginDeleteAndWait( resourceGroupName: string, containerAppName: string, - name: string, + sourceControlName: string, options?: ContainerAppsSourceControlsDeleteOptionalParams ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/daprComponents.ts b/sdk/app/arm-app/src/operationsInterfaces/daprComponents.ts index 61ee0547987b..a598b7bbe25b 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/daprComponents.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/daprComponents.ts @@ -14,7 +14,9 @@ import { DaprComponentsGetResponse, DaprComponentsCreateOrUpdateOptionalParams, DaprComponentsCreateOrUpdateResponse, - DaprComponentsDeleteOptionalParams + DaprComponentsDeleteOptionalParams, + DaprComponentsListSecretsOptionalParams, + DaprComponentsListSecretsResponse } from "../models"; /// @@ -35,27 +37,27 @@ export interface DaprComponents { * Get a dapr 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 Dapr Component. + * @param componentName Name of the Dapr Component. * @param options The options parameters. */ get( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, options?: DaprComponentsGetOptionalParams ): Promise; /** * Creates or updates a Dapr 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 Dapr Component. + * @param componentName Name of the Dapr Component. * @param daprComponentEnvelope Configuration details of the Dapr Component. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, daprComponentEnvelope: DaprComponent, options?: DaprComponentsCreateOrUpdateOptionalParams ): Promise; @@ -63,13 +65,26 @@ export interface DaprComponents { * Delete a Dapr Component 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 Component. + * @param componentName Name of the Dapr Component. * @param options The options parameters. */ delete( resourceGroupName: string, environmentName: string, - name: string, + componentName: string, options?: DaprComponentsDeleteOptionalParams ): Promise; + /** + * List secrets 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. + */ + listSecrets( + resourceGroupName: string, + environmentName: string, + componentName: string, + options?: DaprComponentsListSecretsOptionalParams + ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/index.ts b/sdk/app/arm-app/src/operationsInterfaces/index.ts index 5dc5208b4575..be3cf8e34a81 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/index.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/index.ts @@ -6,13 +6,21 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +export * from "./containerAppsAuthConfigs"; export * from "./containerApps"; export * from "./containerAppsRevisions"; export * from "./containerAppsRevisionReplicas"; +export * from "./daprComponents"; +export * from "./containerAppsDiagnostics"; +export * from "./managedEnvironmentDiagnostics"; +export * from "./managedEnvironmentsDiagnostics"; +export * from "./operations"; export * from "./managedEnvironments"; export * from "./certificates"; -export * from "./operations"; -export * from "./containerAppsSourceControls"; -export * from "./daprComponents"; -export * from "./containerAppsAuthConfigs"; +export * from "./namespaces"; export * from "./managedEnvironmentsStorages"; +export * from "./containerAppsSourceControls"; +export * from "./connectedEnvironments"; +export * from "./connectedEnvironmentsCertificates"; +export * from "./connectedEnvironmentsDaprComponents"; +export * from "./connectedEnvironmentsStorages"; diff --git a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentDiagnostics.ts b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentDiagnostics.ts new file mode 100644 index 000000000000..35c897c7cf40 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentDiagnostics.ts @@ -0,0 +1,42 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + ManagedEnvironmentDiagnosticsListDetectorsOptionalParams, + ManagedEnvironmentDiagnosticsListDetectorsResponse, + ManagedEnvironmentDiagnosticsGetDetectorOptionalParams, + ManagedEnvironmentDiagnosticsGetDetectorResponse +} from "../models"; + +/** Interface representing a ManagedEnvironmentDiagnostics. */ +export interface ManagedEnvironmentDiagnostics { + /** + * Get the list of diagnostics for a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param options The options parameters. + */ + listDetectors( + resourceGroupName: string, + environmentName: string, + options?: ManagedEnvironmentDiagnosticsListDetectorsOptionalParams + ): Promise; + /** + * Get the diagnostics data for a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param detectorName Name of the Managed Environment detector. + * @param options The options parameters. + */ + getDetector( + resourceGroupName: string, + environmentName: string, + detectorName: string, + options?: ManagedEnvironmentDiagnosticsGetDetectorOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironments.ts b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironments.ts index 8d6ee3e2f59a..bbb4449aa607 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironments.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironments.ts @@ -17,9 +17,7 @@ import { ManagedEnvironmentsCreateOrUpdateOptionalParams, ManagedEnvironmentsCreateOrUpdateResponse, ManagedEnvironmentsDeleteOptionalParams, - ManagedEnvironmentPatch, - ManagedEnvironmentsUpdateOptionalParams, - ManagedEnvironmentsUpdateResponse + ManagedEnvironmentsUpdateOptionalParams } from "../models"; /// @@ -44,24 +42,24 @@ export interface ManagedEnvironments { /** * Get the properties of a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ get( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsGetOptionalParams ): Promise; /** * Creates or updates a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ beginCreateOrUpdate( resourceGroupName: string, - name: string, + environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams ): Promise< @@ -73,49 +71,62 @@ export interface ManagedEnvironments { /** * Creates or updates a Managed Environment used to host container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ beginCreateOrUpdateAndWait( resourceGroupName: string, - name: string, + environmentName: string, environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsCreateOrUpdateOptionalParams ): Promise; /** * Delete a Managed Environment if it does not have any container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ beginDelete( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams ): Promise, void>>; /** * Delete a Managed Environment if it does not have any container apps. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ beginDeleteAndWait( resourceGroupName: string, - name: string, + environmentName: string, options?: ManagedEnvironmentsDeleteOptionalParams ): Promise; /** - * Patches a Managed Environment. Only patching of tags is supported currently + * Patches a Managed Environment using JSON Merge Patch * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param name Name of the Environment. + * @param environmentName Name of the Environment. * @param environmentEnvelope Configuration details of the Environment. * @param options The options parameters. */ - update( + beginUpdate( resourceGroupName: string, - name: string, - environmentEnvelope: ManagedEnvironmentPatch, + environmentName: string, + environmentEnvelope: ManagedEnvironment, options?: ManagedEnvironmentsUpdateOptionalParams - ): Promise; + ): Promise, void>>; + /** + * Patches a Managed Environment using JSON Merge Patch + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param environmentEnvelope Configuration details of the Environment. + * @param options The options parameters. + */ + beginUpdateAndWait( + resourceGroupName: string, + environmentName: string, + environmentEnvelope: ManagedEnvironment, + options?: ManagedEnvironmentsUpdateOptionalParams + ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsDiagnostics.ts b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsDiagnostics.ts new file mode 100644 index 000000000000..a90da24cf5ac --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsDiagnostics.ts @@ -0,0 +1,27 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + ManagedEnvironmentsDiagnosticsGetRootOptionalParams, + ManagedEnvironmentsDiagnosticsGetRootResponse +} from "../models"; + +/** Interface representing a ManagedEnvironmentsDiagnostics. */ +export interface ManagedEnvironmentsDiagnostics { + /** + * Get the properties of a Managed Environment used to host container apps. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Environment. + * @param options The options parameters. + */ + getRoot( + resourceGroupName: string, + environmentName: string, + options?: ManagedEnvironmentsDiagnosticsGetRootOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsStorages.ts b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsStorages.ts index ed2fca873fa3..9ceeba873bfc 100644 --- a/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsStorages.ts +++ b/sdk/app/arm-app/src/operationsInterfaces/managedEnvironmentsStorages.ts @@ -22,53 +22,53 @@ export interface ManagedEnvironmentsStorages { /** * Get all storages for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. + * @param environmentName Name of the Environment. * @param options The options parameters. */ list( resourceGroupName: string, - envName: string, + environmentName: string, options?: ManagedEnvironmentsStoragesListOptionalParams ): Promise; /** * Get storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param options The options parameters. */ get( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, options?: ManagedEnvironmentsStoragesGetOptionalParams ): Promise; /** * Create or update storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param storageEnvelope Configuration details of storage. * @param options The options parameters. */ createOrUpdate( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, storageEnvelope: ManagedEnvironmentStorage, options?: ManagedEnvironmentsStoragesCreateOrUpdateOptionalParams ): Promise; /** * Delete storage for a managedEnvironment. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param envName Name of the Environment. - * @param name Name of the storage. + * @param environmentName Name of the Environment. + * @param storageName Name of the storage. * @param options The options parameters. */ delete( resourceGroupName: string, - envName: string, - name: string, + environmentName: string, + storageName: string, options?: ManagedEnvironmentsStoragesDeleteOptionalParams ): Promise; } diff --git a/sdk/app/arm-app/src/operationsInterfaces/namespaces.ts b/sdk/app/arm-app/src/operationsInterfaces/namespaces.ts new file mode 100644 index 000000000000..b3b2251fc092 --- /dev/null +++ b/sdk/app/arm-app/src/operationsInterfaces/namespaces.ts @@ -0,0 +1,30 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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, + NamespacesCheckNameAvailabilityOptionalParams, + NamespacesCheckNameAvailabilityResponse +} from "../models"; + +/** Interface representing a Namespaces. */ +export interface Namespaces { + /** + * Checks if resource name is available. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param environmentName Name of the Managed Environment. + * @param checkNameAvailabilityRequest The check name availability request. + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + environmentName: string, + checkNameAvailabilityRequest: CheckNameAvailabilityRequest, + options?: NamespacesCheckNameAvailabilityOptionalParams + ): Promise; +} diff --git a/sdk/app/arm-app/test/sampleTest.ts b/sdk/app/arm-app/test/sampleTest.ts index 7ed89b043e1b..25aeb3ebcc36 100644 --- a/sdk/app/arm-app/test/sampleTest.ts +++ b/sdk/app/arm-app/test/sampleTest.ts @@ -7,35 +7,30 @@ */ import { - env, - record, - RecorderEnvironmentSetup, - Recorder + Recorder, + RecorderStartOptions, + env } from "@azure-tools/test-recorder"; -import * as assert from "assert"; +import { assert } from "chai"; +import { Context } from "mocha"; -const recorderEnvSetup: RecorderEnvironmentSetup = { - replaceableVariables: { - 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" - }, - customizationsOnRecordings: [ - (recording: any): any => - recording.replace( - /"access_token":"[^"]*"/g, - `"access_token":"access_token"` - ) - ], - queryParametersToSkip: [] +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 function() { - recorder = record(this, recorderEnvSetup); + beforeEach(async function(this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); }); afterEach(async function() { diff --git a/sdk/app/arm-app/tsconfig.json b/sdk/app/arm-app/tsconfig.json index e17400c98311..3e6ae96443f3 100644 --- a/sdk/app/arm-app/tsconfig.json +++ b/sdk/app/arm-app/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-app": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"