From 0e53e64b46aba627720fe48d3d15e5c4a76f30ae Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Wed, 25 Oct 2023 01:39:45 +0000 Subject: [PATCH] CodeGen from PR 26202 in Azure/azure-rest-api-specs [Hub Generated] Publish private branch 'archidda-azureintegrationspaces-Microsoft.IntegrationSpaces-2023-11-14-preview' (#26202) * add or modify files * Address CI errors --- common/config/rush/pnpm-lock.yaml | 71 +- rush.json | 9 +- .../arm-azureintegrationspaces/CHANGELOG.md | 5 + .../arm-azureintegrationspaces/LICENSE | 21 + .../arm-azureintegrationspaces/README.md | 109 ++ .../arm-azureintegrationspaces/_meta.json | 8 + .../api-extractor.json | 31 + .../arm-azureintegrationspaces/package.json | 116 ++ .../review/arm-azureintegrationspaces.api.md | 794 ++++++++++ .../rollup.config.js | 122 ++ .../arm-azureintegrationspaces/sample.env | 4 + .../arm-azureintegrationspaces/src/index.ts | 13 + .../src/microsoftIntegrationSpaces.ts | 168 +++ .../src/models/index.ts | 988 +++++++++++++ .../src/models/mappers.ts | 1305 +++++++++++++++++ .../src/models/parameters.ts | 346 +++++ .../src/operations/applicationResources.ts | 438 ++++++ .../src/operations/applications.ts | 625 ++++++++ .../src/operations/businessProcessVersions.ts | 311 ++++ .../src/operations/businessProcesses.ts | 450 ++++++ .../src/operations/index.ts | 15 + .../src/operations/infrastructureResources.ts | 405 +++++ .../src/operations/operations.ts | 149 ++ .../src/operations/spaces.ts | 486 ++++++ .../applicationResources.ts | 103 ++ .../src/operationsInterfaces/applications.ts | 176 +++ .../businessProcessVersions.ts | 52 + .../operationsInterfaces/businessProcesses.ts | 103 ++ .../src/operationsInterfaces/index.ts | 15 + .../infrastructureResources.ts | 93 ++ .../src/operationsInterfaces/operations.ts | 22 + .../src/operationsInterfaces/spaces.ts | 91 ++ .../src/pagingHelper.ts | 39 + .../test/sampleTest.ts | 43 + .../arm-azureintegrationspaces/tsconfig.json | 27 + sdk/azureintegrationspaces/ci.mgmt.yml | 38 + 36 files changed, 7786 insertions(+), 5 deletions(-) create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/CHANGELOG.md create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/LICENSE create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/README.md create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/_meta.json create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/api-extractor.json create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/package.json create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/review/arm-azureintegrationspaces.api.md create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/rollup.config.js create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/sample.env create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/index.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/microsoftIntegrationSpaces.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/index.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/mappers.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/parameters.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applicationResources.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applications.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcessVersions.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcesses.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/index.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/infrastructureResources.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/operations.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/spaces.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applicationResources.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applications.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcessVersions.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcesses.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/index.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/infrastructureResources.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/operations.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/spaces.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/src/pagingHelper.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/test/sampleTest.ts create mode 100644 sdk/azureintegrationspaces/arm-azureintegrationspaces/tsconfig.json create mode 100644 sdk/azureintegrationspaces/ci.mgmt.yml diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index a9d46d020fc8..9936349d7967 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -113,6 +113,9 @@ dependencies: '@rush-temp/arm-azureadexternalidentities': specifier: file:./projects/arm-azureadexternalidentities.tgz version: file:projects/arm-azureadexternalidentities.tgz + '@rush-temp/arm-azureintegrationspaces': + specifier: file:./projects/arm-azureintegrationspaces.tgz + version: file:projects/arm-azureintegrationspaces.tgz '@rush-temp/arm-azurestack': specifier: file:./projects/arm-azurestack.tgz version: file:projects/arm-azurestack.tgz @@ -2928,7 +2931,7 @@ packages: /@types/decompress@4.2.5: resolution: {integrity: sha512-LdL+kbcKGs9TzvB/K+OBGzPfDoP6gwwTsykYjodlzUJUUYp/43c1p1jE5YTtz3z4Ml90iruvBXbJ6+kDvb3WSQ==} dependencies: - '@types/node': 16.18.55 + '@types/node': 18.18.6 dev: false /@types/eslint@8.44.3: @@ -8956,6 +8959,37 @@ packages: code-block-writer: 12.0.0 dev: false + /ts-node@10.9.1(@types/node@16.18.55)(typescript@5.0.4): + resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} + hasBin: true + peerDependencies: + '@swc/core': '>=1.2.50' + '@swc/wasm': '>=1.2.50' + '@types/node': '*' + typescript: '>=2.7' + peerDependenciesMeta: + '@swc/core': + optional: true + '@swc/wasm': + optional: true + dependencies: + '@cspotcode/source-map-support': 0.8.1 + '@tsconfig/node10': 1.0.9 + '@tsconfig/node12': 1.0.11 + '@tsconfig/node14': 1.0.3 + '@tsconfig/node16': 1.0.4 + '@types/node': 16.18.55 + acorn: 8.10.0 + acorn-walk: 8.2.0 + arg: 4.1.3 + create-require: 1.1.1 + diff: 4.0.2 + make-error: 1.3.6 + typescript: 5.0.4 + v8-compile-cache-lib: 3.0.1 + yn: 3.1.1 + dev: false + /ts-node@10.9.1(@types/node@16.18.55)(typescript@5.2.2): resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} hasBin: true @@ -10996,6 +11030,37 @@ packages: - '@swc/wasm' dev: false + file:projects/arm-azureintegrationspaces.tgz: + resolution: {integrity: sha512-kl6QmJC2pygb+EF0DSP+Pp+/XA3LcmnCE5vmPFTzgFQAmL6Gs+jEqyDu14uYFLJttXeAwvqMTh3mIInscAthrg==, tarball: file:projects/arm-azureintegrationspaces.tgz} + name: '@rush-temp/arm-azureintegrationspaces' + version: 0.0.0 + dependencies: + '@microsoft/api-extractor': 7.38.0(@types/node@16.18.55) + '@rollup/plugin-commonjs': 24.1.0(rollup@2.79.1) + '@rollup/plugin-json': 6.0.0(rollup@2.79.1) + '@rollup/plugin-multi-entry': 6.0.0(rollup@2.79.1) + '@rollup/plugin-node-resolve': 13.3.0(rollup@2.79.1) + '@types/chai': 4.3.6 + '@types/mocha': 10.0.2 + '@types/node': 16.18.55 + chai: 4.3.10 + cross-env: 7.0.3 + dotenv: 16.3.1 + esm: 3.2.25 + mkdirp: 2.1.6 + mocha: 10.2.0 + rimraf: 5.0.5 + rollup: 2.79.1 + rollup-plugin-sourcemaps: 0.6.3(@types/node@16.18.55)(rollup@2.79.1) + ts-node: 10.9.1(@types/node@16.18.55)(typescript@5.0.4) + tslib: 2.6.2 + typescript: 5.0.4 + uglify-js: 3.17.4 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + dev: false + file:projects/arm-azurestack.tgz: resolution: {integrity: sha512-cyV34oj3t5SE6slMyH0Y+o1E+y2hKsxcCbNtoIpk9vwUV7vFZ1Fa3JD8y/aGZCB/np5KyupVdC6Yvi565cwsaw==, tarball: file:projects/arm-azurestack.tgz} name: '@rush-temp/arm-azurestack' @@ -19212,7 +19277,7 @@ packages: dev: false file:projects/keyvault-certificates.tgz: - resolution: {integrity: sha512-I2HoDbXKPMnWCzSLvBfSeRvhcEcjo5QbWjR69KuNMGEeNtuyi9ZIYdRhvDkh1jhmXF0pUFIO+gxW1fDLZNHL+w==, tarball: file:projects/keyvault-certificates.tgz} + resolution: {integrity: sha512-N3MzxkAtHFu1M6+2m0+9fYOpGu66U9JAjLwxrkMPgj/qtovuH2m8lFizg6B4k4mnWSo19Z0kl04vF7nNS9CR6g==, tarball: file:projects/keyvault-certificates.tgz} name: '@rush-temp/keyvault-certificates' version: 0.0.0 dependencies: @@ -20028,7 +20093,7 @@ packages: dev: false file:projects/openai.tgz: - resolution: {integrity: sha512-HPJq35LqAc0O4ZWamZunXj5BkVfVNdv2w1RdY2uw64qwsyHfDNFl2AQ9RSGn9HxJtZopAmf93tueLSiARnjQsg==, tarball: file:projects/openai.tgz} + resolution: {integrity: sha512-xYnrqVPQaBXxwvLxAX32bPmxIQyZCHNlUmtJoOMxe1ij2h7Mki4+y4OTBA7UVwgqfHWd2FzEClwuZGomo0LpwQ==, tarball: file:projects/openai.tgz} name: '@rush-temp/openai' version: 0.0.0 dependencies: diff --git a/rush.json b/rush.json index 8ade5068358e..678d7073a631 100644 --- a/rush.json +++ b/rush.json @@ -1,7 +1,7 @@ /** * This is the main configuration file for Rush. * For full documentation, please see https://rushjs.io - */ { + */{ "$schema": "https://developer.microsoft.com/json-schemas/rush/v5/rush.schema.json", /** * (Required) This specifies the version of the Rush engine to be used in this repo. @@ -2140,6 +2140,11 @@ "packageName": "@azure/arm-playwrighttesting", "projectFolder": "sdk/playwrighttesting/arm-playwrighttesting", "versionPolicyName": "management" + }, + { + "packageName": "@azure/arm-azureintegrationspaces", + "projectFolder": "sdk/azureintegrationspaces/arm-azureintegrationspaces", + "versionPolicyName": "management" } ] -} +} \ No newline at end of file diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/CHANGELOG.md b/sdk/azureintegrationspaces/arm-azureintegrationspaces/CHANGELOG.md new file mode 100644 index 000000000000..e7a586011880 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/CHANGELOG.md @@ -0,0 +1,5 @@ +# Release History + +## 1.0.0-beta.1 (2023-10-25) + +The package of @azure/arm-azureintegrationspaces 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/azureintegrationspaces/arm-azureintegrationspaces/LICENSE b/sdk/azureintegrationspaces/arm-azureintegrationspaces/LICENSE new file mode 100644 index 000000000000..3a1d9b6f24f7 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2023 Microsoft + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +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 +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. \ No newline at end of file diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/README.md b/sdk/azureintegrationspaces/arm-azureintegrationspaces/README.md new file mode 100644 index 000000000000..285e6ef2df7b --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/README.md @@ -0,0 +1,109 @@ +# Azure MicrosoftIntegrationSpaces client library for JavaScript + +This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure MicrosoftIntegrationSpaces client. + +The azure integration spaces resource provider. + +[Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/azureintegrationspaces/arm-azureintegrationspaces) | +[Package (NPM)](https://www.npmjs.com/package/@azure/arm-azureintegrationspaces) | +[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-azureintegrationspaces?view=azure-node-preview) | +[Samples](https://github.com/Azure-Samples/azure-samples-js-management) + +## Getting started + +### Currently supported environments + +- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule) +- Latest versions of Safari, Chrome, Edge and Firefox. + +See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details. + +### Prerequisites + +- An [Azure subscription][azure_sub]. + +### Install the `@azure/arm-azureintegrationspaces` package + +Install the Azure MicrosoftIntegrationSpaces client library for JavaScript with `npm`: + +```bash +npm install @azure/arm-azureintegrationspaces +``` + +### Create and authenticate a `MicrosoftIntegrationSpaces` + +To create a client object to access the Azure MicrosoftIntegrationSpaces API, you will need the `endpoint` of your Azure MicrosoftIntegrationSpaces resource and a `credential`. The Azure MicrosoftIntegrationSpaces client can use Azure Active Directory credentials to authenticate. +You can find the endpoint for your Azure MicrosoftIntegrationSpaces resource in the [Azure Portal][azure_portal]. + +You can authenticate with Azure Active Directory using a credential from the [@azure/identity][azure_identity] library or [an existing AAD Token](https://github.com/Azure/azure-sdk-for-js/blob/master/sdk/identity/identity/samples/AzureIdentityExamples.md#authenticating-with-a-pre-fetched-access-token). + +To use the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with the Azure SDK, please install the `@azure/identity` package: + +```bash +npm install @azure/identity +``` + +You will also need to **register a new AAD application and grant access to Azure MicrosoftIntegrationSpaces** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions). +Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`. + +For more information about how to create an Azure AD Application check out [this guide](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal). + +```javascript +const { MicrosoftIntegrationSpaces } = require("@azure/arm-azureintegrationspaces"); +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 MicrosoftIntegrationSpaces(new DefaultAzureCredential(), subscriptionId); + +// For client-side applications running in the browser, use this code instead: +// const credential = new InteractiveBrowserCredential({ +// tenantId: "", +// clientId: "" +// }); +// const client = new MicrosoftIntegrationSpaces(credential, subscriptionId); +``` + + +### JavaScript Bundle +To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling). + +## Key concepts + +### MicrosoftIntegrationSpaces + +`MicrosoftIntegrationSpaces` is the primary interface for developers using the Azure MicrosoftIntegrationSpaces client library. Explore the methods on this client object to understand the different features of the Azure MicrosoftIntegrationSpaces service that you can access. + +## Troubleshooting + +### Logging + +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`: + +```javascript +const { setLogLevel } = require("@azure/logger"); +setLogLevel("info"); +``` + +For more detailed instructions on how to enable logs, you can look at the [@azure/logger package docs](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/logger). + +## Next steps + +Please take a look at the [samples](https://github.com/Azure-Samples/azure-samples-js-management) directory for detailed examples on how to use this library. + +## Contributing + +If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/main/CONTRIBUTING.md) to learn more about how to build and test the code. + +## Related projects + +- [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%2Fazureintegrationspaces%2Farm-azureintegrationspaces%2FREADME.png) + +[azure_cli]: https://docs.microsoft.com/cli/azure +[azure_sub]: https://azure.microsoft.com/free/ +[azure_sub]: https://azure.microsoft.com/free/ +[azure_portal]: https://portal.azure.com +[azure_identity]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity +[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity#defaultazurecredential diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/_meta.json b/sdk/azureintegrationspaces/arm-azureintegrationspaces/_meta.json new file mode 100644 index 000000000000..2317b05bdc0a --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/_meta.json @@ -0,0 +1,8 @@ +{ + "commit": "4ac46278dcc019a30ccf913d5274249d76cecdfa", + "readme": "specification/azureintegrationspaces/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=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/azureintegrationspaces/resource-manager/readme.md --use=@autorest/typescript@^6.0.11", + "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.2", + "use": "@autorest/typescript@^6.0.11" +} \ No newline at end of file diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/api-extractor.json b/sdk/azureintegrationspaces/arm-azureintegrationspaces/api-extractor.json new file mode 100644 index 000000000000..52d501f5d4a5 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/api-extractor.json @@ -0,0 +1,31 @@ +{ + "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", + "mainEntryPointFilePath": "./dist-esm/src/index.d.ts", + "docModel": { + "enabled": true + }, + "apiReport": { + "enabled": true, + "reportFolder": "./review" + }, + "dtsRollup": { + "enabled": true, + "untrimmedFilePath": "", + "publicTrimmedFilePath": "./types/arm-azureintegrationspaces.d.ts" + }, + "messages": { + "tsdocMessageReporting": { + "default": { + "logLevel": "none" + } + }, + "extractorMessageReporting": { + "ae-missing-release-tag": { + "logLevel": "none" + }, + "ae-unresolved-link": { + "logLevel": "none" + } + } + } +} \ No newline at end of file diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/package.json b/sdk/azureintegrationspaces/arm-azureintegrationspaces/package.json new file mode 100644 index 000000000000..75e75e1df584 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/package.json @@ -0,0 +1,116 @@ +{ + "name": "@azure/arm-azureintegrationspaces", + "sdk-type": "mgmt", + "author": "Microsoft Corporation", + "description": "A generated SDK for MicrosoftIntegrationSpaces.", + "version": "1.0.0-beta.1", + "engines": { + "node": ">=16.0.0" + }, + "dependencies": { + "@azure/core-paging": "^1.2.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.3.0", + "@azure/core-rest-pipeline": "^1.12.0", + "tslib": "^2.2.0" + }, + "keywords": [ + "node", + "azure", + "typescript", + "browser", + "isomorphic" + ], + "license": "MIT", + "main": "./dist/index.js", + "module": "./dist-esm/src/index.js", + "types": "./types/arm-azureintegrationspaces.d.ts", + "devDependencies": { + "@microsoft/api-extractor": "^7.31.1", + "@rollup/plugin-commonjs": "^24.0.0", + "@rollup/plugin-json": "^6.0.0", + "@rollup/plugin-multi-entry": "^6.0.0", + "@rollup/plugin-node-resolve": "^13.1.3", + "mkdirp": "^2.1.2", + "rollup": "^2.66.1", + "rollup-plugin-sourcemaps": "^0.6.3", + "typescript": "~5.0.0", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", + "@azure/identity": "^3.3.0", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.0.0", + "mocha": "^10.0.0", + "@types/mocha": "^10.0.0", + "esm": "^3.2.18", + "@types/chai": "^4.2.8", + "chai": "^4.2.0", + "cross-env": "^7.0.2", + "@types/node": "^16.0.0", + "ts-node": "^10.0.0", + "@azure/dev-tool": "^1.0.0" + }, + "repository": { + "type": "git", + "url": "https://github.com/Azure/azure-sdk-for-js.git" + }, + "bugs": { + "url": "https://github.com/Azure/azure-sdk-for-js/issues" + }, + "files": [ + "dist/**/*.js", + "dist/**/*.js.map", + "dist/**/*.d.ts", + "dist/**/*.d.ts.map", + "dist-esm/**/*.js", + "dist-esm/**/*.js.map", + "dist-esm/**/*.d.ts", + "dist-esm/**/*.d.ts.map", + "src/**/*.ts", + "README.md", + "LICENSE", + "rollup.config.js", + "tsconfig.json", + "review/*", + "CHANGELOG.md", + "types/*" + ], + "scripts": { + "build": "npm run clean && tsc && rollup -c 2>&1 && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "api-extractor run --local", + "lint": "echo skipped", + "audit": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", + "build:node": "echo skipped", + "build:browser": "echo skipped", + "build:test": "echo skipped", + "build:samples": "echo skipped.", + "check-format": "echo skipped", + "execute:samples": "echo skipped", + "format": "echo skipped", + "test": "npm run integration-test", + "test:node": "echo skipped", + "test:browser": "echo skipped", + "unit-test": "npm run unit-test:node && npm run unit-test:browser", + "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": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" + }, + "sideEffects": false, + "//metadata": { + "constantPaths": [ + { + "path": "src/microsoftIntegrationSpaces.ts", + "prefix": "packageDetails" + } + ] + }, + "autoPublish": true, + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/azureintegrationspaces/arm-azureintegrationspaces" +} \ No newline at end of file diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/review/arm-azureintegrationspaces.api.md b/sdk/azureintegrationspaces/arm-azureintegrationspaces/review/arm-azureintegrationspaces.api.md new file mode 100644 index 000000000000..cb790e74d8aa --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/review/arm-azureintegrationspaces.api.md @@ -0,0 +1,794 @@ +## API Report File for "@azure/arm-azureintegrationspaces" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts + +import * as coreAuth from '@azure/core-auth'; +import * as coreClient from '@azure/core-client'; +import { PagedAsyncIterableIterator } from '@azure/core-paging'; + +// @public +export type ActionType = string; + +// @public +export interface Application extends TrackedResource { + description?: string; + readonly provisioningState?: ProvisioningState; + trackingDataStores?: { + [propertyName: string]: TrackingDataStore; + }; +} + +// @public +export interface ApplicationListResult { + nextLink?: string; + value: Application[]; +} + +// @public +export interface ApplicationResource extends ProxyResource { + readonly provisioningState?: ProvisioningState; + resourceId?: string; + resourceKind?: string; + resourceType?: string; +} + +// @public +export interface ApplicationResourceListResult { + nextLink?: string; + value: ApplicationResource[]; +} + +// @public +export interface ApplicationResources { + createOrUpdate(resourceGroupName: string, spaceName: string, applicationName: string, resourceName: string, resource: ApplicationResource, options?: ApplicationResourcesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, spaceName: string, applicationName: string, resourceName: string, options?: ApplicationResourcesDeleteOptionalParams): Promise; + get(resourceGroupName: string, spaceName: string, applicationName: string, resourceName: string, options?: ApplicationResourcesGetOptionalParams): Promise; + listByApplication(resourceGroupName: string, spaceName: string, applicationName: string, options?: ApplicationResourcesListByApplicationOptionalParams): PagedAsyncIterableIterator; + patch(resourceGroupName: string, spaceName: string, applicationName: string, resourceName: string, properties: ApplicationResourceUpdate, options?: ApplicationResourcesPatchOptionalParams): Promise; +} + +// @public +export interface ApplicationResourcesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationResourcesCreateOrUpdateResponse = ApplicationResource; + +// @public +export interface ApplicationResourcesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ApplicationResourcesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationResourcesGetResponse = ApplicationResource; + +// @public +export interface ApplicationResourcesListByApplicationNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationResourcesListByApplicationNextResponse = ApplicationResourceListResult; + +// @public +export interface ApplicationResourcesListByApplicationOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type ApplicationResourcesListByApplicationResponse = ApplicationResourceListResult; + +// @public +export interface ApplicationResourcesPatchOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationResourcesPatchResponse = ApplicationResource; + +// @public +export interface ApplicationResourceUpdate { + resourceId?: string; + resourceKind?: string; + resourceType?: string; +} + +// @public +export interface Applications { + createOrUpdate(resourceGroupName: string, spaceName: string, applicationName: string, resource: Application, options?: ApplicationsCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, spaceName: string, applicationName: string, options?: ApplicationsDeleteOptionalParams): Promise; + deleteBusinessProcessDevelopmentArtifact(resourceGroupName: string, spaceName: string, applicationName: string, body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, options?: ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams): Promise; + get(resourceGroupName: string, spaceName: string, applicationName: string, options?: ApplicationsGetOptionalParams): Promise; + getBusinessProcessDevelopmentArtifact(resourceGroupName: string, spaceName: string, applicationName: string, body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, options?: ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams): Promise; + listBusinessProcessDevelopmentArtifacts(resourceGroupName: string, spaceName: string, applicationName: string, options?: ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams): Promise; + listBySpace(resourceGroupName: string, spaceName: string, options?: ApplicationsListBySpaceOptionalParams): PagedAsyncIterableIterator; + patch(resourceGroupName: string, spaceName: string, applicationName: string, properties: ApplicationUpdate, options?: ApplicationsPatchOptionalParams): Promise; + saveBusinessProcessDevelopmentArtifact(resourceGroupName: string, spaceName: string, applicationName: string, body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, options?: ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams): Promise; + validateBusinessProcessDevelopmentArtifact(resourceGroupName: string, spaceName: string, applicationName: string, body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, options?: ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams): Promise; +} + +// @public +export interface ApplicationsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsCreateOrUpdateResponse = Application; + +// @public +export interface ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ApplicationsDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsGetBusinessProcessDevelopmentArtifactResponse = SaveOrGetBusinessProcessDevelopmentArtifactResponse; + +// @public +export interface ApplicationsGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsGetResponse = Application; + +// @public +export interface ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsListBusinessProcessDevelopmentArtifactsResponse = ListBusinessProcessDevelopmentArtifactsResponse; + +// @public +export interface ApplicationsListBySpaceNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsListBySpaceNextResponse = ApplicationListResult; + +// @public +export interface ApplicationsListBySpaceOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type ApplicationsListBySpaceResponse = ApplicationListResult; + +// @public +export interface ApplicationsPatchOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsPatchResponse = Application; + +// @public +export interface ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ApplicationsSaveBusinessProcessDevelopmentArtifactResponse = SaveOrGetBusinessProcessDevelopmentArtifactResponse; + +// @public +export interface ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface ApplicationUpdate { + description?: string; + tags?: { + [propertyName: string]: string; + }; + trackingDataStores?: { + [propertyName: string]: TrackingDataStore; + }; +} + +// @public +export interface BusinessProcess extends ProxyResource { + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; + businessProcessStages?: { + [propertyName: string]: BusinessProcessStage; + }; + description?: string; + identifier?: BusinessProcessIdentifier; + readonly provisioningState?: ProvisioningState; + tableName?: string; + trackingDataStoreReferenceName?: string; + readonly version?: string; +} + +// @public +export interface BusinessProcessDevelopmentArtifactProperties { + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; + businessProcessStages?: { + [propertyName: string]: BusinessProcessStage; + }; + description?: string; + identifier?: BusinessProcessIdentifier; + trackingProfiles?: { + [propertyName: string]: TrackingProfileDefinition; + }; +} + +// @public +export interface BusinessProcesses { + createOrUpdate(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, resource: BusinessProcess, options?: BusinessProcessesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, options?: BusinessProcessesDeleteOptionalParams): Promise; + get(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, options?: BusinessProcessesGetOptionalParams): Promise; + listByApplication(resourceGroupName: string, spaceName: string, applicationName: string, options?: BusinessProcessesListByApplicationOptionalParams): PagedAsyncIterableIterator; + patch(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, properties: BusinessProcessUpdate, options?: BusinessProcessesPatchOptionalParams): Promise; +} + +// @public +export interface BusinessProcessesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessesCreateOrUpdateResponse = BusinessProcess; + +// @public +export interface BusinessProcessesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface BusinessProcessesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessesGetResponse = BusinessProcess; + +// @public +export interface BusinessProcessesListByApplicationNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessesListByApplicationNextResponse = BusinessProcessListResult; + +// @public +export interface BusinessProcessesListByApplicationOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type BusinessProcessesListByApplicationResponse = BusinessProcessListResult; + +// @public +export interface BusinessProcessesPatchOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessesPatchResponse = BusinessProcess; + +// @public +export interface BusinessProcessIdentifier { + propertyName?: string; + propertyType?: string; +} + +// @public +export interface BusinessProcessListResult { + nextLink?: string; + value: BusinessProcess[]; +} + +// @public +export interface BusinessProcessMappingItem { + logicAppResourceId?: string; + operationName?: string; + operationType?: string; + workflowName?: string; +} + +// @public +export interface BusinessProcessReference { + name?: string; + version?: string; +} + +// @public +export interface BusinessProcessStage { + description?: string; + properties?: { + [propertyName: string]: string; + }; + stagesBefore?: string[]; +} + +// @public +export interface BusinessProcessUpdate { + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; + businessProcessStages?: { + [propertyName: string]: BusinessProcessStage; + }; + description?: string; + identifier?: BusinessProcessIdentifier; + tableName?: string; + trackingDataStoreReferenceName?: string; +} + +// @public +export interface BusinessProcessVersion extends ProxyResource { + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; + businessProcessStages?: { + [propertyName: string]: BusinessProcessStage; + }; + description?: string; + identifier?: BusinessProcessIdentifier; + readonly provisioningState?: ProvisioningState; + tableName?: string; + trackingDataStoreReferenceName?: string; + readonly version?: string; +} + +// @public +export interface BusinessProcessVersionListResult { + nextLink?: string; + value: BusinessProcessVersion[]; +} + +// @public +export interface BusinessProcessVersions { + get(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, businessProcessVersion: string, options?: BusinessProcessVersionsGetOptionalParams): Promise; + listByBusinessProcess(resourceGroupName: string, spaceName: string, applicationName: string, businessProcessName: string, options?: BusinessProcessVersionsListByBusinessProcessOptionalParams): PagedAsyncIterableIterator; +} + +// @public +export interface BusinessProcessVersionsGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessVersionsGetResponse = BusinessProcessVersion; + +// @public +export interface BusinessProcessVersionsListByBusinessProcessNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type BusinessProcessVersionsListByBusinessProcessNextResponse = BusinessProcessVersionListResult; + +// @public +export interface BusinessProcessVersionsListByBusinessProcessOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type BusinessProcessVersionsListByBusinessProcessResponse = BusinessProcessVersionListResult; + +// @public +export type CreatedByType = string; + +// @public +export interface ErrorAdditionalInfo { + readonly info?: Record; + readonly type?: string; +} + +// @public +export interface ErrorDetail { + readonly additionalInfo?: ErrorAdditionalInfo[]; + readonly code?: string; + readonly details?: ErrorDetail[]; + readonly message?: string; + readonly target?: string; +} + +// @public +export interface ErrorResponse { + error?: ErrorDetail; +} + +// @public +export interface FlowTrackingDefinition { + correlationContext?: TrackingCorrelationContext; + events?: { + [propertyName: string]: TrackingEventDefinition; + }; +} + +// @public +export function getContinuationToken(page: unknown): string | undefined; + +// @public +export interface GetOrDeleteBusinessProcessDevelopmentArtifactRequest { + name: string; +} + +// @public +export interface InfrastructureResource extends ProxyResource { + readonly provisioningState?: ProvisioningState; + resourceId?: string; + resourceType?: string; +} + +// @public +export interface InfrastructureResourceListResult { + nextLink?: string; + value: InfrastructureResource[]; +} + +// @public +export interface InfrastructureResources { + createOrUpdate(resourceGroupName: string, spaceName: string, infrastructureResourceName: string, resource: InfrastructureResource, options?: InfrastructureResourcesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, spaceName: string, infrastructureResourceName: string, options?: InfrastructureResourcesDeleteOptionalParams): Promise; + get(resourceGroupName: string, spaceName: string, infrastructureResourceName: string, options?: InfrastructureResourcesGetOptionalParams): Promise; + listBySpace(resourceGroupName: string, spaceName: string, options?: InfrastructureResourcesListBySpaceOptionalParams): PagedAsyncIterableIterator; + patch(resourceGroupName: string, spaceName: string, infrastructureResourceName: string, properties: InfrastructureResourceUpdate, options?: InfrastructureResourcesPatchOptionalParams): Promise; +} + +// @public +export interface InfrastructureResourcesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type InfrastructureResourcesCreateOrUpdateResponse = InfrastructureResource; + +// @public +export interface InfrastructureResourcesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface InfrastructureResourcesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type InfrastructureResourcesGetResponse = InfrastructureResource; + +// @public +export interface InfrastructureResourcesListBySpaceNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type InfrastructureResourcesListBySpaceNextResponse = InfrastructureResourceListResult; + +// @public +export interface InfrastructureResourcesListBySpaceOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type InfrastructureResourcesListBySpaceResponse = InfrastructureResourceListResult; + +// @public +export interface InfrastructureResourcesPatchOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type InfrastructureResourcesPatchResponse = InfrastructureResource; + +// @public +export interface InfrastructureResourceUpdate { + resourceId?: string; + resourceType?: string; +} + +// @public +export enum KnownActionType { + Internal = "Internal" +} + +// @public +export enum KnownCreatedByType { + Application = "Application", + Key = "Key", + ManagedIdentity = "ManagedIdentity", + User = "User" +} + +// @public +export enum KnownOrigin { + System = "system", + User = "user", + UserSystem = "user,system" +} + +// @public +export enum KnownProvisioningState { + Accepted = "Accepted", + Canceled = "Canceled", + Deleting = "Deleting", + Failed = "Failed", + Provisioning = "Provisioning", + Succeeded = "Succeeded", + Updating = "Updating" +} + +// @public +export interface ListBusinessProcessDevelopmentArtifactsResponse { + value: SaveOrGetBusinessProcessDevelopmentArtifactResponse[]; +} + +// @public (undocumented) +export class MicrosoftIntegrationSpaces extends coreClient.ServiceClient { + // (undocumented) + $host: string; + constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: MicrosoftIntegrationSpacesOptionalParams); + // (undocumented) + apiVersion: string; + // (undocumented) + applicationResources: ApplicationResources; + // (undocumented) + applications: Applications; + // (undocumented) + businessProcesses: BusinessProcesses; + // (undocumented) + businessProcessVersions: BusinessProcessVersions; + // (undocumented) + infrastructureResources: InfrastructureResources; + // (undocumented) + operations: Operations; + // (undocumented) + spaces: Spaces; + // (undocumented) + subscriptionId: string; +} + +// @public +export interface MicrosoftIntegrationSpacesOptionalParams extends coreClient.ServiceClientOptions { + $host?: string; + apiVersion?: string; + endpoint?: string; +} + +// @public +export interface Operation { + readonly actionType?: ActionType; + display?: OperationDisplay; + readonly isDataAction?: boolean; + readonly name?: string; + readonly origin?: Origin; +} + +// @public +export interface OperationDisplay { + readonly description?: string; + readonly operation?: string; + readonly provider?: string; + readonly resource?: string; +} + +// @public +export interface OperationListResult { + readonly nextLink?: string; + readonly value?: Operation[]; +} + +// @public +export interface Operations { + list(options?: OperationsListOptionalParams): PagedAsyncIterableIterator; +} + +// @public +export interface OperationsListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type OperationsListNextResponse = OperationListResult; + +// @public +export interface OperationsListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type OperationsListResponse = OperationListResult; + +// @public +export type Origin = string; + +// @public +export type ProvisioningState = string; + +// @public +export interface ProxyResource extends Resource { +} + +// @public +export interface Resource { + readonly id?: string; + readonly name?: string; + readonly systemData?: SystemData; + readonly type?: string; +} + +// @public +export interface SaveOrGetBusinessProcessDevelopmentArtifactResponse { + name: string; + properties?: BusinessProcessDevelopmentArtifactProperties; + readonly systemData?: SystemData; +} + +// @public +export interface SaveOrValidateBusinessProcessDevelopmentArtifactRequest { + name: string; + properties?: BusinessProcessDevelopmentArtifactProperties; +} + +// @public +export interface Space extends TrackedResource { + description?: string; + readonly provisioningState?: ProvisioningState; +} + +// @public +export interface SpaceListResult { + nextLink?: string; + value: Space[]; +} + +// @public +export interface Spaces { + createOrUpdate(resourceGroupName: string, spaceName: string, resource: Space, options?: SpacesCreateOrUpdateOptionalParams): Promise; + delete(resourceGroupName: string, spaceName: string, options?: SpacesDeleteOptionalParams): Promise; + get(resourceGroupName: string, spaceName: string, options?: SpacesGetOptionalParams): Promise; + listByResourceGroup(resourceGroupName: string, options?: SpacesListByResourceGroupOptionalParams): PagedAsyncIterableIterator; + listBySubscription(options?: SpacesListBySubscriptionOptionalParams): PagedAsyncIterableIterator; + patch(resourceGroupName: string, spaceName: string, properties: SpaceUpdate, options?: SpacesPatchOptionalParams): Promise; +} + +// @public +export interface SpacesCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesCreateOrUpdateResponse = Space; + +// @public +export interface SpacesDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface SpacesGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesGetResponse = Space; + +// @public +export interface SpacesListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesListByResourceGroupNextResponse = SpaceListResult; + +// @public +export interface SpacesListByResourceGroupOptionalParams extends coreClient.OperationOptions { + expand?: string[]; + filter?: string; + maxpagesize?: number; + orderby?: string[]; + select?: string[]; + skip?: number; + top?: number; +} + +// @public +export type SpacesListByResourceGroupResponse = SpaceListResult; + +// @public +export interface SpacesListBySubscriptionNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesListBySubscriptionNextResponse = SpaceListResult; + +// @public +export interface SpacesListBySubscriptionOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesListBySubscriptionResponse = SpaceListResult; + +// @public +export interface SpacesPatchOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SpacesPatchResponse = Space; + +// @public +export interface SpaceUpdate { + description?: string; + tags?: { + [propertyName: string]: string; + }; +} + +// @public +export interface SystemData { + createdAt?: Date; + createdBy?: string; + createdByType?: CreatedByType; + lastModifiedAt?: Date; + lastModifiedBy?: string; + lastModifiedByType?: CreatedByType; +} + +// @public +export interface TrackedResource extends Resource { + location: string; + tags?: { + [propertyName: string]: string; + }; +} + +// @public +export interface TrackingCorrelationContext { + operationName?: string; + operationType?: string; + propertyName?: string; + value?: string; +} + +// @public +export interface TrackingDataStore { + databaseName: string; + dataStoreIngestionUri: string; + dataStoreResourceId: string; + dataStoreUri: string; +} + +// @public +export interface TrackingEventDefinition { + operationName?: string; + operationType?: string; + properties?: { + [propertyName: string]: Record; + }; +} + +// @public +export interface TrackingProfileDefinition { + businessProcess?: BusinessProcessReference; + schema?: string; + trackingDefinitions?: { + [propertyName: string]: FlowTrackingDefinition; + }; +} + +// (No @packageDocumentation comment for this package) + +``` diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/rollup.config.js b/sdk/azureintegrationspaces/arm-azureintegrationspaces/rollup.config.js new file mode 100644 index 000000000000..3f89d7309da5 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/rollup.config.js @@ -0,0 +1,122 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import nodeResolve from "@rollup/plugin-node-resolve"; +import cjs from "@rollup/plugin-commonjs"; +import sourcemaps from "rollup-plugin-sourcemaps"; +import multiEntry from "@rollup/plugin-multi-entry"; +import json from "@rollup/plugin-json"; + +import nodeBuiltins from "builtin-modules"; + +// #region Warning Handler + +/** + * A function that can determine whether a rollup warning should be ignored. If + * the function returns `true`, then the warning will not be displayed. + */ + +function ignoreNiseSinonEval(warning) { + return ( + warning.code === "EVAL" && + warning.id && + (warning.id.includes("node_modules/nise") || + warning.id.includes("node_modules/sinon")) === true + ); +} + +function ignoreChaiCircularDependency(warning) { + return ( + warning.code === "CIRCULAR_DEPENDENCY" && + warning.importer && warning.importer.includes("node_modules/chai") === true + ); +} + +const warningInhibitors = [ignoreChaiCircularDependency, ignoreNiseSinonEval]; + +/** + * Construct a warning handler for the shared rollup configuration + * that ignores certain warnings that are not relevant to testing. + */ +function makeOnWarnForTesting() { + return (warning, warn) => { + // If every inhibitor returns false (i.e. no inhibitors), then show the warning + if (warningInhibitors.every((inhib) => !inhib(warning))) { + warn(warning); + } + }; +} + +// #endregion + +function makeBrowserTestConfig() { + const config = { + input: { + include: ["dist-esm/test/**/*.spec.js"], + exclude: ["dist-esm/test/**/node/**"] + }, + output: { + file: `dist-test/index.browser.js`, + format: "umd", + sourcemap: true + }, + preserveSymlinks: false, + plugins: [ + multiEntry({ exports: false }), + nodeResolve({ + mainFields: ["module", "browser"] + }), + cjs(), + json(), + sourcemaps() + //viz({ filename: "dist-test/browser-stats.html", sourcemap: true }) + ], + onwarn: makeOnWarnForTesting(), + // Disable tree-shaking of test code. In rollup-plugin-node-resolve@5.0.0, + // rollup started respecting the "sideEffects" field in package.json. Since + // our package.json sets "sideEffects=false", this also applies to test + // code, which causes all tests to be removed by tree-shaking. + treeshake: false + }; + + return config; +} + +const defaultConfigurationOptions = { + disableBrowserBundle: false +}; + +export function makeConfig(pkg, options) { + options = { + ...defaultConfigurationOptions, + ...(options || {}) + }; + + const baseConfig = { + // Use the package's module field if it has one + input: pkg["module"] || "dist-esm/src/index.js", + external: [ + ...nodeBuiltins, + ...Object.keys(pkg.dependencies), + ...Object.keys(pkg.devDependencies) + ], + output: { file: "dist/index.js", format: "cjs", sourcemap: true }, + preserveSymlinks: false, + plugins: [sourcemaps(), nodeResolve()] + }; + + const config = [baseConfig]; + + if (!options.disableBrowserBundle) { + config.push(makeBrowserTestConfig()); + } + + return config; +} + +export default makeConfig(require("./package.json")); diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/sample.env b/sdk/azureintegrationspaces/arm-azureintegrationspaces/sample.env new file mode 100644 index 000000000000..672847a3fea0 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/sample.env @@ -0,0 +1,4 @@ +# 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/azureintegrationspaces/arm-azureintegrationspaces/src/index.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/index.ts new file mode 100644 index 000000000000..04d2a6a9a5bc --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/index.ts @@ -0,0 +1,13 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +/// +export { getContinuationToken } from "./pagingHelper"; +export * from "./models"; +export { MicrosoftIntegrationSpaces } from "./microsoftIntegrationSpaces"; +export * from "./operationsInterfaces"; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/microsoftIntegrationSpaces.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/microsoftIntegrationSpaces.ts new file mode 100644 index 000000000000..101187a27dde --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/microsoftIntegrationSpaces.ts @@ -0,0 +1,168 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +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 { + OperationsImpl, + SpacesImpl, + ApplicationsImpl, + BusinessProcessesImpl, + BusinessProcessVersionsImpl, + ApplicationResourcesImpl, + InfrastructureResourcesImpl +} from "./operations"; +import { + Operations, + Spaces, + Applications, + BusinessProcesses, + BusinessProcessVersions, + ApplicationResources, + InfrastructureResources +} from "./operationsInterfaces"; +import { MicrosoftIntegrationSpacesOptionalParams } from "./models"; + +export class MicrosoftIntegrationSpaces extends coreClient.ServiceClient { + $host: string; + apiVersion: string; + subscriptionId: string; + + /** + * Initializes a new instance of the MicrosoftIntegrationSpaces class. + * @param credentials Subscription credentials which uniquely identify client subscription. + * @param subscriptionId The ID of the target subscription. + * @param options The parameter options + */ + constructor( + credentials: coreAuth.TokenCredential, + subscriptionId: string, + options?: MicrosoftIntegrationSpacesOptionalParams + ) { + if (credentials === undefined) { + throw new Error("'credentials' cannot be null"); + } + if (subscriptionId === undefined) { + throw new Error("'subscriptionId' cannot be null"); + } + + // Initializing default values for options + if (!options) { + options = {}; + } + const defaults: MicrosoftIntegrationSpacesOptionalParams = { + requestContentType: "application/json; charset=utf-8", + credential: credentials + }; + + const packageDetails = `azsdk-js-arm-azureintegrationspaces/1.0.0-beta.1`; + const userAgentPrefix = + options.userAgentOptions && options.userAgentOptions.userAgentPrefix + ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` + : `${packageDetails}`; + + const optionsWithDefaults = { + ...defaults, + ...options, + userAgentOptions: { + userAgentPrefix + }, + endpoint: + options.endpoint ?? options.baseUri ?? "https://management.azure.com" + }; + super(optionsWithDefaults); + + let bearerTokenAuthenticationPolicyFound: boolean = false; + if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( + (pipelinePolicy) => + pipelinePolicy.name === + coreRestPipeline.bearerTokenAuthenticationPolicyName + ); + } + if ( + !options || + !options.pipeline || + options.pipeline.getOrderedPolicies().length == 0 || + !bearerTokenAuthenticationPolicyFound + ) { + this.pipeline.removePolicy({ + name: coreRestPipeline.bearerTokenAuthenticationPolicyName + }); + this.pipeline.addPolicy( + coreRestPipeline.bearerTokenAuthenticationPolicy({ + credential: credentials, + scopes: + optionsWithDefaults.credentialScopes ?? + `${optionsWithDefaults.endpoint}/.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 || "2023-11-14-preview"; + this.operations = new OperationsImpl(this); + this.spaces = new SpacesImpl(this); + this.applications = new ApplicationsImpl(this); + this.businessProcesses = new BusinessProcessesImpl(this); + this.businessProcessVersions = new BusinessProcessVersionsImpl(this); + this.applicationResources = new ApplicationResourcesImpl(this); + this.infrastructureResources = new InfrastructureResourcesImpl(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); + } + + operations: Operations; + spaces: Spaces; + applications: Applications; + businessProcesses: BusinessProcesses; + businessProcessVersions: BusinessProcessVersions; + applicationResources: ApplicationResources; + infrastructureResources: InfrastructureResources; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/index.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/index.ts new file mode 100644 index 000000000000..69c371aa7bf6 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/index.ts @@ -0,0 +1,988 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import * as coreClient from "@azure/core-client"; + +/** A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. */ +export interface OperationListResult { + /** + * List of operations supported by the resource provider + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly value?: Operation[]; + /** + * URL to get the next set of operation list results (if there are any). + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Details of a REST API operation, returned from the Resource Provider Operations API */ +export interface Operation { + /** + * The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane operations. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly isDataAction?: boolean; + /** Localized display information for this particular operation. */ + display?: OperationDisplay; + /** + * The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly origin?: Origin; + /** + * Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly actionType?: ActionType; +} + +/** Localized display information for this particular operation. */ +export interface OperationDisplay { + /** + * The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft Compute". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provider?: string; + /** + * The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job Schedule Collections". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly resource?: string; + /** + * The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly operation?: string; + /** + * The short, localized friendly description of the operation; suitable for tool tips and detailed views. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly description?: string; +} + +/** Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.). */ +export interface ErrorResponse { + /** The error object. */ + error?: ErrorDetail; +} + +/** The error detail. */ +export interface ErrorDetail { + /** + * The error code. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly code?: string; + /** + * The error message. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message?: string; + /** + * The error target. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly target?: string; + /** + * The error details. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly details?: ErrorDetail[]; + /** + * The error additional info. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly additionalInfo?: ErrorAdditionalInfo[]; +} + +/** The resource management error additional info. */ +export interface ErrorAdditionalInfo { + /** + * The additional info type. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * The additional info. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly info?: Record; +} + +/** The response of a Space list operation. */ +export interface SpaceListResult { + /** The Space items on this page */ + value: Space[]; + /** The link to the next page of items */ + nextLink?: 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. + */ + readonly name?: string; + /** + * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * Azure Resource Manager metadata containing createdBy and modifiedBy information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; +} + +/** Metadata pertaining to creation and last modification of the resource. */ +export interface SystemData { + /** The identity that created the resource. */ + createdBy?: string; + /** The type of identity that created the resource. */ + createdByType?: CreatedByType; + /** The timestamp of resource creation (UTC). */ + createdAt?: Date; + /** The identity that last modified the resource. */ + lastModifiedBy?: string; + /** The type of identity that last modified the resource. */ + lastModifiedByType?: CreatedByType; + /** The timestamp of resource last modification (UTC) */ + lastModifiedAt?: Date; +} + +/** The type used for update operations of the Space. */ +export interface SpaceUpdate { + /** Resource tags. */ + tags?: { [propertyName: string]: string }; + /** The description of the resource. */ + description?: string; +} + +/** The response of a Application list operation. */ +export interface ApplicationListResult { + /** The Application items on this page */ + value: Application[]; + /** The link to the next page of items */ + nextLink?: string; +} + +/** The properties of tracking data store. */ +export interface TrackingDataStore { + /** The database name. */ + databaseName: string; + /** The data store resource id. */ + dataStoreResourceId: string; + /** The data store URI. */ + dataStoreUri: string; + /** The data store ingestion URI. */ + dataStoreIngestionUri: string; +} + +/** The type used for update operations of the Application. */ +export interface ApplicationUpdate { + /** Resource tags. */ + tags?: { [propertyName: string]: string }; + /** The description of the resource. */ + description?: string; + /** The tracking data stores. */ + trackingDataStores?: { [propertyName: string]: TrackingDataStore }; +} + +/** The response of a BusinessProcess list operation. */ +export interface BusinessProcessListResult { + /** The BusinessProcess items on this page */ + value: BusinessProcess[]; + /** The link to the next page of items */ + nextLink?: string; +} + +/** The properties of business process identifier. */ +export interface BusinessProcessIdentifier { + /** The property name of the business process identifier. */ + propertyName?: string; + /** The property type of the business process identifier. */ + propertyType?: string; +} + +/** The properties of business process stage. */ +export interface BusinessProcessStage { + /** The description of the business stage. */ + description?: string; + /** The properties within the properties of the business process stage. */ + properties?: { [propertyName: string]: string }; + /** The property to keep track of stages before current in the business process stage. */ + stagesBefore?: string[]; +} + +/** The properties of business process mapping. */ +export interface BusinessProcessMappingItem { + /** The logic app resource id. */ + logicAppResourceId?: string; + /** The workflow name within the logic app. */ + workflowName?: string; + /** The operation name. */ + operationName?: string; + /** The mapping item operation type of the business process. */ + operationType?: string; +} + +/** The type used for update operations of the BusinessProcess. */ +export interface BusinessProcessUpdate { + /** The description of the business process. */ + description?: string; + /** The table name of the business process. */ + tableName?: string; + /** The tracking data store reference name. */ + trackingDataStoreReferenceName?: string; + /** The business process identifier. */ + identifier?: BusinessProcessIdentifier; + /** The business process stages. */ + businessProcessStages?: { [propertyName: string]: BusinessProcessStage }; + /** The business process mapping. */ + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; +} + +/** The response of a BusinessProcessVersion list operation. */ +export interface BusinessProcessVersionListResult { + /** The BusinessProcessVersion items on this page */ + value: BusinessProcessVersion[]; + /** The link to the next page of items */ + nextLink?: string; +} + +/** The business process development artifact get or delete request. */ +export interface GetOrDeleteBusinessProcessDevelopmentArtifactRequest { + /** The name of the business process development artifact. */ + name: string; +} + +/** The business process development artifact save or get response. */ +export interface SaveOrGetBusinessProcessDevelopmentArtifactResponse { + /** The name of the business process development artifact. */ + name: string; + /** + * The system data of the business process development artifact. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; + /** The properties of the business process development artifact. */ + properties?: BusinessProcessDevelopmentArtifactProperties; +} + +/** The properties of business process development artifact. */ +export interface BusinessProcessDevelopmentArtifactProperties { + /** The description of the business process. */ + description?: string; + /** The business process identifier. */ + identifier?: BusinessProcessIdentifier; + /** The business process stages. */ + businessProcessStages?: { [propertyName: string]: BusinessProcessStage }; + /** The business process mapping. */ + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; + /** The tracking profile for the business process. */ + trackingProfiles?: { [propertyName: string]: TrackingProfileDefinition }; +} + +/** The tracking profile for the business process */ +export interface TrackingProfileDefinition { + /** The tracking definition schema uri. */ + schema?: string; + /** The business process reference. */ + businessProcess?: BusinessProcessReference; + /** The tracking definitions. */ + trackingDefinitions?: { [propertyName: string]: FlowTrackingDefinition }; +} + +/** The business process reference. */ +export interface BusinessProcessReference { + /** The business process name. */ + name?: string; + /** The business process version. */ + version?: string; +} + +/** The workflow tracking definition. */ +export interface FlowTrackingDefinition { + /** The tracking correlation context. */ + correlationContext?: TrackingCorrelationContext; + /** The tracking events. */ + events?: { [propertyName: string]: TrackingEventDefinition }; +} + +/** The tracking correlation context. */ +export interface TrackingCorrelationContext { + /** The operation type for correlation context. */ + operationType?: string; + /** The operation name for correlation context. */ + operationName?: string; + /** The name of the correlation property. */ + propertyName?: string; + /** The template expression for correlation context property value. */ + value?: string; +} + +/** The tracking event definition. */ +export interface TrackingEventDefinition { + /** The operation type. */ + operationType?: string; + /** The operation name. */ + operationName?: string; + /** The properties to be collected for event. */ + properties?: { [propertyName: string]: Record }; +} + +/** The business process development artifact get collection response. */ +export interface ListBusinessProcessDevelopmentArtifactsResponse { + /** The list of the business process development artifact. */ + value: SaveOrGetBusinessProcessDevelopmentArtifactResponse[]; +} + +/** The response of a ApplicationResource list operation. */ +export interface ApplicationResourceListResult { + /** The ApplicationResource items on this page */ + value: ApplicationResource[]; + /** The link to the next page of items */ + nextLink?: string; +} + +/** The type used for update operations of the ApplicationResource. */ +export interface ApplicationResourceUpdate { + /** The type of the application resource. */ + resourceType?: string; + /** The Arm id of the application resource. */ + resourceId?: string; + /** The kind of the application resource. */ + resourceKind?: string; +} + +/** The business process development artifact save or validate request. */ +export interface SaveOrValidateBusinessProcessDevelopmentArtifactRequest { + /** The name of the business process development artifact. */ + name: string; + /** The properties of the business process development artifact. */ + properties?: BusinessProcessDevelopmentArtifactProperties; +} + +/** The response of a InfrastructureResource list operation. */ +export interface InfrastructureResourceListResult { + /** The InfrastructureResource items on this page */ + value: InfrastructureResource[]; + /** The link to the next page of items */ + nextLink?: string; +} + +/** The type used for update operations of the InfrastructureResource. */ +export interface InfrastructureResourceUpdate { + /** The type of the infrastructure resource. */ + resourceType?: string; + /** The id of the infrastructure resource. */ + resourceId?: string; +} + +/** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */ +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 interface ProxyResource extends Resource {} + +/** An integration space. */ +export interface Space extends TrackedResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** The description of the resource. */ + description?: string; +} + +/** An integration application under space. */ +export interface Application extends TrackedResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** The description of the resource. */ + description?: string; + /** The tracking data stores. */ + trackingDataStores?: { [propertyName: string]: TrackingDataStore }; +} + +/** A business process under application. */ +export interface BusinessProcess extends ProxyResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** + * The version of the business process. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly version?: string; + /** The description of the business process. */ + description?: string; + /** The table name of the business process. */ + tableName?: string; + /** The tracking data store reference name. */ + trackingDataStoreReferenceName?: string; + /** The business process identifier. */ + identifier?: BusinessProcessIdentifier; + /** The business process stages. */ + businessProcessStages?: { [propertyName: string]: BusinessProcessStage }; + /** The business process mapping. */ + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; +} + +/** A business process version. */ +export interface BusinessProcessVersion extends ProxyResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** + * The version of the business process. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly version?: string; + /** The description of the business process. */ + description?: string; + /** The table name of the business process. */ + tableName?: string; + /** The tracking data store reference name. */ + trackingDataStoreReferenceName?: string; + /** The business process identifier. */ + identifier?: BusinessProcessIdentifier; + /** The business process stages. */ + businessProcessStages?: { [propertyName: string]: BusinessProcessStage }; + /** The business process mapping. */ + businessProcessMapping?: { + [propertyName: string]: BusinessProcessMappingItem; + }; +} + +/** A resource under application. */ +export interface ApplicationResource extends ProxyResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** The type of the application resource. */ + resourceType?: string; + /** The Arm id of the application resource. */ + resourceId?: string; + /** The kind of the application resource. */ + resourceKind?: string; +} + +/** An infrastructure resource under Space. */ +export interface InfrastructureResource extends ProxyResource { + /** + * The status of the last operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** The type of the infrastructure resource. */ + resourceType?: string; + /** The id of the infrastructure resource. */ + resourceId?: string; +} + +/** Known values of {@link Origin} that the service accepts. */ +export enum KnownOrigin { + /** User */ + User = "user", + /** System */ + System = "system", + /** UserSystem */ + UserSystem = "user,system" +} + +/** + * Defines values for Origin. \ + * {@link KnownOrigin} can be used interchangeably with Origin, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **user** \ + * **system** \ + * **user,system** + */ +export type Origin = string; + +/** Known values of {@link ActionType} that the service accepts. */ +export enum KnownActionType { + /** Internal */ + Internal = "Internal" +} + +/** + * Defines values for ActionType. \ + * {@link KnownActionType} can be used interchangeably with ActionType, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Internal** + */ +export type ActionType = string; + +/** Known values of {@link ProvisioningState} that the service accepts. */ +export enum KnownProvisioningState { + /** Resource has been created. */ + Succeeded = "Succeeded", + /** Resource creation failed. */ + Failed = "Failed", + /** Resource creation was canceled. */ + Canceled = "Canceled", + /** Provisioning */ + Provisioning = "Provisioning", + /** Updating */ + Updating = "Updating", + /** Deleting */ + Deleting = "Deleting", + /** Accepted */ + Accepted = "Accepted" +} + +/** + * Defines values for ProvisioningState. \ + * {@link KnownProvisioningState} can be used interchangeably with ProvisioningState, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Succeeded**: Resource has been created. \ + * **Failed**: Resource creation failed. \ + * **Canceled**: Resource creation was canceled. \ + * **Provisioning** \ + * **Updating** \ + * **Deleting** \ + * **Accepted** + */ +export type ProvisioningState = 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" +} + +/** + * 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; + +/** Optional parameters. */ +export interface OperationsListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type OperationsListResponse = OperationListResult; + +/** Optional parameters. */ +export interface OperationsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type OperationsListNextResponse = OperationListResult; + +/** Optional parameters. */ +export interface SpacesListBySubscriptionOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySubscription operation. */ +export type SpacesListBySubscriptionResponse = SpaceListResult; + +/** Optional parameters. */ +export interface SpacesListByResourceGroupOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listByResourceGroup operation. */ +export type SpacesListByResourceGroupResponse = SpaceListResult; + +/** Optional parameters. */ +export interface SpacesGetOptionalParams extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type SpacesGetResponse = Space; + +/** Optional parameters. */ +export interface SpacesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type SpacesCreateOrUpdateResponse = Space; + +/** Optional parameters. */ +export interface SpacesPatchOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the patch operation. */ +export type SpacesPatchResponse = Space; + +/** Optional parameters. */ +export interface SpacesDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface SpacesListBySubscriptionNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySubscriptionNext operation. */ +export type SpacesListBySubscriptionNextResponse = SpaceListResult; + +/** Optional parameters. */ +export interface SpacesListByResourceGroupNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByResourceGroupNext operation. */ +export type SpacesListByResourceGroupNextResponse = SpaceListResult; + +/** Optional parameters. */ +export interface ApplicationsListBySpaceOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listBySpace operation. */ +export type ApplicationsListBySpaceResponse = ApplicationListResult; + +/** Optional parameters. */ +export interface ApplicationsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type ApplicationsGetResponse = Application; + +/** Optional parameters. */ +export interface ApplicationsCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type ApplicationsCreateOrUpdateResponse = Application; + +/** Optional parameters. */ +export interface ApplicationsPatchOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the patch operation. */ +export type ApplicationsPatchResponse = Application; + +/** Optional parameters. */ +export interface ApplicationsDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBusinessProcessDevelopmentArtifact operation. */ +export type ApplicationsGetBusinessProcessDevelopmentArtifactResponse = SaveOrGetBusinessProcessDevelopmentArtifactResponse; + +/** Optional parameters. */ +export interface ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBusinessProcessDevelopmentArtifacts operation. */ +export type ApplicationsListBusinessProcessDevelopmentArtifactsResponse = ListBusinessProcessDevelopmentArtifactsResponse; + +/** Optional parameters. */ +export interface ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the saveBusinessProcessDevelopmentArtifact operation. */ +export type ApplicationsSaveBusinessProcessDevelopmentArtifactResponse = SaveOrGetBusinessProcessDevelopmentArtifactResponse; + +/** Optional parameters. */ +export interface ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface ApplicationsListBySpaceNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySpaceNext operation. */ +export type ApplicationsListBySpaceNextResponse = ApplicationListResult; + +/** Optional parameters. */ +export interface BusinessProcessesListByApplicationOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listByApplication operation. */ +export type BusinessProcessesListByApplicationResponse = BusinessProcessListResult; + +/** Optional parameters. */ +export interface BusinessProcessesGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type BusinessProcessesGetResponse = BusinessProcess; + +/** Optional parameters. */ +export interface BusinessProcessesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type BusinessProcessesCreateOrUpdateResponse = BusinessProcess; + +/** Optional parameters. */ +export interface BusinessProcessesPatchOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the patch operation. */ +export type BusinessProcessesPatchResponse = BusinessProcess; + +/** Optional parameters. */ +export interface BusinessProcessesDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface BusinessProcessesListByApplicationNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByApplicationNext operation. */ +export type BusinessProcessesListByApplicationNextResponse = BusinessProcessListResult; + +/** Optional parameters. */ +export interface BusinessProcessVersionsListByBusinessProcessOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listByBusinessProcess operation. */ +export type BusinessProcessVersionsListByBusinessProcessResponse = BusinessProcessVersionListResult; + +/** Optional parameters. */ +export interface BusinessProcessVersionsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type BusinessProcessVersionsGetResponse = BusinessProcessVersion; + +/** Optional parameters. */ +export interface BusinessProcessVersionsListByBusinessProcessNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByBusinessProcessNext operation. */ +export type BusinessProcessVersionsListByBusinessProcessNextResponse = BusinessProcessVersionListResult; + +/** Optional parameters. */ +export interface ApplicationResourcesListByApplicationOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listByApplication operation. */ +export type ApplicationResourcesListByApplicationResponse = ApplicationResourceListResult; + +/** Optional parameters. */ +export interface ApplicationResourcesGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type ApplicationResourcesGetResponse = ApplicationResource; + +/** Optional parameters. */ +export interface ApplicationResourcesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type ApplicationResourcesCreateOrUpdateResponse = ApplicationResource; + +/** Optional parameters. */ +export interface ApplicationResourcesPatchOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the patch operation. */ +export type ApplicationResourcesPatchResponse = ApplicationResource; + +/** Optional parameters. */ +export interface ApplicationResourcesDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface ApplicationResourcesListByApplicationNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByApplicationNext operation. */ +export type ApplicationResourcesListByApplicationNextResponse = ApplicationResourceListResult; + +/** Optional parameters. */ +export interface InfrastructureResourcesListBySpaceOptionalParams + extends coreClient.OperationOptions { + /** The number of result items to return. */ + top?: number; + /** The number of result items to skip. */ + skip?: number; + /** The maximum number of result items per page. */ + maxpagesize?: number; + /** Filter the result list using the given expression. */ + filter?: string; + /** Select the specified fields to be included in the response. */ + select?: string[]; + /** Expand the indicated resources into the response. */ + expand?: string[]; + /** Expressions that specify the order of returned results. */ + orderby?: string[]; +} + +/** Contains response data for the listBySpace operation. */ +export type InfrastructureResourcesListBySpaceResponse = InfrastructureResourceListResult; + +/** Optional parameters. */ +export interface InfrastructureResourcesGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type InfrastructureResourcesGetResponse = InfrastructureResource; + +/** Optional parameters. */ +export interface InfrastructureResourcesCreateOrUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdate operation. */ +export type InfrastructureResourcesCreateOrUpdateResponse = InfrastructureResource; + +/** Optional parameters. */ +export interface InfrastructureResourcesPatchOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the patch operation. */ +export type InfrastructureResourcesPatchResponse = InfrastructureResource; + +/** Optional parameters. */ +export interface InfrastructureResourcesDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface InfrastructureResourcesListBySpaceNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySpaceNext operation. */ +export type InfrastructureResourcesListBySpaceNextResponse = InfrastructureResourceListResult; + +/** Optional parameters. */ +export interface MicrosoftIntegrationSpacesOptionalParams + extends coreClient.ServiceClientOptions { + /** server parameter */ + $host?: string; + /** Api Version */ + apiVersion?: string; + /** Overrides client endpoint. */ + endpoint?: string; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/mappers.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/mappers.ts new file mode 100644 index 000000000000..b87cecbf4f26 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/mappers.ts @@ -0,0 +1,1305 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import * as coreClient from "@azure/core-client"; + +export const OperationListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OperationListResult", + modelProperties: { + value: { + serializedName: "value", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Operation" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + +export const Operation: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Operation", + modelProperties: { + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String" + } + }, + isDataAction: { + serializedName: "isDataAction", + readOnly: true, + type: { + name: "Boolean" + } + }, + display: { + serializedName: "display", + type: { + name: "Composite", + className: "OperationDisplay" + } + }, + origin: { + serializedName: "origin", + readOnly: true, + type: { + name: "String" + } + }, + actionType: { + serializedName: "actionType", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + +export const OperationDisplay: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "OperationDisplay", + modelProperties: { + provider: { + serializedName: "provider", + readOnly: true, + type: { + name: "String" + } + }, + resource: { + serializedName: "resource", + readOnly: true, + type: { + name: "String" + } + }, + operation: { + serializedName: "operation", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "description", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + +export const ErrorResponse: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ErrorResponse", + modelProperties: { + error: { + serializedName: "error", + type: { + name: "Composite", + className: "ErrorDetail" + } + } + } + } +}; + +export const ErrorDetail: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ErrorDetail", + modelProperties: { + code: { + serializedName: "code", + readOnly: true, + type: { + name: "String" + } + }, + message: { + serializedName: "message", + readOnly: true, + type: { + name: "String" + } + }, + target: { + serializedName: "target", + readOnly: true, + type: { + name: "String" + } + }, + details: { + serializedName: "details", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorDetail" + } + } + } + }, + additionalInfo: { + serializedName: "additionalInfo", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorAdditionalInfo" + } + } + } + } + } + } +}; + +export const ErrorAdditionalInfo: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ErrorAdditionalInfo", + modelProperties: { + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String" + } + }, + info: { + serializedName: "info", + readOnly: true, + type: { + name: "Dictionary", + value: { type: { name: "any" } } + } + } + } + } +}; + +export const SpaceListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SpaceListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Space" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const Resource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Resource", + modelProperties: { + id: { + serializedName: "id", + readOnly: true, + type: { + name: "String" + } + }, + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String" + } + }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String" + } + }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + } + } + } +}; + +export const SystemData: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String" + } + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String" + } + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime" + } + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String" + } + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String" + } + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime" + } + } + } + } +}; + +export const SpaceUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SpaceUpdate", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + } + } + } +}; + +export const ApplicationListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ApplicationListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Application" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const TrackingDataStore: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackingDataStore", + modelProperties: { + databaseName: { + serializedName: "databaseName", + required: true, + type: { + name: "String" + } + }, + dataStoreResourceId: { + serializedName: "dataStoreResourceId", + required: true, + type: { + name: "String" + } + }, + dataStoreUri: { + serializedName: "dataStoreUri", + required: true, + type: { + name: "String" + } + }, + dataStoreIngestionUri: { + serializedName: "dataStoreIngestionUri", + required: true, + type: { + name: "String" + } + } + } + } +}; + +export const ApplicationUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ApplicationUpdate", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + trackingDataStores: { + serializedName: "properties.trackingDataStores", + type: { + name: "Dictionary", + value: { type: { name: "Composite", className: "TrackingDataStore" } } + } + } + } + } +}; + +export const BusinessProcessListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "BusinessProcess" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const BusinessProcessIdentifier: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessIdentifier", + modelProperties: { + propertyName: { + serializedName: "propertyName", + type: { + name: "String" + } + }, + propertyType: { + serializedName: "propertyType", + type: { + name: "String" + } + } + } + } +}; + +export const BusinessProcessStage: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessStage", + modelProperties: { + description: { + serializedName: "description", + type: { + name: "String" + } + }, + properties: { + serializedName: "properties", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + }, + stagesBefore: { + serializedName: "stagesBefore", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const BusinessProcessMappingItem: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessMappingItem", + modelProperties: { + logicAppResourceId: { + serializedName: "logicAppResourceId", + type: { + name: "String" + } + }, + workflowName: { + serializedName: "workflowName", + type: { + name: "String" + } + }, + operationName: { + serializedName: "operationName", + type: { + name: "String" + } + }, + operationType: { + serializedName: "operationType", + type: { + name: "String" + } + } + } + } +}; + +export const BusinessProcessUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessUpdate", + modelProperties: { + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + tableName: { + serializedName: "properties.tableName", + type: { + name: "String" + } + }, + trackingDataStoreReferenceName: { + serializedName: "properties.trackingDataStoreReferenceName", + type: { + name: "String" + } + }, + identifier: { + serializedName: "properties.identifier", + type: { + name: "Composite", + className: "BusinessProcessIdentifier" + } + }, + businessProcessStages: { + serializedName: "properties.businessProcessStages", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessStage" } + } + } + }, + businessProcessMapping: { + serializedName: "properties.businessProcessMapping", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessMappingItem" } + } + } + } + } + } +}; + +export const BusinessProcessVersionListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessVersionListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "BusinessProcessVersion" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const GetOrDeleteBusinessProcessDevelopmentArtifactRequest: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "GetOrDeleteBusinessProcessDevelopmentArtifactRequest", + modelProperties: { + name: { + serializedName: "name", + required: true, + type: { + name: "String" + } + } + } + } +}; + +export const SaveOrGetBusinessProcessDevelopmentArtifactResponse: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SaveOrGetBusinessProcessDevelopmentArtifactResponse", + modelProperties: { + name: { + serializedName: "name", + required: true, + type: { + name: "String" + } + }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + }, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "BusinessProcessDevelopmentArtifactProperties" + } + } + } + } +}; + +export const BusinessProcessDevelopmentArtifactProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessDevelopmentArtifactProperties", + modelProperties: { + description: { + serializedName: "description", + type: { + name: "String" + } + }, + identifier: { + serializedName: "identifier", + type: { + name: "Composite", + className: "BusinessProcessIdentifier" + } + }, + businessProcessStages: { + serializedName: "businessProcessStages", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessStage" } + } + } + }, + businessProcessMapping: { + serializedName: "businessProcessMapping", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessMappingItem" } + } + } + }, + trackingProfiles: { + serializedName: "trackingProfiles", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "TrackingProfileDefinition" } + } + } + } + } + } +}; + +export const TrackingProfileDefinition: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackingProfileDefinition", + modelProperties: { + schema: { + serializedName: "$schema", + type: { + name: "String" + } + }, + businessProcess: { + serializedName: "businessProcess", + type: { + name: "Composite", + className: "BusinessProcessReference" + } + }, + trackingDefinitions: { + serializedName: "trackingDefinitions", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "FlowTrackingDefinition" } + } + } + } + } + } +}; + +export const BusinessProcessReference: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessReference", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + version: { + serializedName: "version", + type: { + name: "String" + } + } + } + } +}; + +export const FlowTrackingDefinition: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "FlowTrackingDefinition", + modelProperties: { + correlationContext: { + serializedName: "correlationContext", + type: { + name: "Composite", + className: "TrackingCorrelationContext" + } + }, + events: { + serializedName: "events", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "TrackingEventDefinition" } + } + } + } + } + } +}; + +export const TrackingCorrelationContext: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackingCorrelationContext", + modelProperties: { + operationType: { + serializedName: "operationType", + type: { + name: "String" + } + }, + operationName: { + serializedName: "operationName", + type: { + name: "String" + } + }, + propertyName: { + serializedName: "propertyName", + type: { + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "String" + } + } + } + } +}; + +export const TrackingEventDefinition: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackingEventDefinition", + modelProperties: { + operationType: { + serializedName: "operationType", + type: { + name: "String" + } + }, + operationName: { + serializedName: "operationName", + type: { + name: "String" + } + }, + properties: { + serializedName: "properties", + type: { + name: "Dictionary", + value: { + type: { name: "Dictionary", value: { type: { name: "any" } } } + } + } + } + } + } +}; + +export const ListBusinessProcessDevelopmentArtifactsResponse: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ListBusinessProcessDevelopmentArtifactsResponse", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SaveOrGetBusinessProcessDevelopmentArtifactResponse" + } + } + } + } + } + } +}; + +export const ApplicationResourceListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ApplicationResourceListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ApplicationResource" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const ApplicationResourceUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ApplicationResourceUpdate", + modelProperties: { + resourceType: { + serializedName: "properties.resourceType", + type: { + name: "String" + } + }, + resourceId: { + serializedName: "properties.resourceId", + type: { + name: "String" + } + }, + resourceKind: { + serializedName: "properties.resourceKind", + type: { + name: "String" + } + } + } + } +}; + +export const SaveOrValidateBusinessProcessDevelopmentArtifactRequest: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SaveOrValidateBusinessProcessDevelopmentArtifactRequest", + modelProperties: { + name: { + serializedName: "name", + required: true, + type: { + name: "String" + } + }, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "BusinessProcessDevelopmentArtifactProperties" + } + } + } + } +}; + +export const InfrastructureResourceListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "InfrastructureResourceListResult", + modelProperties: { + value: { + serializedName: "value", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "InfrastructureResource" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const InfrastructureResourceUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "InfrastructureResourceUpdate", + modelProperties: { + resourceType: { + serializedName: "properties.resourceType", + type: { + name: "String" + } + }, + resourceId: { + serializedName: "properties.resourceId", + type: { + name: "String" + } + } + } + } +}; + +export const TrackedResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackedResource", + modelProperties: { + ...Resource.type.modelProperties, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + }, + location: { + serializedName: "location", + required: true, + type: { + name: "String" + } + } + } + } +}; + +export const ProxyResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ProxyResource", + modelProperties: { + ...Resource.type.modelProperties + } + } +}; + +export const Space: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Space", + modelProperties: { + ...TrackedResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + } + } + } +}; + +export const Application: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Application", + modelProperties: { + ...TrackedResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + trackingDataStores: { + serializedName: "properties.trackingDataStores", + type: { + name: "Dictionary", + value: { type: { name: "Composite", className: "TrackingDataStore" } } + } + } + } + } +}; + +export const BusinessProcess: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcess", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + version: { + serializedName: "properties.version", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + tableName: { + serializedName: "properties.tableName", + type: { + name: "String" + } + }, + trackingDataStoreReferenceName: { + serializedName: "properties.trackingDataStoreReferenceName", + type: { + name: "String" + } + }, + identifier: { + serializedName: "properties.identifier", + type: { + name: "Composite", + className: "BusinessProcessIdentifier" + } + }, + businessProcessStages: { + serializedName: "properties.businessProcessStages", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessStage" } + } + } + }, + businessProcessMapping: { + serializedName: "properties.businessProcessMapping", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessMappingItem" } + } + } + } + } + } +}; + +export const BusinessProcessVersion: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "BusinessProcessVersion", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + version: { + serializedName: "properties.version", + readOnly: true, + type: { + name: "String" + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + tableName: { + serializedName: "properties.tableName", + type: { + name: "String" + } + }, + trackingDataStoreReferenceName: { + serializedName: "properties.trackingDataStoreReferenceName", + type: { + name: "String" + } + }, + identifier: { + serializedName: "properties.identifier", + type: { + name: "Composite", + className: "BusinessProcessIdentifier" + } + }, + businessProcessStages: { + serializedName: "properties.businessProcessStages", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessStage" } + } + } + }, + businessProcessMapping: { + serializedName: "properties.businessProcessMapping", + type: { + name: "Dictionary", + value: { + type: { name: "Composite", className: "BusinessProcessMappingItem" } + } + } + } + } + } +}; + +export const ApplicationResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ApplicationResource", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + resourceType: { + serializedName: "properties.resourceType", + type: { + name: "String" + } + }, + resourceId: { + serializedName: "properties.resourceId", + type: { + name: "String" + } + }, + resourceKind: { + serializedName: "properties.resourceKind", + type: { + name: "String" + } + } + } + } +}; + +export const InfrastructureResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "InfrastructureResource", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + resourceType: { + serializedName: "properties.resourceType", + type: { + name: "String" + } + }, + resourceId: { + serializedName: "properties.resourceId", + type: { + name: "String" + } + } + } + } +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/parameters.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/parameters.ts new file mode 100644 index 000000000000..68b3dafb8e95 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/models/parameters.ts @@ -0,0 +1,346 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + OperationParameter, + OperationURLParameter, + OperationQueryParameter +} from "@azure/core-client"; +import { + Space as SpaceMapper, + SpaceUpdate as SpaceUpdateMapper, + Application as ApplicationMapper, + ApplicationUpdate as ApplicationUpdateMapper, + GetOrDeleteBusinessProcessDevelopmentArtifactRequest as GetOrDeleteBusinessProcessDevelopmentArtifactRequestMapper, + SaveOrValidateBusinessProcessDevelopmentArtifactRequest as SaveOrValidateBusinessProcessDevelopmentArtifactRequestMapper, + BusinessProcess as BusinessProcessMapper, + BusinessProcessUpdate as BusinessProcessUpdateMapper, + ApplicationResource as ApplicationResourceMapper, + ApplicationResourceUpdate as ApplicationResourceUpdateMapper, + InfrastructureResource as InfrastructureResourceMapper, + InfrastructureResourceUpdate as InfrastructureResourceUpdateMapper +} from "../models/mappers"; + +export const accept: OperationParameter = { + parameterPath: "accept", + mapper: { + defaultValue: "application/json", + isConstant: true, + serializedName: "Accept", + type: { + name: "String" + } + } +}; + +export const $host: OperationURLParameter = { + parameterPath: "$host", + mapper: { + serializedName: "$host", + required: true, + type: { + name: "String" + } + }, + skipEncoding: true +}; + +export const apiVersion: OperationQueryParameter = { + parameterPath: "apiVersion", + mapper: { + defaultValue: "2023-11-14-preview", + isConstant: true, + serializedName: "api-version", + type: { + name: "String" + } + } +}; + +export const nextLink: OperationURLParameter = { + parameterPath: "nextLink", + mapper: { + serializedName: "nextLink", + required: true, + type: { + name: "String" + } + }, + skipEncoding: true +}; + +export const subscriptionId: OperationURLParameter = { + parameterPath: "subscriptionId", + mapper: { + constraints: { + MinLength: 1 + }, + serializedName: "subscriptionId", + required: true, + type: { + name: "String" + } + } +}; + +export const resourceGroupName: OperationURLParameter = { + parameterPath: "resourceGroupName", + mapper: { + constraints: { + MaxLength: 90, + MinLength: 1 + }, + serializedName: "resourceGroupName", + required: true, + type: { + name: "String" + } + } +}; + +export const top: OperationQueryParameter = { + parameterPath: ["options", "top"], + mapper: { + serializedName: "top", + type: { + name: "Number" + } + } +}; + +export const skip: OperationQueryParameter = { + parameterPath: ["options", "skip"], + mapper: { + defaultValue: 0, + serializedName: "skip", + type: { + name: "Number" + } + } +}; + +export const maxpagesize: OperationQueryParameter = { + parameterPath: ["options", "maxpagesize"], + mapper: { + serializedName: "maxpagesize", + type: { + name: "Number" + } + } +}; + +export const filter: OperationQueryParameter = { + parameterPath: ["options", "filter"], + mapper: { + serializedName: "filter", + type: { + name: "String" + } + } +}; + +export const select: OperationQueryParameter = { + parameterPath: ["options", "select"], + mapper: { + serializedName: "select", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: "Multi" +}; + +export const expand: OperationQueryParameter = { + parameterPath: ["options", "expand"], + mapper: { + serializedName: "expand", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: "Multi" +}; + +export const orderby: OperationQueryParameter = { + parameterPath: ["options", "orderby"], + mapper: { + serializedName: "orderby", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: "Multi" +}; + +export const spaceName: OperationURLParameter = { + parameterPath: "spaceName", + mapper: { + constraints: { + Pattern: new RegExp("[a-zA-Z0-9_.()-]{0,79}$") + }, + serializedName: "spaceName", + required: true, + type: { + name: "String" + } + } +}; + +export const contentType: OperationParameter = { + parameterPath: ["options", "contentType"], + mapper: { + defaultValue: "application/json", + isConstant: true, + serializedName: "Content-Type", + type: { + name: "String" + } + } +}; + +export const resource: OperationParameter = { + parameterPath: "resource", + mapper: SpaceMapper +}; + +export const properties: OperationParameter = { + parameterPath: "properties", + mapper: SpaceUpdateMapper +}; + +export const applicationName: OperationURLParameter = { + parameterPath: "applicationName", + mapper: { + constraints: { + Pattern: new RegExp("[a-zA-Z0-9_.()-]{0,79}$") + }, + serializedName: "applicationName", + required: true, + type: { + name: "String" + } + } +}; + +export const resource1: OperationParameter = { + parameterPath: "resource", + mapper: ApplicationMapper +}; + +export const properties1: OperationParameter = { + parameterPath: "properties", + mapper: ApplicationUpdateMapper +}; + +export const body: OperationParameter = { + parameterPath: "body", + mapper: GetOrDeleteBusinessProcessDevelopmentArtifactRequestMapper +}; + +export const body1: OperationParameter = { + parameterPath: "body", + mapper: SaveOrValidateBusinessProcessDevelopmentArtifactRequestMapper +}; + +export const businessProcessName: OperationURLParameter = { + parameterPath: "businessProcessName", + mapper: { + constraints: { + Pattern: new RegExp("[a-zA-Z0-9_.()-]{0,79}$") + }, + serializedName: "businessProcessName", + required: true, + type: { + name: "String" + } + } +}; + +export const resource2: OperationParameter = { + parameterPath: "resource", + mapper: BusinessProcessMapper +}; + +export const properties2: OperationParameter = { + parameterPath: "properties", + mapper: BusinessProcessUpdateMapper +}; + +export const businessProcessVersion: OperationURLParameter = { + parameterPath: "businessProcessVersion", + mapper: { + serializedName: "businessProcessVersion", + required: true, + type: { + name: "String" + } + } +}; + +export const resourceName: OperationURLParameter = { + parameterPath: "resourceName", + mapper: { + constraints: { + Pattern: new RegExp("[a-zA-Z0-9_.()-]{0,79}$") + }, + serializedName: "resourceName", + required: true, + type: { + name: "String" + } + } +}; + +export const resource3: OperationParameter = { + parameterPath: "resource", + mapper: ApplicationResourceMapper +}; + +export const properties3: OperationParameter = { + parameterPath: "properties", + mapper: ApplicationResourceUpdateMapper +}; + +export const infrastructureResourceName: OperationURLParameter = { + parameterPath: "infrastructureResourceName", + mapper: { + constraints: { + Pattern: new RegExp("[a-zA-Z0-9_.()-]{0,79}$") + }, + serializedName: "infrastructureResourceName", + required: true, + type: { + name: "String" + } + } +}; + +export const resource4: OperationParameter = { + parameterPath: "resource", + mapper: InfrastructureResourceMapper +}; + +export const properties4: OperationParameter = { + parameterPath: "properties", + mapper: InfrastructureResourceUpdateMapper +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applicationResources.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applicationResources.ts new file mode 100644 index 000000000000..ac601f0ff9d3 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applicationResources.ts @@ -0,0 +1,438 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { ApplicationResources } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + ApplicationResource, + ApplicationResourcesListByApplicationNextOptionalParams, + ApplicationResourcesListByApplicationOptionalParams, + ApplicationResourcesListByApplicationResponse, + ApplicationResourcesGetOptionalParams, + ApplicationResourcesGetResponse, + ApplicationResourcesCreateOrUpdateOptionalParams, + ApplicationResourcesCreateOrUpdateResponse, + ApplicationResourceUpdate, + ApplicationResourcesPatchOptionalParams, + ApplicationResourcesPatchResponse, + ApplicationResourcesDeleteOptionalParams, + ApplicationResourcesListByApplicationNextResponse +} from "../models"; + +/// +/** Class containing ApplicationResources operations. */ +export class ApplicationResourcesImpl implements ApplicationResources { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class ApplicationResources class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List ApplicationResource resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + public listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationResourcesListByApplicationOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listByApplicationPagingAll( + resourceGroupName, + spaceName, + applicationName, + 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.listByApplicationPagingPage( + resourceGroupName, + spaceName, + applicationName, + options, + settings + ); + } + }; + } + + private async *listByApplicationPagingPage( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationResourcesListByApplicationOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: ApplicationResourcesListByApplicationResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByApplication( + resourceGroupName, + spaceName, + applicationName, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByApplicationNext( + resourceGroupName, + spaceName, + applicationName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByApplicationPagingAll( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationResourcesListByApplicationOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listByApplicationPagingPage( + resourceGroupName, + spaceName, + applicationName, + options + )) { + yield* page; + } + } + + /** + * List ApplicationResource resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + private _listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationResourcesListByApplicationOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, options }, + listByApplicationOperationSpec + ); + } + + /** + * Get a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + options?: ApplicationResourcesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, resourceName, options }, + getOperationSpec + ); + } + + /** + * Create a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + resource: ApplicationResource, + options?: ApplicationResourcesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + resourceName, + resource, + options + }, + createOrUpdateOperationSpec + ); + } + + /** + * Update a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + properties: ApplicationResourceUpdate, + options?: ApplicationResourcesPatchOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + resourceName, + properties, + options + }, + patchOperationSpec + ); + } + + /** + * Delete a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + options?: ApplicationResourcesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, resourceName, options }, + deleteOperationSpec + ); + } + + /** + * ListByApplicationNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param nextLink The nextLink from the previous successful call to the ListByApplication method. + * @param options The options parameters. + */ + private _listByApplicationNext( + resourceGroupName: string, + spaceName: string, + applicationName: string, + nextLink: string, + options?: ApplicationResourcesListByApplicationNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, nextLink, options }, + listByApplicationNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listByApplicationOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/resources", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ApplicationResourceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/resources/{resourceName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ApplicationResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/resources/{resourceName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.ApplicationResource + }, + 201: { + bodyMapper: Mappers.ApplicationResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.resource3, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const patchOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/resources/{resourceName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.ApplicationResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.properties3, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/resources/{resourceName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listByApplicationNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ApplicationResourceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applications.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applications.ts new file mode 100644 index 000000000000..2a89a8049928 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/applications.ts @@ -0,0 +1,625 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { Applications } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + Application, + ApplicationsListBySpaceNextOptionalParams, + ApplicationsListBySpaceOptionalParams, + ApplicationsListBySpaceResponse, + ApplicationsGetOptionalParams, + ApplicationsGetResponse, + ApplicationsCreateOrUpdateOptionalParams, + ApplicationsCreateOrUpdateResponse, + ApplicationUpdate, + ApplicationsPatchOptionalParams, + ApplicationsPatchResponse, + ApplicationsDeleteOptionalParams, + GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsGetBusinessProcessDevelopmentArtifactResponse, + ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams, + ApplicationsListBusinessProcessDevelopmentArtifactsResponse, + SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsSaveBusinessProcessDevelopmentArtifactResponse, + ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsListBySpaceNextResponse +} from "../models"; + +/// +/** Class containing Applications operations. */ +export class ApplicationsImpl implements Applications { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class Applications class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List Application resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + public listBySpace( + resourceGroupName: string, + spaceName: string, + options?: ApplicationsListBySpaceOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listBySpacePagingAll( + resourceGroupName, + spaceName, + 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.listBySpacePagingPage( + resourceGroupName, + spaceName, + options, + settings + ); + } + }; + } + + private async *listBySpacePagingPage( + resourceGroupName: string, + spaceName: string, + options?: ApplicationsListBySpaceOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: ApplicationsListBySpaceResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBySpace(resourceGroupName, spaceName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBySpaceNext( + resourceGroupName, + spaceName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBySpacePagingAll( + resourceGroupName: string, + spaceName: string, + options?: ApplicationsListBySpaceOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listBySpacePagingPage( + resourceGroupName, + spaceName, + options + )) { + yield* page; + } + } + + /** + * List Application resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + private _listBySpace( + resourceGroupName: string, + spaceName: string, + options?: ApplicationsListBySpaceOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, options }, + listBySpaceOperationSpec + ); + } + + /** + * Get a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, options }, + getOperationSpec + ); + } + + /** + * Create a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resource: Application, + options?: ApplicationsCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, resource, options }, + createOrUpdateOperationSpec + ); + } + + /** + * Update a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + properties: ApplicationUpdate, + options?: ApplicationsPatchOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, properties, options }, + patchOperationSpec + ); + } + + /** + * Delete a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, options }, + deleteOperationSpec + ); + } + + /** + * The delete business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + deleteBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, body, options }, + deleteBusinessProcessDevelopmentArtifactOperationSpec + ); + } + + /** + * The get business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + getBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, body, options }, + getBusinessProcessDevelopmentArtifactOperationSpec + ); + } + + /** + * The list business process development artifacts action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + listBusinessProcessDevelopmentArtifacts( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, options }, + listBusinessProcessDevelopmentArtifactsOperationSpec + ); + } + + /** + * The save business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + saveBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, body, options }, + saveBusinessProcessDevelopmentArtifactOperationSpec + ); + } + + /** + * The validate business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + validateBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, body, options }, + validateBusinessProcessDevelopmentArtifactOperationSpec + ); + } + + /** + * ListBySpaceNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param nextLink The nextLink from the previous successful call to the ListBySpace method. + * @param options The options parameters. + */ + private _listBySpaceNext( + resourceGroupName: string, + spaceName: string, + nextLink: string, + options?: ApplicationsListBySpaceNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, nextLink, options }, + listBySpaceNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listBySpaceOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ApplicationListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Application + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Application + }, + 201: { + bodyMapper: Mappers.Application + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.resource1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const patchOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.Application + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.properties1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; +const deleteBusinessProcessDevelopmentArtifactOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/deleteBusinessProcessDevelopmentArtifact", + httpMethod: "POST", + responses: { + 200: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.body, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const getBusinessProcessDevelopmentArtifactOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/getBusinessProcessDevelopmentArtifact", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.SaveOrGetBusinessProcessDevelopmentArtifactResponse + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.body, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listBusinessProcessDevelopmentArtifactsOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/listBusinessProcessDevelopmentArtifacts", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.ListBusinessProcessDevelopmentArtifactsResponse + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; +const saveBusinessProcessDevelopmentArtifactOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/saveBusinessProcessDevelopmentArtifact", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.SaveOrGetBusinessProcessDevelopmentArtifactResponse + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.body1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const validateBusinessProcessDevelopmentArtifactOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/validateBusinessProcessDevelopmentArtifact", + httpMethod: "POST", + responses: { + 200: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.body1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const listBySpaceNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ApplicationListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcessVersions.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcessVersions.ts new file mode 100644 index 000000000000..3efe65d75d48 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcessVersions.ts @@ -0,0 +1,311 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { BusinessProcessVersions } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + BusinessProcessVersion, + BusinessProcessVersionsListByBusinessProcessNextOptionalParams, + BusinessProcessVersionsListByBusinessProcessOptionalParams, + BusinessProcessVersionsListByBusinessProcessResponse, + BusinessProcessVersionsGetOptionalParams, + BusinessProcessVersionsGetResponse, + BusinessProcessVersionsListByBusinessProcessNextResponse +} from "../models"; + +/// +/** Class containing BusinessProcessVersions operations. */ +export class BusinessProcessVersionsImpl implements BusinessProcessVersions { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class BusinessProcessVersions class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List BusinessProcessVersion resources by BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + public listByBusinessProcess( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessVersionsListByBusinessProcessOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listByBusinessProcessPagingAll( + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + 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.listByBusinessProcessPagingPage( + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options, + settings + ); + } + }; + } + + private async *listByBusinessProcessPagingPage( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessVersionsListByBusinessProcessOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: BusinessProcessVersionsListByBusinessProcessResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByBusinessProcess( + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByBusinessProcessNext( + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByBusinessProcessPagingAll( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessVersionsListByBusinessProcessOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listByBusinessProcessPagingPage( + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options + )) { + yield* page; + } + } + + /** + * List BusinessProcessVersion resources by BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + private _listByBusinessProcess( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessVersionsListByBusinessProcessOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options + }, + listByBusinessProcessOperationSpec + ); + } + + /** + * Get a BusinessProcessVersion + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param businessProcessVersion The version of the business process + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + businessProcessVersion: string, + options?: BusinessProcessVersionsGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + businessProcessVersion, + options + }, + getOperationSpec + ); + } + + /** + * ListByBusinessProcessNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param nextLink The nextLink from the previous successful call to the ListByBusinessProcess method. + * @param options The options parameters. + */ + private _listByBusinessProcessNext( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + nextLink: string, + options?: BusinessProcessVersionsListByBusinessProcessNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + nextLink, + options + }, + listByBusinessProcessNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listByBusinessProcessOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcessVersionListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}/versions/{businessProcessVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcessVersion + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName, + Parameters.businessProcessVersion + ], + headerParameters: [Parameters.accept], + serializer +}; +const listByBusinessProcessNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcessVersionListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcesses.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcesses.ts new file mode 100644 index 000000000000..617db4b7c1fb --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/businessProcesses.ts @@ -0,0 +1,450 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { BusinessProcesses } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + BusinessProcess, + BusinessProcessesListByApplicationNextOptionalParams, + BusinessProcessesListByApplicationOptionalParams, + BusinessProcessesListByApplicationResponse, + BusinessProcessesGetOptionalParams, + BusinessProcessesGetResponse, + BusinessProcessesCreateOrUpdateOptionalParams, + BusinessProcessesCreateOrUpdateResponse, + BusinessProcessUpdate, + BusinessProcessesPatchOptionalParams, + BusinessProcessesPatchResponse, + BusinessProcessesDeleteOptionalParams, + BusinessProcessesListByApplicationNextResponse +} from "../models"; + +/// +/** Class containing BusinessProcesses operations. */ +export class BusinessProcessesImpl implements BusinessProcesses { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class BusinessProcesses class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List BusinessProcess resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + public listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: BusinessProcessesListByApplicationOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listByApplicationPagingAll( + resourceGroupName, + spaceName, + applicationName, + 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.listByApplicationPagingPage( + resourceGroupName, + spaceName, + applicationName, + options, + settings + ); + } + }; + } + + private async *listByApplicationPagingPage( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: BusinessProcessesListByApplicationOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: BusinessProcessesListByApplicationResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByApplication( + resourceGroupName, + spaceName, + applicationName, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByApplicationNext( + resourceGroupName, + spaceName, + applicationName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByApplicationPagingAll( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: BusinessProcessesListByApplicationOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listByApplicationPagingPage( + resourceGroupName, + spaceName, + applicationName, + options + )) { + yield* page; + } + } + + /** + * List BusinessProcess resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + private _listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: BusinessProcessesListByApplicationOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, options }, + listByApplicationOperationSpec + ); + } + + /** + * Get a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options + }, + getOperationSpec + ); + } + + /** + * Create a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + resource: BusinessProcess, + options?: BusinessProcessesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + resource, + options + }, + createOrUpdateOperationSpec + ); + } + + /** + * Update a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + properties: BusinessProcessUpdate, + options?: BusinessProcessesPatchOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + properties, + options + }, + patchOperationSpec + ); + } + + /** + * Delete a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + applicationName, + businessProcessName, + options + }, + deleteOperationSpec + ); + } + + /** + * ListByApplicationNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param nextLink The nextLink from the previous successful call to the ListByApplication method. + * @param options The options parameters. + */ + private _listByApplicationNext( + resourceGroupName: string, + spaceName: string, + applicationName: string, + nextLink: string, + options?: BusinessProcessesListByApplicationNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, applicationName, nextLink, options }, + listByApplicationNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listByApplicationOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcessListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcess + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcess + }, + 201: { + bodyMapper: Mappers.BusinessProcess + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.resource2, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const patchOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcess + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.properties2, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/applications/{applicationName}/businessProcesses/{businessProcessName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName, + Parameters.businessProcessName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listByApplicationNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.BusinessProcessListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.applicationName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/index.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/index.ts new file mode 100644 index 000000000000..a5165821b759 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/index.ts @@ -0,0 +1,15 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export * from "./operations"; +export * from "./spaces"; +export * from "./applications"; +export * from "./businessProcesses"; +export * from "./businessProcessVersions"; +export * from "./applicationResources"; +export * from "./infrastructureResources"; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/infrastructureResources.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/infrastructureResources.ts new file mode 100644 index 000000000000..75786686332b --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/infrastructureResources.ts @@ -0,0 +1,405 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { InfrastructureResources } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + InfrastructureResource, + InfrastructureResourcesListBySpaceNextOptionalParams, + InfrastructureResourcesListBySpaceOptionalParams, + InfrastructureResourcesListBySpaceResponse, + InfrastructureResourcesGetOptionalParams, + InfrastructureResourcesGetResponse, + InfrastructureResourcesCreateOrUpdateOptionalParams, + InfrastructureResourcesCreateOrUpdateResponse, + InfrastructureResourceUpdate, + InfrastructureResourcesPatchOptionalParams, + InfrastructureResourcesPatchResponse, + InfrastructureResourcesDeleteOptionalParams, + InfrastructureResourcesListBySpaceNextResponse +} from "../models"; + +/// +/** Class containing InfrastructureResources operations. */ +export class InfrastructureResourcesImpl implements InfrastructureResources { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class InfrastructureResources class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List InfrastructureResource resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + public listBySpace( + resourceGroupName: string, + spaceName: string, + options?: InfrastructureResourcesListBySpaceOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listBySpacePagingAll( + resourceGroupName, + spaceName, + 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.listBySpacePagingPage( + resourceGroupName, + spaceName, + options, + settings + ); + } + }; + } + + private async *listBySpacePagingPage( + resourceGroupName: string, + spaceName: string, + options?: InfrastructureResourcesListBySpaceOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: InfrastructureResourcesListBySpaceResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBySpace(resourceGroupName, spaceName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBySpaceNext( + resourceGroupName, + spaceName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBySpacePagingAll( + resourceGroupName: string, + spaceName: string, + options?: InfrastructureResourcesListBySpaceOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listBySpacePagingPage( + resourceGroupName, + spaceName, + options + )) { + yield* page; + } + } + + /** + * List InfrastructureResource resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + private _listBySpace( + resourceGroupName: string, + spaceName: string, + options?: InfrastructureResourcesListBySpaceOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, options }, + listBySpaceOperationSpec + ); + } + + /** + * Get a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + options?: InfrastructureResourcesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, infrastructureResourceName, options }, + getOperationSpec + ); + } + + /** + * Create a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + resource: InfrastructureResource, + options?: InfrastructureResourcesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + infrastructureResourceName, + resource, + options + }, + createOrUpdateOperationSpec + ); + } + + /** + * Update a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + properties: InfrastructureResourceUpdate, + options?: InfrastructureResourcesPatchOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + spaceName, + infrastructureResourceName, + properties, + options + }, + patchOperationSpec + ); + } + + /** + * Delete a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + options?: InfrastructureResourcesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, infrastructureResourceName, options }, + deleteOperationSpec + ); + } + + /** + * ListBySpaceNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param nextLink The nextLink from the previous successful call to the ListBySpace method. + * @param options The options parameters. + */ + private _listBySpaceNext( + resourceGroupName: string, + spaceName: string, + nextLink: string, + options?: InfrastructureResourcesListBySpaceNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, nextLink, options }, + listBySpaceNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listBySpaceOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/infrastructureResources", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.InfrastructureResourceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/infrastructureResources/{infrastructureResourceName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.InfrastructureResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.infrastructureResourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/infrastructureResources/{infrastructureResourceName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.InfrastructureResource + }, + 201: { + bodyMapper: Mappers.InfrastructureResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.resource4, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.infrastructureResourceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const patchOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/infrastructureResources/{infrastructureResourceName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.InfrastructureResource + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.properties4, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.infrastructureResourceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}/infrastructureResources/{infrastructureResourceName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName, + Parameters.infrastructureResourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listBySpaceNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.InfrastructureResourceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/operations.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/operations.ts new file mode 100644 index 000000000000..fb3784285067 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/operations.ts @@ -0,0 +1,149 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { Operations } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + Operation, + OperationsListNextOptionalParams, + OperationsListOptionalParams, + OperationsListResponse, + OperationsListNextResponse +} from "../models"; + +/// +/** Class containing Operations operations. */ +export class OperationsImpl implements Operations { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class Operations class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List the operations for the provider + * @param options The options parameters. + */ + public list( + options?: OperationsListOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(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(options, settings); + } + }; + } + + private async *listPagingPage( + options?: OperationsListOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: OperationsListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext(continuationToken, options); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + options?: OperationsListOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listPagingPage(options)) { + yield* page; + } + } + + /** + * List the operations for the provider + * @param options The options parameters. + */ + private _list( + options?: OperationsListOptionalParams + ): Promise { + return this.client.sendOperationRequest({ options }, listOperationSpec); + } + + /** + * ListNext + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + nextLink: string, + options?: OperationsListNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { nextLink, options }, + listNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.IntegrationSpaces/operations", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.OperationListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host], + headerParameters: [Parameters.accept], + serializer +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.OperationListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [Parameters.$host, Parameters.nextLink], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/spaces.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/spaces.ts new file mode 100644 index 000000000000..39b5072842f8 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operations/spaces.ts @@ -0,0 +1,486 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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"; +import { Spaces } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { MicrosoftIntegrationSpaces } from "../microsoftIntegrationSpaces"; +import { + Space, + SpacesListBySubscriptionNextOptionalParams, + SpacesListBySubscriptionOptionalParams, + SpacesListBySubscriptionResponse, + SpacesListByResourceGroupNextOptionalParams, + SpacesListByResourceGroupOptionalParams, + SpacesListByResourceGroupResponse, + SpacesGetOptionalParams, + SpacesGetResponse, + SpacesCreateOrUpdateOptionalParams, + SpacesCreateOrUpdateResponse, + SpaceUpdate, + SpacesPatchOptionalParams, + SpacesPatchResponse, + SpacesDeleteOptionalParams, + SpacesListBySubscriptionNextResponse, + SpacesListByResourceGroupNextResponse +} from "../models"; + +/// +/** Class containing Spaces operations. */ +export class SpacesImpl implements Spaces { + private readonly client: MicrosoftIntegrationSpaces; + + /** + * Initialize a new instance of the class Spaces class. + * @param client Reference to the service client + */ + constructor(client: MicrosoftIntegrationSpaces) { + this.client = client; + } + + /** + * List Space resources by subscription ID + * @param options The options parameters. + */ + public listBySubscription( + options?: SpacesListBySubscriptionOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listBySubscriptionPagingAll(options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listBySubscriptionPagingPage(options, settings); + } + }; + } + + private async *listBySubscriptionPagingPage( + options?: SpacesListBySubscriptionOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: SpacesListBySubscriptionResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBySubscription(options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBySubscriptionNext(continuationToken, options); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBySubscriptionPagingAll( + options?: SpacesListBySubscriptionOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listBySubscriptionPagingPage(options)) { + yield* page; + } + } + + /** + * List Space resources by resource group + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param options The options parameters. + */ + public listByResourceGroup( + resourceGroupName: string, + options?: SpacesListByResourceGroupOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listByResourceGroupPagingPage( + resourceGroupName, + options, + settings + ); + } + }; + } + + private async *listByResourceGroupPagingPage( + resourceGroupName: string, + options?: SpacesListByResourceGroupOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: SpacesListByResourceGroupResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByResourceGroup(resourceGroupName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByResourceGroupNext( + resourceGroupName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByResourceGroupPagingAll( + resourceGroupName: string, + options?: SpacesListByResourceGroupOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listByResourceGroupPagingPage( + resourceGroupName, + options + )) { + yield* page; + } + } + + /** + * List Space resources by subscription ID + * @param options The options parameters. + */ + private _listBySubscription( + options?: SpacesListBySubscriptionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { options }, + listBySubscriptionOperationSpec + ); + } + + /** + * List Space resources by resource group + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param options The options parameters. + */ + private _listByResourceGroup( + resourceGroupName: string, + options?: SpacesListByResourceGroupOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, options }, + listByResourceGroupOperationSpec + ); + } + + /** + * Get a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + options?: SpacesGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, options }, + getOperationSpec + ); + } + + /** + * Create a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + resource: Space, + options?: SpacesCreateOrUpdateOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, resource, options }, + createOrUpdateOperationSpec + ); + } + + /** + * Update a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + properties: SpaceUpdate, + options?: SpacesPatchOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, properties, options }, + patchOperationSpec + ); + } + + /** + * Delete a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + options?: SpacesDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, spaceName, options }, + deleteOperationSpec + ); + } + + /** + * ListBySubscriptionNext + * @param nextLink The nextLink from the previous successful call to the ListBySubscription method. + * @param options The options parameters. + */ + private _listBySubscriptionNext( + nextLink: string, + options?: SpacesListBySubscriptionNextOptionalParams + ): 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?: SpacesListByResourceGroupNextOptionalParams + ): 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.IntegrationSpaces/spaces", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.SpaceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.subscriptionId], + headerParameters: [Parameters.accept], + serializer +}; +const listByResourceGroupOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.SpaceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [ + Parameters.apiVersion, + Parameters.top, + Parameters.skip, + Parameters.maxpagesize, + Parameters.filter, + Parameters.select, + Parameters.expand, + Parameters.orderby + ], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Space + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Space + }, + 201: { + bodyMapper: Mappers.Space + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.resource, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const patchOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.Space + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.properties, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IntegrationSpaces/spaces/{spaceName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.spaceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.SpaceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId + ], + headerParameters: [Parameters.accept], + serializer +}; +const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.SpaceListResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applicationResources.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applicationResources.ts new file mode 100644 index 000000000000..8d96443750c8 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applicationResources.ts @@ -0,0 +1,103 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + ApplicationResource, + ApplicationResourcesListByApplicationOptionalParams, + ApplicationResourcesGetOptionalParams, + ApplicationResourcesGetResponse, + ApplicationResourcesCreateOrUpdateOptionalParams, + ApplicationResourcesCreateOrUpdateResponse, + ApplicationResourceUpdate, + ApplicationResourcesPatchOptionalParams, + ApplicationResourcesPatchResponse, + ApplicationResourcesDeleteOptionalParams +} from "../models"; + +/// +/** Interface representing a ApplicationResources. */ +export interface ApplicationResources { + /** + * List ApplicationResource resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationResourcesListByApplicationOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + options?: ApplicationResourcesGetOptionalParams + ): Promise; + /** + * Create a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + resource: ApplicationResource, + options?: ApplicationResourcesCreateOrUpdateOptionalParams + ): Promise; + /** + * Update a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + properties: ApplicationResourceUpdate, + options?: ApplicationResourcesPatchOptionalParams + ): Promise; + /** + * Delete a ApplicationResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resourceName The name of the application resource. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resourceName: string, + options?: ApplicationResourcesDeleteOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applications.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applications.ts new file mode 100644 index 000000000000..4bc6bf35ba91 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/applications.ts @@ -0,0 +1,176 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + Application, + ApplicationsListBySpaceOptionalParams, + ApplicationsGetOptionalParams, + ApplicationsGetResponse, + ApplicationsCreateOrUpdateOptionalParams, + ApplicationsCreateOrUpdateResponse, + ApplicationUpdate, + ApplicationsPatchOptionalParams, + ApplicationsPatchResponse, + ApplicationsDeleteOptionalParams, + GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsGetBusinessProcessDevelopmentArtifactResponse, + ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams, + ApplicationsListBusinessProcessDevelopmentArtifactsResponse, + SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams, + ApplicationsSaveBusinessProcessDevelopmentArtifactResponse, + ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams +} from "../models"; + +/// +/** Interface representing a Applications. */ +export interface Applications { + /** + * List Application resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + listBySpace( + resourceGroupName: string, + spaceName: string, + options?: ApplicationsListBySpaceOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsGetOptionalParams + ): Promise; + /** + * Create a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + resource: Application, + options?: ApplicationsCreateOrUpdateOptionalParams + ): Promise; + /** + * Update a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + properties: ApplicationUpdate, + options?: ApplicationsPatchOptionalParams + ): Promise; + /** + * Delete a Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsDeleteOptionalParams + ): Promise; + /** + * The delete business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + deleteBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsDeleteBusinessProcessDevelopmentArtifactOptionalParams + ): Promise; + /** + * The get business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + getBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: GetOrDeleteBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsGetBusinessProcessDevelopmentArtifactOptionalParams + ): Promise; + /** + * The list business process development artifacts action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + listBusinessProcessDevelopmentArtifacts( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: ApplicationsListBusinessProcessDevelopmentArtifactsOptionalParams + ): Promise; + /** + * The save business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + saveBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsSaveBusinessProcessDevelopmentArtifactOptionalParams + ): Promise; + /** + * The validate business process development artifact action. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param body The content of the action request + * @param options The options parameters. + */ + validateBusinessProcessDevelopmentArtifact( + resourceGroupName: string, + spaceName: string, + applicationName: string, + body: SaveOrValidateBusinessProcessDevelopmentArtifactRequest, + options?: ApplicationsValidateBusinessProcessDevelopmentArtifactOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcessVersions.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcessVersions.ts new file mode 100644 index 000000000000..b8028da7ae69 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcessVersions.ts @@ -0,0 +1,52 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { + BusinessProcessVersion, + BusinessProcessVersionsListByBusinessProcessOptionalParams, + BusinessProcessVersionsGetOptionalParams, + BusinessProcessVersionsGetResponse +} from "../models"; + +/// +/** Interface representing a BusinessProcessVersions. */ +export interface BusinessProcessVersions { + /** + * List BusinessProcessVersion resources by BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + listByBusinessProcess( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessVersionsListByBusinessProcessOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a BusinessProcessVersion + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param businessProcessVersion The version of the business process + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + businessProcessVersion: string, + options?: BusinessProcessVersionsGetOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcesses.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcesses.ts new file mode 100644 index 000000000000..a9f49eea061a --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/businessProcesses.ts @@ -0,0 +1,103 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + BusinessProcess, + BusinessProcessesListByApplicationOptionalParams, + BusinessProcessesGetOptionalParams, + BusinessProcessesGetResponse, + BusinessProcessesCreateOrUpdateOptionalParams, + BusinessProcessesCreateOrUpdateResponse, + BusinessProcessUpdate, + BusinessProcessesPatchOptionalParams, + BusinessProcessesPatchResponse, + BusinessProcessesDeleteOptionalParams +} from "../models"; + +/// +/** Interface representing a BusinessProcesses. */ +export interface BusinessProcesses { + /** + * List BusinessProcess resources by Application + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param options The options parameters. + */ + listByApplication( + resourceGroupName: string, + spaceName: string, + applicationName: string, + options?: BusinessProcessesListByApplicationOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessesGetOptionalParams + ): Promise; + /** + * Create a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + resource: BusinessProcess, + options?: BusinessProcessesCreateOrUpdateOptionalParams + ): Promise; + /** + * Update a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + properties: BusinessProcessUpdate, + options?: BusinessProcessesPatchOptionalParams + ): Promise; + /** + * Delete a BusinessProcess + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param applicationName The name of the Application + * @param businessProcessName The name of the business process + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + applicationName: string, + businessProcessName: string, + options?: BusinessProcessesDeleteOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/index.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/index.ts new file mode 100644 index 000000000000..a5165821b759 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/index.ts @@ -0,0 +1,15 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export * from "./operations"; +export * from "./spaces"; +export * from "./applications"; +export * from "./businessProcesses"; +export * from "./businessProcessVersions"; +export * from "./applicationResources"; +export * from "./infrastructureResources"; diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/infrastructureResources.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/infrastructureResources.ts new file mode 100644 index 000000000000..1cb9f63520dd --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/infrastructureResources.ts @@ -0,0 +1,93 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { + InfrastructureResource, + InfrastructureResourcesListBySpaceOptionalParams, + InfrastructureResourcesGetOptionalParams, + InfrastructureResourcesGetResponse, + InfrastructureResourcesCreateOrUpdateOptionalParams, + InfrastructureResourcesCreateOrUpdateResponse, + InfrastructureResourceUpdate, + InfrastructureResourcesPatchOptionalParams, + InfrastructureResourcesPatchResponse, + InfrastructureResourcesDeleteOptionalParams +} from "../models"; + +/// +/** Interface representing a InfrastructureResources. */ +export interface InfrastructureResources { + /** + * List InfrastructureResource resources by Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + listBySpace( + resourceGroupName: string, + spaceName: string, + options?: InfrastructureResourcesListBySpaceOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + options?: InfrastructureResourcesGetOptionalParams + ): Promise; + /** + * Create a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + resource: InfrastructureResource, + options?: InfrastructureResourcesCreateOrUpdateOptionalParams + ): Promise; + /** + * Update a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + properties: InfrastructureResourceUpdate, + options?: InfrastructureResourcesPatchOptionalParams + ): Promise; + /** + * Delete a InfrastructureResource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param infrastructureResourceName The name of the infrastructure resource in the space. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + infrastructureResourceName: string, + options?: InfrastructureResourcesDeleteOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/operations.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/operations.ts new file mode 100644 index 000000000000..5cf5581845bd --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/operations.ts @@ -0,0 +1,22 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT 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 { Operation, OperationsListOptionalParams } from "../models"; + +/// +/** Interface representing a Operations. */ +export interface Operations { + /** + * List the operations for the provider + * @param options The options parameters. + */ + list( + options?: OperationsListOptionalParams + ): PagedAsyncIterableIterator; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/spaces.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/spaces.ts new file mode 100644 index 000000000000..13536ba9a6e4 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/operationsInterfaces/spaces.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 { + Space, + SpacesListBySubscriptionOptionalParams, + SpacesListByResourceGroupOptionalParams, + SpacesGetOptionalParams, + SpacesGetResponse, + SpacesCreateOrUpdateOptionalParams, + SpacesCreateOrUpdateResponse, + SpaceUpdate, + SpacesPatchOptionalParams, + SpacesPatchResponse, + SpacesDeleteOptionalParams +} from "../models"; + +/// +/** Interface representing a Spaces. */ +export interface Spaces { + /** + * List Space resources by subscription ID + * @param options The options parameters. + */ + listBySubscription( + options?: SpacesListBySubscriptionOptionalParams + ): PagedAsyncIterableIterator; + /** + * List Space resources by resource group + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param options The options parameters. + */ + listByResourceGroup( + resourceGroupName: string, + options?: SpacesListByResourceGroupOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + get( + resourceGroupName: string, + spaceName: string, + options?: SpacesGetOptionalParams + ): Promise; + /** + * Create a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param resource Resource create parameters. + * @param options The options parameters. + */ + createOrUpdate( + resourceGroupName: string, + spaceName: string, + resource: Space, + options?: SpacesCreateOrUpdateOptionalParams + ): Promise; + /** + * Update a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param properties The resource properties to be updated. + * @param options The options parameters. + */ + patch( + resourceGroupName: string, + spaceName: string, + properties: SpaceUpdate, + options?: SpacesPatchOptionalParams + ): Promise; + /** + * Delete a Space + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param spaceName The name of the space + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + spaceName: string, + options?: SpacesDeleteOptionalParams + ): Promise; +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/pagingHelper.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/pagingHelper.ts new file mode 100644 index 000000000000..269a2b9814b5 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/src/pagingHelper.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export interface PageInfo { + continuationToken?: string; +} + +const pageMap = new WeakMap(); + +/** + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from + * that point later. + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. + */ +export function getContinuationToken(page: unknown): string | undefined { + if (typeof page !== "object" || page === null) { + return undefined; + } + return pageMap.get(page)?.continuationToken; +} + +export function setContinuationToken( + page: unknown, + continuationToken: string | undefined +): void { + if (typeof page !== "object" || page === null || !continuationToken) { + return; + } + const pageInfo = pageMap.get(page) ?? {}; + pageInfo.continuationToken = continuationToken; + pageMap.set(page, pageInfo); +} diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/test/sampleTest.ts b/sdk/azureintegrationspaces/arm-azureintegrationspaces/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +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(this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function() { + await recorder.stop(); + }); + + it("sample test", async function() { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/azureintegrationspaces/arm-azureintegrationspaces/tsconfig.json b/sdk/azureintegrationspaces/arm-azureintegrationspaces/tsconfig.json new file mode 100644 index 000000000000..3e6ae96443f3 --- /dev/null +++ b/sdk/azureintegrationspaces/arm-azureintegrationspaces/tsconfig.json @@ -0,0 +1,27 @@ +{ + "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/azureintegrationspaces/ci.mgmt.yml b/sdk/azureintegrationspaces/ci.mgmt.yml new file mode 100644 index 000000000000..c8ebdb6ea292 --- /dev/null +++ b/sdk/azureintegrationspaces/ci.mgmt.yml @@ -0,0 +1,38 @@ +# NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file. + +trigger: + branches: + include: + - main + - feature/* + - release/* + - hotfix/* + exclude: + - feature/v4 + paths: + include: + - sdk/azureintegrationspaces/arm-azureintegrationspaces + - sdk/azureintegrationspaces/ci.mgmt.yml + +pr: + branches: + include: + - main + - feature/* + - release/* + - hotfix/* + exclude: + - feature/v4 + paths: + include: + - sdk/azureintegrationspaces/arm-azureintegrationspaces + - sdk/azureintegrationspaces/ci.mgmt.yml + +extends: + template: /eng/pipelines/templates/stages/archetype-sdk-client.yml + parameters: + ServiceDirectory: azureintegrationspaces + Artifacts: + - name: azure-arm-azureintegrationspaces + safeName: azurearmazureintegrationspaces + \ No newline at end of file