From da2caa8b113dc043d215b47eae213ccc5b8510c6 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Thu, 27 Feb 2025 01:29:15 +0000 Subject: [PATCH] CodeGen from PR 32557 in Azure/azure-rest-api-specs Merge 493572a4c5528331e7b96b7884038da0097ce17f into 6261cf1fb6533df73756cd828796ac01522a9776 --- common/config/rush/pnpm-lock.yaml | 18 +- sdk/appservice/arm-appservice/CHANGELOG.md | 39 +- sdk/appservice/arm-appservice/LICENSE | 8 +- sdk/appservice/arm-appservice/README.md | 38 +- sdk/appservice/arm-appservice/_meta.json | 10 +- .../arm-appservice/api-extractor.json | 6 +- sdk/appservice/arm-appservice/package.json | 31 +- .../review/arm-appservice.api.md | 96 +++ sdk/appservice/arm-appservice/src/lroImpl.ts | 4 + .../arm-appservice/src/models/index.ts | 88 +- .../arm-appservice/src/models/mappers.ts | 14 + .../arm-appservice/src/models/parameters.ts | 60 +- .../arm-appservice/src/operations/index.ts | 1 + .../src/operations/siteCertificates.ts | 767 ++++++++++++++++++ .../src/operationsInterfaces/index.ts | 1 + .../operationsInterfaces/siteCertificates.ts | 183 +++++ .../src/webSiteManagementClient.ts | 8 +- .../arm-appservice/test/sampleTest.ts | 40 + .../tsconfig.browser.config.json | 5 +- sdk/appservice/arm-appservice/tsconfig.json | 36 +- .../arm-appservice/tsconfig.samples.json | 4 +- .../arm-appservice/tsconfig.test.json | 5 +- .../arm-appservice/vitest.browser.config.ts | 3 +- .../arm-appservice/vitest.config.ts | 1 + .../arm-appservice/vitest.esm.config.ts | 6 +- 25 files changed, 1377 insertions(+), 95 deletions(-) create mode 100644 sdk/appservice/arm-appservice/src/operations/siteCertificates.ts create mode 100644 sdk/appservice/arm-appservice/src/operationsInterfaces/siteCertificates.ts create mode 100644 sdk/appservice/arm-appservice/test/sampleTest.ts diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 87cd47a1d0ac..f17574baa52f 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -2554,7 +2554,7 @@ packages: version: 0.0.0 '@rush-temp/ai-text-analytics@file:projects/ai-text-analytics.tgz': - resolution: {integrity: sha512-1jGgJPXpBnqpTnDegMjesgQibCkWWP+sIHe9EH3z+SW5Z3EJ53VljlaafiWwNz+9z+8a+P0lnsC0J07hwnVINQ==, tarball: file:projects/ai-text-analytics.tgz} + resolution: {integrity: sha512-gkyef86U6fABbjY5iPYkRyjDu+KvYLoGMbZRQ+N6rTvDM8pE8XxZ8ll54rRk0lxqMAO3wHBhuFfAuNgDhhTluw==, tarball: file:projects/ai-text-analytics.tgz} version: 0.0.0 '@rush-temp/ai-translation-document@file:projects/ai-translation-document.tgz': @@ -2570,7 +2570,7 @@ packages: version: 0.0.0 '@rush-temp/ai-vision-image-analysis@file:projects/ai-vision-image-analysis.tgz': - resolution: {integrity: sha512-C7u702obHICqMaeFPSXIZNsmxVX/WH2izXwXmCdVVepetjRgFaqEHqT5qPYSHJkfKOO+0rPPbfF2DfefCiD4hg==, tarball: file:projects/ai-vision-image-analysis.tgz} + resolution: {integrity: sha512-818aPAYE2nBY0rMl1Qj2o9QkGi8NiK2N5SzZ1ByScuEO/y7yBpjwKOA/+6oIrOwEhszzTAal9HUB47rFZ1OWpA==, tarball: file:projects/ai-vision-image-analysis.tgz} version: 0.0.0 '@rush-temp/api-management-custom-widgets-scaffolder@file:projects/api-management-custom-widgets-scaffolder.tgz': @@ -2626,7 +2626,7 @@ packages: version: 0.0.0 '@rush-temp/arm-appservice-1@file:projects/arm-appservice-1.tgz': - resolution: {integrity: sha512-Wf2DGnB77ljft54tdBoZhlLGQhB6O2F35XAAYy1KcThUb5dOK3ako6dRdqKVtEBtfiEfIxgEwVxtDuqcC/M6sQ==, tarball: file:projects/arm-appservice-1.tgz} + resolution: {integrity: sha512-iKSrVDFGbXb/C3uGawAraSy2HA5iE1D+76f1h1A8y63bA2ATDv7Rl/QLQfNQ0C/Msfmf9SYDHON9RIw5Sym9yA==, tarball: file:projects/arm-appservice-1.tgz} version: 0.0.0 '@rush-temp/arm-appservice-profile-2020-09-01-hybrid@file:projects/arm-appservice-profile-2020-09-01-hybrid.tgz': @@ -3762,7 +3762,7 @@ packages: version: 0.0.0 '@rush-temp/functions-authentication-events@file:projects/functions-authentication-events.tgz': - resolution: {integrity: sha512-3z+Wn2tFhy1O3WnYtoshPxE8VZmpkx/LCJCQsP1kqYPotgzBWU92XQ1vVex4akjvDMaDiqL5sbs5kfmmDT7LBQ==, tarball: file:projects/functions-authentication-events.tgz} + resolution: {integrity: sha512-SancGMuk0aVOLc2LqvEqXKdkohnaud5TIHxy1D5x/AWaDlA88RCsdWfMwAutVVz972Dpf0v5w88w3pqsTiCAMw==, tarball: file:projects/functions-authentication-events.tgz} version: 0.0.0 '@rush-temp/health-deidentification@file:projects/health-deidentification.tgz': @@ -4018,19 +4018,19 @@ packages: version: 0.0.0 '@rush-temp/quantum-jobs@file:projects/quantum-jobs.tgz': - resolution: {integrity: sha512-zHtPe9OjzXX4THRvBVecPTzBM/VsSsjguLMgSQYk0Uy4Ll4myk/LoUpZZwc9nIblkPCiePJh8270MZO5H6KOOA==, tarball: file:projects/quantum-jobs.tgz} + resolution: {integrity: sha512-x6bNUk9vu8zvYVXAVFfol08i1y10LkjNUzJZWK5219WTOFHX0YkDjmZk7ZOEOoqBl9lA+/iBWSEu5ejYUQbYAw==, tarball: file:projects/quantum-jobs.tgz} version: 0.0.0 '@rush-temp/schema-registry-avro@file:projects/schema-registry-avro.tgz': - resolution: {integrity: sha512-pXsOSqgPhJlk4sQdIe5htRBCNPm4HnaZFgtcoEq1wFBJ2rQ/2sVV9YssxvsHBZwjcl+68iRpRMzfHq0xXN7pyg==, tarball: file:projects/schema-registry-avro.tgz} + resolution: {integrity: sha512-hdHZ0SJ7TRPDoof/ywC1v5P5T4Qtz6npoA4P2yFaNlhXIHEbmpxSS8bdk9t9oBOe5+wTx1Syz1CWbPNhpoGjdQ==, tarball: file:projects/schema-registry-avro.tgz} version: 0.0.0 '@rush-temp/schema-registry-json@file:projects/schema-registry-json.tgz': - resolution: {integrity: sha512-ZwFbFtIFKLrC3h+7A7Ct8dPokgFmUaCKXsxIIFETiJCMcoBGxAvvAmP59/E5S8l4AgeE7RcQuw4FdN/ySLbwBg==, tarball: file:projects/schema-registry-json.tgz} + resolution: {integrity: sha512-d/3GcklBP2GOnxwkWrBmQJrpJsEOTZzK7cqlzXavChVF2HfOy/a+DpNfF8APLp43f7PVpXeqkToFHXSkdEG9bg==, tarball: file:projects/schema-registry-json.tgz} version: 0.0.0 '@rush-temp/schema-registry@file:projects/schema-registry.tgz': - resolution: {integrity: sha512-N8FsEoIwUNgbuQGPFtJ90JTn7qYPpk2HD7AmhgGD5SlLS6Im9t8cc+/5A74nzrSKdPiko7p8Ht2LWSGzI6WWxw==, tarball: file:projects/schema-registry.tgz} + resolution: {integrity: sha512-oI5hZC61oj/rnBpFxm7PdT9EefXIWFNZF5wQfFOjKL75XUP4TXpr7cRU5G/jLYM7CDYOrQVPgrRZN0iuNFy0VQ==, tarball: file:projects/schema-registry.tgz} version: 0.0.0 '@rush-temp/search-documents@file:projects/search-documents.tgz': @@ -23765,7 +23765,7 @@ snapshots: '@types/chai-as-promised@7.1.8': dependencies: - '@types/chai': 4.3.20 + '@types/chai': 5.0.1 '@types/chai-as-promised@8.0.1': dependencies: diff --git a/sdk/appservice/arm-appservice/CHANGELOG.md b/sdk/appservice/arm-appservice/CHANGELOG.md index c5808e1e269b..166432882ae3 100644 --- a/sdk/appservice/arm-appservice/CHANGELOG.md +++ b/sdk/appservice/arm-appservice/CHANGELOG.md @@ -1,15 +1,36 @@ # Release History - -## 16.0.1 (Unreleased) - + +## 16.1.0 (2025-02-27) + ### Features Added -### Breaking Changes - -### Bugs Fixed - -### Other Changes - + - Added operation group SiteCertificates + - Added Interface SiteCertificatesCreateOrUpdateOptionalParams + - Added Interface SiteCertificatesCreateOrUpdateSlotOptionalParams + - Added Interface SiteCertificatesDeleteOptionalParams + - Added Interface SiteCertificatesDeleteSlotOptionalParams + - Added Interface SiteCertificatesGetOptionalParams + - Added Interface SiteCertificatesGetSlotOptionalParams + - Added Interface SiteCertificatesListNextOptionalParams + - Added Interface SiteCertificatesListOptionalParams + - Added Interface SiteCertificatesListSlotNextOptionalParams + - Added Interface SiteCertificatesListSlotOptionalParams + - Added Interface SiteCertificatesUpdateOptionalParams + - Added Interface SiteCertificatesUpdateSlotOptionalParams + - Added Type Alias SiteCertificatesCreateOrUpdateResponse + - Added Type Alias SiteCertificatesCreateOrUpdateSlotResponse + - Added Type Alias SiteCertificatesGetResponse + - Added Type Alias SiteCertificatesGetSlotResponse + - Added Type Alias SiteCertificatesListNextResponse + - Added Type Alias SiteCertificatesListResponse + - Added Type Alias SiteCertificatesListSlotNextResponse + - Added Type Alias SiteCertificatesListSlotResponse + - Added Type Alias SiteCertificatesUpdateResponse + - Added Type Alias SiteCertificatesUpdateSlotResponse + - Interface Site has a new optional parameter clientAffinityProxyEnabled + - Interface SitePatchResource has a new optional parameter clientAffinityProxyEnabled + + ## 16.0.0 (2025-02-12) ### Features Added diff --git a/sdk/appservice/arm-appservice/LICENSE b/sdk/appservice/arm-appservice/LICENSE index b2f52a2bad4e..2ad4de7b17f0 100644 --- a/sdk/appservice/arm-appservice/LICENSE +++ b/sdk/appservice/arm-appservice/LICENSE @@ -1,6 +1,6 @@ -Copyright (c) Microsoft Corporation. +The MIT License (MIT) -MIT License +Copyright (c) 2025 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -12,10 +12,10 @@ furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +SOFTWARE. \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/README.md b/sdk/appservice/arm-appservice/README.md index a435a23c9b37..a47018f173ad 100644 --- a/sdk/appservice/arm-appservice/README.md +++ b/sdk/appservice/arm-appservice/README.md @@ -47,33 +47,24 @@ You will also need to **register a new AAD application and grant access to Azure For more information about how to create an Azure AD Application check out [this guide](https://learn.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal). - -Using Node.js and Node-like environments, you can use the `DefaultAzureCredential` class to authenticate the client. - -```ts snippet:ReadmeSampleCreateClient_Node -import { WebSiteManagementClient } from "@azure/arm-appservice"; -import { DefaultAzureCredential } from "@azure/identity"; +```javascript +const { WebSiteManagementClient } = require("@azure/arm-appservice"); +const { DefaultAzureCredential } = require("@azure/identity"); +// For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details. const subscriptionId = "00000000-0000-0000-0000-000000000000"; const client = new WebSiteManagementClient(new DefaultAzureCredential(), subscriptionId); -``` - -For browser environments, use the `InteractiveBrowserCredential` from the `@azure/identity` package to authenticate. - -```ts snippet:ReadmeSampleCreateClient_Browser -import { InteractiveBrowserCredential } from "@azure/identity"; -import { WebSiteManagementClient } from "@azure/arm-appservice"; -const subscriptionId = "00000000-0000-0000-0000-000000000000"; -const credential = new InteractiveBrowserCredential({ - tenantId: "", - clientId: "", -}); -const client = new WebSiteManagementClient(credential, subscriptionId); +// For client-side applications running in the browser, use this code instead: +// const credential = new InteractiveBrowserCredential({ +// tenantId: "", +// clientId: "" +// }); +// const client = new WebSiteManagementClient(credential, subscriptionId); ``` -### JavaScript Bundle +### JavaScript Bundle To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling). ## Key concepts @@ -88,9 +79,8 @@ To use this client library in the browser, first you need to use a bundler. For Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`: -```ts snippet:SetLogLevel -import { setLogLevel } from "@azure/logger"; - +```javascript +const { setLogLevel } = require("@azure/logger"); setLogLevel("info"); ``` @@ -108,7 +98,7 @@ If you'd like to contribute to this library, please read the [contributing guide - [Microsoft Azure SDK for JavaScript](https://github.com/Azure/azure-sdk-for-js) - +![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Fappservice%2Farm-appservice%2FREADME.png) [azure_cli]: https://learn.microsoft.com/cli/azure [azure_sub]: https://azure.microsoft.com/free/ diff --git a/sdk/appservice/arm-appservice/_meta.json b/sdk/appservice/arm-appservice/_meta.json index e33dd81b9511..8e4171960db7 100644 --- a/sdk/appservice/arm-appservice/_meta.json +++ b/sdk/appservice/arm-appservice/_meta.json @@ -1,8 +1,8 @@ { - "commit": "20efe6fd4db8a494eab1852a8541fbabe5de569c", + "commit": "d92bf7cdbd4db7d68a73d24ac62bd86ed3842ff7", "readme": "specification/web/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\web\\resource-manager\\readme.md --use=@autorest/typescript@6.0.34 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/web/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.19", - "use": "@autorest/typescript@6.0.34" -} + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.21", + "use": "@autorest/typescript@^6.0.12" +} \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/api-extractor.json b/sdk/appservice/arm-appservice/api-extractor.json index 1807d1dd8662..8f48a64b5e1f 100644 --- a/sdk/appservice/arm-appservice/api-extractor.json +++ b/sdk/appservice/arm-appservice/api-extractor.json @@ -1,6 +1,6 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", - "mainEntryPointFilePath": "dist/esm/index.d.ts", + "mainEntryPointFilePath": "./dist-esm/src/index.d.ts", "docModel": { "enabled": true }, @@ -11,7 +11,7 @@ "dtsRollup": { "enabled": true, "untrimmedFilePath": "", - "publicTrimmedFilePath": "dist/arm-appservice.d.ts" + "publicTrimmedFilePath": "./types/arm-appservice.d.ts" }, "messages": { "tsdocMessageReporting": { @@ -28,4 +28,4 @@ } } } -} +} \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/package.json b/sdk/appservice/arm-appservice/package.json index 0e7201162519..77feae6a26b7 100644 --- a/sdk/appservice/arm-appservice/package.json +++ b/sdk/appservice/arm-appservice/package.json @@ -3,7 +3,7 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for WebSiteManagementClient.", - "version": "16.0.1", + "version": "16.1.0", "engines": { "node": ">=18.0.0" }, @@ -21,12 +21,11 @@ "azure", "typescript", "browser", - "isomorphic", - "cloud" + "isomorphic" ], "license": "MIT", "main": "./dist/commonjs/index.js", - "module": "./dist/esm/index.js", + "module": "./dist-esm/src/index.js", "types": "./dist/commonjs/index.d.ts", "devDependencies": { "@azure-tools/test-credential": "^2.0.0", @@ -34,16 +33,18 @@ "@azure-tools/test-utils-vitest": "^1.0.0", "@azure/dev-tool": "^1.0.0", "@azure/identity": "^4.7.0", - "@azure/logger": "^1.1.4", "@types/node": "^18.0.0", - "@vitest/browser": "^3.0.5", - "@vitest/coverage-istanbul": "^3.0.5", + "@vitest/browser": "^3.0.6", + "@vitest/coverage-istanbul": "^3.0.6", "dotenv": "^16.0.0", "playwright": "^1.50.1", "typescript": "~5.6.2", - "vitest": "^3.0.5" + "vitest": "^3.0.6" + }, + "repository": { + "type": "git", + "url": "https://github.com/Azure/azure-sdk-for-js.git" }, - "repository": "github:Azure/azure-sdk-for-js", "bugs": { "url": "https://github.com/Azure/azure-sdk-for-js/issues" }, @@ -78,7 +79,7 @@ "unit-test": "npm run unit-test:node && npm run unit-test:browser", "unit-test:browser": "echo skipped", "unit-test:node": "dev-tool run test:vitest", - "update-snippets": "dev-tool run update-snippets" + "update-snippets": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -91,14 +92,6 @@ }, "autoPublish": true, "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/appservice/arm-appservice", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://learn.microsoft.com/javascript/api/@azure/arm-appservice?view=azure-node-preview" - }, "type": "module", "tshy": { "project": "./tsconfig.src.json", @@ -139,4 +132,4 @@ } } } -} +} \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/review/arm-appservice.api.md b/sdk/appservice/arm-appservice/review/arm-appservice.api.md index c9a129c4c869..d661e48089db 100644 --- a/sdk/appservice/arm-appservice/review/arm-appservice.api.md +++ b/sdk/appservice/arm-appservice/review/arm-appservice.api.md @@ -5962,6 +5962,7 @@ export interface Site extends Resource { autoGeneratedDomainNameLabelScope?: AutoGeneratedDomainNameLabelScope; readonly availabilityState?: SiteAvailabilityState; clientAffinityEnabled?: boolean; + clientAffinityProxyEnabled?: boolean; clientCertEnabled?: boolean; clientCertExclusionPaths?: string; clientCertMode?: ClientCertMode; @@ -6073,6 +6074,98 @@ export interface SiteAuthSettingsV2 extends ProxyOnlyResource { // @public export type SiteAvailabilityState = "Normal" | "Limited" | "DisasterRecoveryMode"; +// @public +export interface SiteCertificates { + createOrUpdate(resourceGroupName: string, name: string, certificateName: string, certificateEnvelope: Certificate, options?: SiteCertificatesCreateOrUpdateOptionalParams): Promise; + createOrUpdateSlot(resourceGroupName: string, name: string, slot: string, certificateName: string, certificateEnvelope: Certificate, options?: SiteCertificatesCreateOrUpdateSlotOptionalParams): Promise; + delete(resourceGroupName: string, name: string, certificateName: string, options?: SiteCertificatesDeleteOptionalParams): Promise; + deleteSlot(resourceGroupName: string, name: string, slot: string, certificateName: string, options?: SiteCertificatesDeleteSlotOptionalParams): Promise; + get(resourceGroupName: string, name: string, certificateName: string, options?: SiteCertificatesGetOptionalParams): Promise; + getSlot(resourceGroupName: string, name: string, slot: string, certificateName: string, options?: SiteCertificatesGetSlotOptionalParams): Promise; + list(resourceGroupName: string, name: string, options?: SiteCertificatesListOptionalParams): PagedAsyncIterableIterator; + listSlot(resourceGroupName: string, name: string, slot: string, options?: SiteCertificatesListSlotOptionalParams): PagedAsyncIterableIterator; + update(resourceGroupName: string, name: string, certificateName: string, certificateEnvelope: CertificatePatchResource, options?: SiteCertificatesUpdateOptionalParams): Promise; + updateSlot(resourceGroupName: string, name: string, slot: string, certificateName: string, certificateEnvelope: CertificatePatchResource, options?: SiteCertificatesUpdateSlotOptionalParams): Promise; +} + +// @public +export interface SiteCertificatesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesCreateOrUpdateResponse = Certificate; + +// @public +export interface SiteCertificatesCreateOrUpdateSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesCreateOrUpdateSlotResponse = Certificate; + +// @public +export interface SiteCertificatesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface SiteCertificatesDeleteSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface SiteCertificatesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesGetResponse = Certificate; + +// @public +export interface SiteCertificatesGetSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesGetSlotResponse = Certificate; + +// @public +export interface SiteCertificatesListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesListNextResponse = CertificateCollection; + +// @public +export interface SiteCertificatesListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesListResponse = CertificateCollection; + +// @public +export interface SiteCertificatesListSlotNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesListSlotNextResponse = CertificateCollection; + +// @public +export interface SiteCertificatesListSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesListSlotResponse = CertificateCollection; + +// @public +export interface SiteCertificatesUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesUpdateResponse = Certificate; + +// @public +export interface SiteCertificatesUpdateSlotOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SiteCertificatesUpdateSlotResponse = Certificate; + // @public export interface SiteCloneability { blockingCharacteristics?: SiteCloneabilityCriterion[]; @@ -6365,6 +6458,7 @@ export interface SiteMachineKey { export interface SitePatchResource extends ProxyOnlyResource { readonly availabilityState?: SiteAvailabilityState; clientAffinityEnabled?: boolean; + clientAffinityProxyEnabled?: boolean; clientCertEnabled?: boolean; clientCertExclusionPaths?: string; clientCertMode?: ClientCertMode; @@ -11944,6 +12038,8 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { // (undocumented) resourceHealthMetadataOperations: ResourceHealthMetadataOperations; // (undocumented) + siteCertificates: SiteCertificates; + // (undocumented) staticSites: StaticSites; // (undocumented) subscriptionId?: string; diff --git a/sdk/appservice/arm-appservice/src/lroImpl.ts b/sdk/appservice/arm-appservice/src/lroImpl.ts index d8bc98987053..5f88efab981b 100644 --- a/sdk/appservice/arm-appservice/src/lroImpl.ts +++ b/sdk/appservice/arm-appservice/src/lroImpl.ts @@ -5,6 +5,10 @@ * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ + +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. + import { AbortSignalLike } from "@azure/abort-controller"; import { LongRunningOperation, LroResponse } from "@azure/core-lro"; diff --git a/sdk/appservice/arm-appservice/src/models/index.ts b/sdk/appservice/arm-appservice/src/models/index.ts index a8202ae85839..5ac0f35b2750 100644 --- a/sdk/appservice/arm-appservice/src/models/index.ts +++ b/sdk/appservice/arm-appservice/src/models/index.ts @@ -5371,6 +5371,8 @@ export interface Site extends Resource { hostingEnvironmentProfile?: HostingEnvironmentProfile; /** true to enable client affinity; false to stop sending session affinity cookies, which route client requests in the same session to the same instance. Default is true. */ clientAffinityEnabled?: boolean; + /** true to override client affinity cookie domain with X-Forwarded-Host request header. false to use default domain. Default is false. */ + clientAffinityProxyEnabled?: boolean; /** true to enable client certificate authentication (TLS mutual authentication); otherwise, false. Default is false. */ clientCertEnabled?: boolean; /** @@ -5626,16 +5628,16 @@ export interface Certificate extends Resource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly hostingEnvironmentProfile?: HostingEnvironmentProfile; - /** Key Vault Csm resource Id. */ + /** Azure Key Vault Csm resource Id. */ keyVaultId?: string; - /** Key Vault secret name. */ + /** Azure Key Vault secret name. */ keyVaultSecretName?: string; /** * Status of the Key Vault secret. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly keyVaultSecretStatus?: KeyVaultSecretStatus; - /** Resource ID of the associated App Service plan, formatted as: "/subscriptions/{subscriptionID}/resourceGroups/{groupName}/providers/Microsoft.Web/serverfarms/{appServicePlanName}". */ + /** Resource ID of the associated App Service plan. */ serverFarmId?: string; /** CNAME of the certificate to be issued via free certificate */ canonicalName?: string; @@ -7436,6 +7438,8 @@ export interface SitePatchResource extends ProxyOnlyResource { hostingEnvironmentProfile?: HostingEnvironmentProfile; /** true to enable client affinity; false to stop sending session affinity cookies, which route client requests in the same session to the same instance. Default is true. */ clientAffinityEnabled?: boolean; + /** true to override client affinity cookie domain with X-Forwarded-Host request header. false to use default domain. Default is false. */ + clientAffinityProxyEnabled?: boolean; /** true to enable client certificate authentication (TLS mutual authentication); otherwise, false. Default is false. */ clientCertEnabled?: boolean; /** @@ -13224,6 +13228,84 @@ export interface GetUsagesInLocationListNextOptionalParams /** Contains response data for the listNext operation. */ export type GetUsagesInLocationListNextResponse = CsmUsageQuotaCollection; +/** Optional parameters. */ +export interface SiteCertificatesListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type SiteCertificatesListResponse = CertificateCollection; + +/** Optional parameters. */ +export interface SiteCertificatesGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type SiteCertificatesGetResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type SiteCertificatesCreateOrUpdateResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface SiteCertificatesUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the update operation. */ +export type SiteCertificatesUpdateResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesListSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listSlot operation. */ +export type SiteCertificatesListSlotResponse = CertificateCollection; + +/** Optional parameters. */ +export interface SiteCertificatesGetSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getSlot operation. */ +export type SiteCertificatesGetSlotResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesCreateOrUpdateSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdateSlot operation. */ +export type SiteCertificatesCreateOrUpdateSlotResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesDeleteSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface SiteCertificatesUpdateSlotOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the updateSlot operation. */ +export type SiteCertificatesUpdateSlotResponse = Certificate; + +/** Optional parameters. */ +export interface SiteCertificatesListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type SiteCertificatesListNextResponse = CertificateCollection; + +/** Optional parameters. */ +export interface SiteCertificatesListSlotNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listSlotNext operation. */ +export type SiteCertificatesListSlotNextResponse = CertificateCollection; + /** Optional parameters. */ export interface StaticSitesPreviewWorkflowOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/appservice/arm-appservice/src/models/mappers.ts b/sdk/appservice/arm-appservice/src/models/mappers.ts index 08302eb3d90c..27d9d5446a05 100644 --- a/sdk/appservice/arm-appservice/src/models/mappers.ts +++ b/sdk/appservice/arm-appservice/src/models/mappers.ts @@ -16156,6 +16156,13 @@ export const Site: coreClient.CompositeMapper = { name: "Boolean", }, }, + clientAffinityProxyEnabled: { + serializedName: "properties.clientAffinityProxyEnabled", + xmlName: "properties.clientAffinityProxyEnabled", + type: { + name: "Boolean", + }, + }, clientCertEnabled: { serializedName: "properties.clientCertEnabled", xmlName: "properties.clientCertEnabled", @@ -21691,6 +21698,13 @@ export const SitePatchResource: coreClient.CompositeMapper = { name: "Boolean", }, }, + clientAffinityProxyEnabled: { + serializedName: "properties.clientAffinityProxyEnabled", + xmlName: "properties.clientAffinityProxyEnabled", + type: { + name: "Boolean", + }, + }, clientCertEnabled: { serializedName: "properties.clientCertEnabled", xmlName: "properties.clientCertEnabled", diff --git a/sdk/appservice/arm-appservice/src/models/parameters.ts b/sdk/appservice/arm-appservice/src/models/parameters.ts index 6b83c2ba29fa..ac0cf0c5d366 100644 --- a/sdk/appservice/arm-appservice/src/models/parameters.ts +++ b/sdk/appservice/arm-appservice/src/models/parameters.ts @@ -140,7 +140,7 @@ export const subscriptionId: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2024-04-01", + defaultValue: "2024-11-01", isConstant: true, serializedName: "api-version", type: { @@ -977,6 +977,64 @@ export const location1: OperationURLParameter = { }, }; +export const resourceGroupName1: OperationURLParameter = { + parameterPath: "resourceGroupName", + mapper: { + constraints: { + MaxLength: 90, + MinLength: 1, + }, + serializedName: "resourceGroupName", + required: true, + xmlName: "resourceGroupName", + type: { + name: "String", + }, + }, +}; + +export const name2: OperationURLParameter = { + parameterPath: "name", + mapper: { + constraints: { + Pattern: new RegExp("^[A-z][A-z0-9]*$"), + }, + serializedName: "name", + required: true, + xmlName: "name", + type: { + name: "String", + }, + }, +}; + +export const certificateName: OperationURLParameter = { + parameterPath: "certificateName", + mapper: { + constraints: { + Pattern: new RegExp("^[A-z][A-z0-9]*$"), + }, + serializedName: "certificateName", + required: true, + xmlName: "certificateName", + type: { + name: "String", + }, + }, +}; + +export const certificateName1: OperationURLParameter = { + parameterPath: "certificateName", + mapper: { + serializedName: "certificateName", + required: true, + xmlName: "certificateName", + type: { + name: "String", + }, + }, +}; + export const staticSitesWorkflowPreviewRequest: OperationParameter = { parameterPath: "staticSitesWorkflowPreviewRequest", mapper: StaticSitesWorkflowPreviewRequestMapper, diff --git a/sdk/appservice/arm-appservice/src/operations/index.ts b/sdk/appservice/arm-appservice/src/operations/index.ts index ac6566b1dd58..56a646583b80 100644 --- a/sdk/appservice/arm-appservice/src/operations/index.ts +++ b/sdk/appservice/arm-appservice/src/operations/index.ts @@ -23,6 +23,7 @@ export * from "./provider.js"; export * from "./recommendations.js"; export * from "./resourceHealthMetadataOperations.js"; export * from "./getUsagesInLocation.js"; +export * from "./siteCertificates.js"; export * from "./staticSites.js"; export * from "./webApps.js"; export * from "./workflows.js"; diff --git a/sdk/appservice/arm-appservice/src/operations/siteCertificates.ts b/sdk/appservice/arm-appservice/src/operations/siteCertificates.ts new file mode 100644 index 000000000000..a0834db41013 --- /dev/null +++ b/sdk/appservice/arm-appservice/src/operations/siteCertificates.ts @@ -0,0 +1,767 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; +import { setContinuationToken } from "../pagingHelper.js"; +import { SiteCertificates } from "../operationsInterfaces/index.js"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers.js"; +import * as Parameters from "../models/parameters.js"; +import { WebSiteManagementClient } from "../webSiteManagementClient.js"; +import { + Certificate, + SiteCertificatesListNextOptionalParams, + SiteCertificatesListOptionalParams, + SiteCertificatesListResponse, + SiteCertificatesListSlotNextOptionalParams, + SiteCertificatesListSlotOptionalParams, + SiteCertificatesListSlotResponse, + SiteCertificatesGetOptionalParams, + SiteCertificatesGetResponse, + SiteCertificatesCreateOrUpdateOptionalParams, + SiteCertificatesCreateOrUpdateResponse, + SiteCertificatesDeleteOptionalParams, + CertificatePatchResource, + SiteCertificatesUpdateOptionalParams, + SiteCertificatesUpdateResponse, + SiteCertificatesGetSlotOptionalParams, + SiteCertificatesGetSlotResponse, + SiteCertificatesCreateOrUpdateSlotOptionalParams, + SiteCertificatesCreateOrUpdateSlotResponse, + SiteCertificatesDeleteSlotOptionalParams, + SiteCertificatesUpdateSlotOptionalParams, + SiteCertificatesUpdateSlotResponse, + SiteCertificatesListNextResponse, + SiteCertificatesListSlotNextResponse, +} from "../models/index.js"; + +/// +/** Class containing SiteCertificates operations. */ +export class SiteCertificatesImpl implements SiteCertificates { + private readonly client: WebSiteManagementClient; + + /** + * Initialize a new instance of the class SiteCertificates class. + * @param client Reference to the service client + */ + constructor(client: WebSiteManagementClient) { + this.client = client; + } + + /** + * Get all certificates in a resource group under a site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param options The options parameters. + */ + public list( + resourceGroupName: string, + name: string, + options?: SiteCertificatesListOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(resourceGroupName, name, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listPagingPage(resourceGroupName, name, options, settings); + }, + }; + } + + private async *listPagingPage( + resourceGroupName: string, + name: string, + options?: SiteCertificatesListOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: SiteCertificatesListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(resourceGroupName, name, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext( + resourceGroupName, + name, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + resourceGroupName: string, + name: string, + options?: SiteCertificatesListOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + resourceGroupName, + name, + options, + )) { + yield* page; + } + } + + /** + * Get all certificates in a resource group for a given site and a deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param options The options parameters. + */ + public listSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: SiteCertificatesListSlotOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listSlotPagingAll(resourceGroupName, name, slot, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listSlotPagingPage( + resourceGroupName, + name, + slot, + options, + settings, + ); + }, + }; + } + + private async *listSlotPagingPage( + resourceGroupName: string, + name: string, + slot: string, + options?: SiteCertificatesListSlotOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: SiteCertificatesListSlotResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listSlot(resourceGroupName, name, slot, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listSlotNext( + resourceGroupName, + name, + slot, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listSlotPagingAll( + resourceGroupName: string, + name: string, + slot: string, + options?: SiteCertificatesListSlotOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listSlotPagingPage( + resourceGroupName, + name, + slot, + options, + )) { + yield* page; + } + } + + /** + * Get all certificates in a resource group under a site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param options The options parameters. + */ + private _list( + resourceGroupName: string, + name: string, + options?: SiteCertificatesListOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, options }, + listOperationSpec, + ); + } + + /** + * Get a certificate belonging to a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + name: string, + certificateName: string, + options?: SiteCertificatesGetOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, certificateName, options }, + getOperationSpec, + ); + } + + /** + * Create or update a certificate under a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + name: string, + certificateName: string, + certificateEnvelope: Certificate, + options?: SiteCertificatesCreateOrUpdateOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + certificateName, + certificateEnvelope, + options, + }, + createOrUpdateOperationSpec, + ); + } + + /** + * Delete a certificate from the site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + name: string, + certificateName: string, + options?: SiteCertificatesDeleteOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, certificateName, options }, + deleteOperationSpec, + ); + } + + /** + * Create or update a certificate under a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + update( + resourceGroupName: string, + name: string, + certificateName: string, + certificateEnvelope: CertificatePatchResource, + options?: SiteCertificatesUpdateOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + certificateName, + certificateEnvelope, + options, + }, + updateOperationSpec, + ); + } + + /** + * Get all certificates in a resource group for a given site and a deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param options The options parameters. + */ + private _listSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: SiteCertificatesListSlotOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, options }, + listSlotOperationSpec, + ); + } + + /** + * Get a certificate for a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + getSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + options?: SiteCertificatesGetSlotOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, certificateName, options }, + getSlotOperationSpec, + ); + } + + /** + * Create or update a certificate in a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + createOrUpdateSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + certificateEnvelope: Certificate, + options?: SiteCertificatesCreateOrUpdateSlotOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + slot, + certificateName, + certificateEnvelope, + options, + }, + createOrUpdateSlotOperationSpec, + ); + } + + /** + * Delete a certificate for a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + deleteSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + options?: SiteCertificatesDeleteSlotOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, certificateName, options }, + deleteSlotOperationSpec, + ); + } + + /** + * Create or update a certificate for a site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + updateSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + certificateEnvelope: CertificatePatchResource, + options?: SiteCertificatesUpdateSlotOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + name, + slot, + certificateName, + certificateEnvelope, + options, + }, + updateSlotOperationSpec, + ); + } + + /** + * ListNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + resourceGroupName: string, + name: string, + nextLink: string, + options?: SiteCertificatesListNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, nextLink, options }, + listNextOperationSpec, + ); + } + + /** + * ListSlotNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param nextLink The nextLink from the previous successful call to the ListSlot method. + * @param options The options parameters. + */ + private _listSlotNext( + resourceGroupName: string, + name: string, + slot: string, + nextLink: string, + options?: SiteCertificatesListSlotNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, name, slot, nextLink, options }, + listSlotNextOperationSpec, + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.CertificateCollection, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName1, + Parameters.name2, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates/{certificateName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Certificate, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName1, + Parameters.name2, + Parameters.certificateName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates/{certificateName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Certificate, + }, + 201: { + bodyMapper: Mappers.Certificate, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + requestBody: Parameters.certificateEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName1, + Parameters.name2, + Parameters.certificateName1, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates/{certificateName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.name, + Parameters.resourceGroupName1, + Parameters.certificateName1, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const updateOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/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.name, + Parameters.resourceGroupName1, + Parameters.certificateName1, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, +}; +const listSlotOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.CertificateCollection, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.name2, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getSlotOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates/{certificateName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Certificate, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.name2, + Parameters.certificateName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateSlotOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates/{certificateName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Certificate, + }, + 201: { + bodyMapper: Mappers.Certificate, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + requestBody: Parameters.certificateEnvelope, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.name, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.certificateName1, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, +}; +const deleteSlotOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates/{certificateName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.name, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.certificateName1, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const updateSlotOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/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.name, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.certificateName1, + ], + 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, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.nextLink, + Parameters.resourceGroupName1, + Parameters.name2, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listSlotNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.CertificateCollection, + }, + default: { + bodyMapper: Mappers.DefaultErrorResponse, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.nextLink, + Parameters.slot, + Parameters.resourceGroupName1, + Parameters.name2, + ], + headerParameters: [Parameters.accept], + serializer, +}; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/index.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/index.ts index ac6566b1dd58..56a646583b80 100644 --- a/sdk/appservice/arm-appservice/src/operationsInterfaces/index.ts +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/index.ts @@ -23,6 +23,7 @@ export * from "./provider.js"; export * from "./recommendations.js"; export * from "./resourceHealthMetadataOperations.js"; export * from "./getUsagesInLocation.js"; +export * from "./siteCertificates.js"; export * from "./staticSites.js"; export * from "./webApps.js"; export * from "./workflows.js"; diff --git a/sdk/appservice/arm-appservice/src/operationsInterfaces/siteCertificates.ts b/sdk/appservice/arm-appservice/src/operationsInterfaces/siteCertificates.ts new file mode 100644 index 000000000000..8040380ffcb8 --- /dev/null +++ b/sdk/appservice/arm-appservice/src/operationsInterfaces/siteCertificates.ts @@ -0,0 +1,183 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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, + SiteCertificatesListOptionalParams, + SiteCertificatesListSlotOptionalParams, + SiteCertificatesGetOptionalParams, + SiteCertificatesGetResponse, + SiteCertificatesCreateOrUpdateOptionalParams, + SiteCertificatesCreateOrUpdateResponse, + SiteCertificatesDeleteOptionalParams, + CertificatePatchResource, + SiteCertificatesUpdateOptionalParams, + SiteCertificatesUpdateResponse, + SiteCertificatesGetSlotOptionalParams, + SiteCertificatesGetSlotResponse, + SiteCertificatesCreateOrUpdateSlotOptionalParams, + SiteCertificatesCreateOrUpdateSlotResponse, + SiteCertificatesDeleteSlotOptionalParams, + SiteCertificatesUpdateSlotOptionalParams, + SiteCertificatesUpdateSlotResponse, +} from "../models/index.js"; + +/// +/** Interface representing a SiteCertificates. */ +export interface SiteCertificates { + /** + * Get all certificates in a resource group under a site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + name: string, + options?: SiteCertificatesListOptionalParams, + ): PagedAsyncIterableIterator; + /** + * Get all certificates in a resource group for a given site and a deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param options The options parameters. + */ + listSlot( + resourceGroupName: string, + name: string, + slot: string, + options?: SiteCertificatesListSlotOptionalParams, + ): PagedAsyncIterableIterator; + /** + * Get a certificate belonging to a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + name: string, + certificateName: string, + options?: SiteCertificatesGetOptionalParams, + ): Promise; + /** + * Create or update a certificate under a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + name: string, + certificateName: string, + certificateEnvelope: Certificate, + options?: SiteCertificatesCreateOrUpdateOptionalParams, + ): Promise; + /** + * Delete a certificate from the site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + name: string, + certificateName: string, + options?: SiteCertificatesDeleteOptionalParams, + ): Promise; + /** + * Create or update a certificate under a given site. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + update( + resourceGroupName: string, + name: string, + certificateName: string, + certificateEnvelope: CertificatePatchResource, + options?: SiteCertificatesUpdateOptionalParams, + ): Promise; + /** + * Get a certificate for a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + getSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + options?: SiteCertificatesGetSlotOptionalParams, + ): Promise; + /** + * Create or update a certificate in a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + createOrUpdateSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + certificateEnvelope: Certificate, + options?: SiteCertificatesCreateOrUpdateSlotOptionalParams, + ): Promise; + /** + * Delete a certificate for a given site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param options The options parameters. + */ + deleteSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + options?: SiteCertificatesDeleteSlotOptionalParams, + ): Promise; + /** + * Create or update a certificate for a site and deployment slot. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param name Name of the site. + * @param slot Name of the deployment slot. If a slot is not specified, the API will create a binding + * for the production slot. + * @param certificateName Name of the certificate. + * @param certificateEnvelope Details of certificate, if it exists already. + * @param options The options parameters. + */ + updateSlot( + resourceGroupName: string, + name: string, + slot: string, + certificateName: string, + certificateEnvelope: CertificatePatchResource, + options?: SiteCertificatesUpdateSlotOptionalParams, + ): Promise; +} diff --git a/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts b/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts index e3e2a7a4528c..981c1e73903b 100644 --- a/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts +++ b/sdk/appservice/arm-appservice/src/webSiteManagementClient.ts @@ -34,6 +34,7 @@ import { RecommendationsImpl, ResourceHealthMetadataOperationsImpl, GetUsagesInLocationImpl, + SiteCertificatesImpl, StaticSitesImpl, WebAppsImpl, WorkflowsImpl, @@ -64,6 +65,7 @@ import { Recommendations, ResourceHealthMetadataOperations, GetUsagesInLocation, + SiteCertificates, StaticSites, WebApps, Workflows, @@ -191,7 +193,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { credential: credentials, }; - const packageDetails = `azsdk-js-arm-appservice/16.0.1`; + const packageDetails = `azsdk-js-arm-appservice/16.1.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -245,7 +247,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2024-04-01"; + this.apiVersion = options.apiVersion || "2024-11-01"; this.appServiceCertificateOrders = new AppServiceCertificateOrdersImpl( this, ); @@ -269,6 +271,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { this.resourceHealthMetadataOperations = new ResourceHealthMetadataOperationsImpl(this); this.getUsagesInLocation = new GetUsagesInLocationImpl(this); + this.siteCertificates = new SiteCertificatesImpl(this); this.staticSites = new StaticSitesImpl(this); this.webApps = new WebAppsImpl(this); this.workflows = new WorkflowsImpl(this); @@ -1098,6 +1101,7 @@ export class WebSiteManagementClient extends coreClient.ServiceClient { recommendations: Recommendations; resourceHealthMetadataOperations: ResourceHealthMetadataOperations; getUsagesInLocation: GetUsagesInLocation; + siteCertificates: SiteCertificates; staticSites: StaticSites; webApps: WebApps; workflows: Workflows; diff --git a/sdk/appservice/arm-appservice/test/sampleTest.ts b/sdk/appservice/arm-appservice/test/sampleTest.ts new file mode 100644 index 000000000000..a1cf7c25afd2 --- /dev/null +++ b/sdk/appservice/arm-appservice/test/sampleTest.ts @@ -0,0 +1,40 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, +} from "@azure-tools/test-recorder"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async (ctx) => { + recorder = new Recorder(ctx); + await recorder.start(recorderOptions); + }); + + afterEach(async () => { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/appservice/arm-appservice/tsconfig.browser.config.json b/sdk/appservice/arm-appservice/tsconfig.browser.config.json index 75871518e3a0..0c8bafa97126 100644 --- a/sdk/appservice/arm-appservice/tsconfig.browser.config.json +++ b/sdk/appservice/arm-appservice/tsconfig.browser.config.json @@ -1,3 +1,6 @@ { - "extends": ["./tsconfig.test.json", "../../../tsconfig.browser.base.json"] + "extends": [ + "./tsconfig.test.json", + "../../../tsconfig.browser.base.json" + ] } diff --git a/sdk/appservice/arm-appservice/tsconfig.json b/sdk/appservice/arm-appservice/tsconfig.json index 19ceb382b521..b35d05ad6e9d 100644 --- a/sdk/appservice/arm-appservice/tsconfig.json +++ b/sdk/appservice/arm-appservice/tsconfig.json @@ -1,13 +1,27 @@ { - "references": [ - { - "path": "./tsconfig.src.json" - }, - { - "path": "./tsconfig.samples.json" - }, - { - "path": "./tsconfig.test.json" - } + "compilerOptions": { + "module": "es6", + "moduleResolution": "node", + "strict": true, + "target": "es6", + "sourceMap": true, + "declarationMap": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "forceConsistentCasingInFileNames": true, + "lib": [ + "es6", + "dom" + ], + "declaration": true, + "outDir": "./dist-esm", + "importHelpers": true + }, + "include": [ + "src/**/*.ts", + "test/**/*.ts" + ], + "exclude": [ + "node_modules" ] -} +} \ No newline at end of file diff --git a/sdk/appservice/arm-appservice/tsconfig.samples.json b/sdk/appservice/arm-appservice/tsconfig.samples.json index 4ca8696f5d98..c8de4eac8419 100644 --- a/sdk/appservice/arm-appservice/tsconfig.samples.json +++ b/sdk/appservice/arm-appservice/tsconfig.samples.json @@ -2,7 +2,9 @@ "extends": "../../../tsconfig.samples.base.json", "compilerOptions": { "paths": { - "@azure/arm-appservice": ["./dist/esm"] + "@azure/arm-appservice": [ + "./dist/esm" + ] } } } diff --git a/sdk/appservice/arm-appservice/tsconfig.test.json b/sdk/appservice/arm-appservice/tsconfig.test.json index 290ca214aebc..3c2b783a8c1b 100644 --- a/sdk/appservice/arm-appservice/tsconfig.test.json +++ b/sdk/appservice/arm-appservice/tsconfig.test.json @@ -1,3 +1,6 @@ { - "extends": ["./tsconfig.src.json", "../../../tsconfig.test.base.json"] + "extends": [ + "./tsconfig.src.json", + "../../../tsconfig.test.base.json" + ] } diff --git a/sdk/appservice/arm-appservice/vitest.browser.config.ts b/sdk/appservice/arm-appservice/vitest.browser.config.ts index 10e70dbfa8ee..182729ab5ce9 100644 --- a/sdk/appservice/arm-appservice/vitest.browser.config.ts +++ b/sdk/appservice/arm-appservice/vitest.browser.config.ts @@ -1,3 +1,4 @@ + // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. @@ -8,7 +9,7 @@ export default mergeConfig( viteConfig, defineConfig({ test: { - include: ["dist-test/browser/test/**/*.spec.js"], + include: ["dist-test/browser/test/**/*.spec.js",], testTimeout: 1200000, hookTimeout: 1200000, }, diff --git a/sdk/appservice/arm-appservice/vitest.config.ts b/sdk/appservice/arm-appservice/vitest.config.ts index 86a71911ccc2..40e031385dd8 100644 --- a/sdk/appservice/arm-appservice/vitest.config.ts +++ b/sdk/appservice/arm-appservice/vitest.config.ts @@ -1,3 +1,4 @@ + // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. diff --git a/sdk/appservice/arm-appservice/vitest.esm.config.ts b/sdk/appservice/arm-appservice/vitest.esm.config.ts index 5e9735e9b144..a70127279fc9 100644 --- a/sdk/appservice/arm-appservice/vitest.esm.config.ts +++ b/sdk/appservice/arm-appservice/vitest.esm.config.ts @@ -1,3 +1,4 @@ + // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. @@ -5,4 +6,7 @@ import { mergeConfig } from "vitest/config"; import vitestConfig from "./vitest.config.ts"; import vitestEsmConfig from "../../../vitest.esm.shared.config.ts"; -export default mergeConfig(vitestConfig, vitestEsmConfig); +export default mergeConfig( + vitestConfig, + vitestEsmConfig +);