From 3019cbb953625fc6ed658ab9a134dc8ef13c9a22 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 9 Jul 2024 02:48:21 +0000 Subject: [PATCH] CodeGen from PR 29707 in Azure/azure-rest-api-specs Merge bd246a654089bc08bbb99f1dbf2c35755a51e40b into cbbe228fd422db02b65e2748f83df5f2bcad7581 --- common/config/rush/pnpm-lock.yaml | 27 +- .../purview-datamap-rest/.eslintrc.json | 5 +- sdk/purview/purview-datamap-rest/README.md | 37 +- .../purview-datamap-rest/api-extractor.json | 27 +- sdk/purview/purview-datamap-rest/package.json | 191 ++++--- .../review/purview-datamap.api.md | 509 +++++++++++------- .../src/clientDefinitions.ts | 449 ++++++++++----- sdk/purview/purview-datamap-rest/src/index.ts | 24 +- .../purview-datamap-rest/src/isUnexpected.ts | 259 ++++++--- .../purview-datamap-rest/src/models.ts | 220 +++----- .../purview-datamap-rest/src/outputModels.ts | 250 +++------ .../purview-datamap-rest/src/parameters.ts | 388 ++++++++----- .../src/purviewDataMapClient.ts | 35 +- .../purview-datamap-rest/src/responses.ts | 191 ++++--- .../src/serializeHelper.ts | 5 +- .../test/public/sampleTest.spec.ts | 21 + .../test/public/utils/recordedClient.ts | 23 +- .../tsconfig.browser.config.json | 10 + .../purview-datamap-rest/tsconfig.json | 16 +- .../purview-datamap-rest/tsp-location.yaml | 2 +- .../vitest.browser.config.ts | 36 ++ .../purview-datamap-rest/vitest.config.ts | 32 ++ 22 files changed, 1674 insertions(+), 1083 deletions(-) create mode 100644 sdk/purview/purview-datamap-rest/test/public/sampleTest.spec.ts create mode 100644 sdk/purview/purview-datamap-rest/tsconfig.browser.config.json create mode 100644 sdk/purview/purview-datamap-rest/vitest.browser.config.ts create mode 100644 sdk/purview/purview-datamap-rest/vitest.config.ts diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index e88839ef06ca..56bac6819492 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -22710,7 +22710,7 @@ packages: dev: false file:projects/purview-datamap.tgz: - resolution: {integrity: sha512-MKf154evmKFTBD68rwGXTKraZkk3566Pigr7ELV6oezp0AqzSOHm7hvkY7ClsIbUFbKjKFYthhZIJz8lJU2P2Q==, tarball: file:projects/purview-datamap.tgz} + resolution: {integrity: sha512-ZLXPxIbuPSARe68+RJFEo5FgddZ70pWCWjnsmVsnYO3Hkf/xxczmIW374+n7ixB+dvSvpKwayWGWcALwT7ingw==, tarball: file:projects/purview-datamap.tgz} name: '@rush-temp/purview-datamap' version: 0.0.0 dependencies: @@ -22721,6 +22721,8 @@ packages: '@types/chai': 4.3.16 '@types/mocha': 10.0.7 '@types/node': 18.19.39 + '@vitest/browser': 1.6.0(playwright@1.45.1)(vitest@1.6.0) + '@vitest/coverage-istanbul': 1.6.0(vitest@1.6.0) autorest: 3.7.1 chai: 4.3.10 cross-env: 7.0.3 @@ -22739,18 +22741,29 @@ packages: mkdirp: 3.0.1 mocha: 10.6.0 nyc: 17.0.0 + playwright: 1.45.1 + prettier: 3.3.2 rimraf: 5.0.8 source-map-support: 0.5.21 ts-node: 10.9.2(@types/node@18.19.39)(typescript@5.5.3) + tshy: 1.18.0 tslib: 2.6.3 - typescript: 5.5.3 + typescript: 5.4.5 + vitest: 1.6.0(@types/node@18.19.39)(@vitest/browser@1.6.0) transitivePeerDependencies: - - '@swc/core' - - '@swc/wasm' - - bufferutil - - debug + - '@edge-runtime/vm' + - '@vitest/ui' + - happy-dom + - jsdom + - less + - lightningcss + - safaridriver + - sass + - stylus + - sugarss - supports-color - - utf-8-validate + - terser + - webdriverio dev: false file:projects/purview-scanning.tgz: diff --git a/sdk/purview/purview-datamap-rest/.eslintrc.json b/sdk/purview/purview-datamap-rest/.eslintrc.json index 619797ac39b6..8793fba07e9d 100644 --- a/sdk/purview/purview-datamap-rest/.eslintrc.json +++ b/sdk/purview/purview-datamap-rest/.eslintrc.json @@ -6,6 +6,9 @@ "@azure/azure-sdk/ts-apiextractor-json-types": "warn", "@azure/azure-sdk/ts-package-json-types": "warn", "@azure/azure-sdk/ts-package-json-engine-is-present": "warn", - "tsdoc/syntax": "warn" + "tsdoc/syntax": "warn", + "@azure/azure-sdk/ts-package-json-module": "off", + "@azure/azure-sdk/ts-package-json-files-required": "off", + "@azure/azure-sdk/ts-package-json-main-is-cjs": "off" } } diff --git a/sdk/purview/purview-datamap-rest/README.md b/sdk/purview/purview-datamap-rest/README.md index 1ad4e5b19519..8719b426acc6 100644 --- a/sdk/purview/purview-datamap-rest/README.md +++ b/sdk/purview/purview-datamap-rest/README.md @@ -1,6 +1,9 @@ # Azure PurviewDataMap REST client library for JavaScript -Microsoft Purview Data Map provides the foundation for data discovery and data governance. Microsoft Purview Data Map is a cloud native PaaS service that captures metadata about enterprise data present in analytics and operation systems on-premises and cloud. Azure PurviewDataMap client provides a set of APIs in Purview Data Map Data Plane. For a full list of APIs, please refer to [Data Map API](https://learn.microsoft.com/rest/api/purview/datamapdataplane/operation-groups?view=rest-purview-datamapdataplane-2023-09-01). +Purview Data Map Service is a fully managed cloud service whose users can +discover the data sources they need and understand the data sources they find. +At the same time, Data Map helps organizations get more value from their +existing investments. This spec defines REST API of Purview Data Map Service. **Please rely heavily on our [REST client docs](https://github.com/Azure/azure-sdk-for-js/blob/main/documentation/rest-clients.md) to use this library** @@ -44,38 +47,6 @@ can be used to authenticate the client. 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 -## Examples - -The following sections provide several code snippets covering some of the most common Purview DataMap scenarios, including: - -- [Get All Type Definitions](#get-all-type-definitions) - -### Get All Type Definitions - -```typescript -import PurviewDataMap from "@azure-rest/purview-datamap"; -import { DefaultAzureCredential } from "@azure/identity"; -import dotenv from "dotenv"; -import { isUnexpected } from "@azure-rest/purview-datamap"; - -dotenv.config(); - -const endpoint = process.env["ENDPOINT"] || ""; - -async function main() { - console.log("== List entity typedefs sample =="); - const client = PurviewDataMap(endpoint, new DefaultAzureCredential()); - - const result = await client.path("/atlas/v2/types/typedefs").get(); - - if (isUnexpected(result)) { - throw result; - } -} - -main().catch(console.error); -``` - ## Troubleshooting ### Logging diff --git a/sdk/purview/purview-datamap-rest/api-extractor.json b/sdk/purview/purview-datamap-rest/api-extractor.json index d4dc8578d51e..188bcfd454d2 100644 --- a/sdk/purview/purview-datamap-rest/api-extractor.json +++ b/sdk/purview/purview-datamap-rest/api-extractor.json @@ -1,18 +1,31 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", - "mainEntryPointFilePath": "./types/src/index.d.ts", - "docModel": { "enabled": true }, - "apiReport": { "enabled": true, "reportFolder": "./review" }, + "mainEntryPointFilePath": "./dist/esm/index.d.ts", + "docModel": { + "enabled": true + }, + "apiReport": { + "enabled": true, + "reportFolder": "./review" + }, "dtsRollup": { "enabled": true, "untrimmedFilePath": "", "publicTrimmedFilePath": "./types/purview-datamap.d.ts" }, "messages": { - "tsdocMessageReporting": { "default": { "logLevel": "none" } }, + "tsdocMessageReporting": { + "default": { + "logLevel": "none" + } + }, "extractorMessageReporting": { - "ae-missing-release-tag": { "logLevel": "none" }, - "ae-unresolved-link": { "logLevel": "none" } + "ae-missing-release-tag": { + "logLevel": "none" + }, + "ae-unresolved-link": { + "logLevel": "none" + } } } -} +} \ No newline at end of file diff --git a/sdk/purview/purview-datamap-rest/package.json b/sdk/purview/purview-datamap-rest/package.json index 6855d4ddf63e..87e35c2bee72 100644 --- a/sdk/purview/purview-datamap-rest/package.json +++ b/sdk/purview/purview-datamap-rest/package.json @@ -1,9 +1,28 @@ { "name": "@azure-rest/purview-datamap", - "sdk-type": "client", - "author": "Microsoft Corporation", - "version": "1.0.0-beta.2", + "version": "1.0.0-beta.1", "description": "Purview DataMap Service\"", + "engines": { + "node": ">=18.0.0" + }, + "sideEffects": false, + "autoPublish": false, + "tshy": { + "exports": { + "./package.json": "./package.json", + ".": "./src/index.ts" + }, + "dialects": [ + "esm", + "commonjs" + ], + "esmDialects": [ + "browser", + "react-native" + ], + "selfLink": false + }, + "type": "module", "keywords": [ "node", "azure", @@ -12,103 +31,107 @@ "browser", "isomorphic" ], + "author": "Microsoft Corporation", "license": "MIT", - "main": "dist/index.js", - "module": "./dist-esm/src/index.js", - "types": "./types/purview-datamap.d.ts", - "repository": "github:Azure/azure-sdk-for-js", - "bugs": { - "url": "https://github.com/Azure/azure-sdk-for-js/issues" - }, "files": [ - "dist/", - "dist-esm/src/", - "types/purview-datamap.d.ts", + "dist", "README.md", "LICENSE", "review/*" ], - "engines": { - "node": ">=18.0.0" + "sdk-type": "client", + "repository": "github:Azure/azure-sdk-for-js", + "bugs": { + "url": "https://github.com/Azure/azure-sdk-for-js/issues" }, - "scripts": { - "build:browser": "tsc -p . && cross-env ONLY_BROWSER=true rollup -c 2>&1", - "build:node": "tsc -p . && cross-env ONLY_NODE=true rollup -c 2>&1", - "build:samples": "echo skipped.", - "build:test": "tsc -p . && dev-tool run bundle", - "build:debug": "tsc -p . && dev-tool run bundle && dev-tool run extract-api", - "check-format": "dev-tool run vendored prettier --list-different --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"*.{js,json}\" \"test/**/*.ts\"", - "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", - "execute:samples": "echo skipped", - "extract-api": "rimraf review && mkdirp ./review && dev-tool run extract-api", - "format": "dev-tool run vendored prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"*.{js,json}\" \"test/**/*.ts\"", - "generate:client": "echo skipped", - "integration-test:browser": "dev-tool run test:browser", - "integration-test:node": "dev-tool run test:node-js-input -- --timeout 5000000 'dist-esm/test/**/*.spec.js'", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "lint:fix": "eslint package.json api-extractor.json src test --ext .ts --fix --fix-type [problem,suggestion]", - "lint": "eslint package.json api-extractor.json src test --ext .ts", - "pack": "npm pack 2>&1", - "test:browser": "npm run clean && npm run build:test && npm run unit-test:browser", - "test:node": "npm run clean && npm run build:test && npm run unit-test:node", - "test": "npm run clean && npm run build:test && npm run unit-test", - "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 --exclude 'test/**/browser/*.spec.ts' 'test/**/*.spec.ts'", - "unit-test:browser": "dev-tool run test:browser", - "build": "npm run clean && tsc -p . && dev-tool run bundle && mkdirp ./review && dev-tool run extract-api" + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/purview/purview-datamap-rest/README.md", + "prettier": "@azure/eslint-plugin-azure-sdk/prettier.json", + "//metadata": { + "constantPaths": [ + { + "path": "src/purviewDataMapClient.ts", + "prefix": "package-version" + } + ] }, - "sideEffects": false, - "autoPublish": false, "dependencies": { + "@azure-rest/core-client": "^2.1.0", "@azure/core-auth": "^1.6.0", - "@azure-rest/core-client": "^1.2.0", - "@azure/core-rest-pipeline": "^1.14.0", + "@azure/core-rest-pipeline": "^1.5.0", "@azure/logger": "^1.0.0", - "tslib": "^2.2.0" + "tslib": "^2.6.2" }, "devDependencies": { - "@microsoft/api-extractor": "^7.31.1", - "autorest": "latest", - "@types/node": "^18.0.0", "dotenv": "^16.0.0", - "eslint": "^8.0.0", + "@microsoft/api-extractor": "^7.40.3", + "@types/node": "^18.0.0", + "eslint": "^8.55.0", + "prettier": "^3.2.5", + "rimraf": "^5.0.5", "mkdirp": "^3.0.1", - "rimraf": "^5.0.0", - "source-map-support": "^0.5.9", - "typescript": "~5.5.3", + "typescript": "~5.4.5", + "tshy": "^1.11.1", + "@azure/core-util": "^1.0.0", + "@azure/identity": "^4.2.1", + "@vitest/browser": "^1.3.1", + "@vitest/coverage-istanbul": "^1.3.1", + "playwright": "^1.41.2", + "vitest": "^1.3.1", + "@azure-tools/test-credential": "^2.0.0", + "@azure-tools/test-recorder": "^4.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/eslint-plugin-azure-sdk": "^3.0.0", - "@azure-tools/test-credential": "^1.0.0", - "@azure/identity": "^4.0.1", - "@azure-tools/test-recorder": "^3.0.0", - "mocha": "^10.0.0", - "@types/mocha": "^10.0.0", - "cross-env": "^7.0.2", - "@types/chai": "^4.2.8", - "chai": "^4.2.0", - "karma-chrome-launcher": "^3.0.0", - "karma-coverage": "^2.0.0", - "karma-env-preprocessor": "^0.1.1", - "karma-firefox-launcher": "^2.1.2", - "karma-junit-reporter": "^2.0.1", - "karma-mocha-reporter": "^2.2.5", - "karma-mocha": "^2.0.1", - "karma-source-map-support": "~1.4.0", - "karma-sourcemap-loader": "^0.4.0", - "karma": "^6.2.0", - "nyc": "^17.0.0", - "ts-node": "^10.0.0" + "@azure/eslint-plugin-azure-sdk": "^3.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/purview/purview-datamap-rest/README.md", - "//metadata": { - "constantPaths": [ - { - "path": "src/purviewDataMapClient.ts", - "prefix": "userAgentInfo" + "scripts": { + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", + "extract-api": "rimraf review && mkdirp ./review && dev-tool run extract-api", + "pack": "npm pack 2>&1", + "lint": "eslint package.json api-extractor.json src test --ext .ts --ext .cts --ext .mts", + "lint:fix": "eslint package.json api-extractor.json src test --ext .ts --ext .cts --ext .mts --fix --fix-type [problem,suggestion]", + "unit-test": "npm run unit-test:node && npm run unit-test:browser", + "unit-test:browser": "npm run build:test && dev-tool run test:vitest --browser", + "unit-test:node": "dev-tool run test:vitest", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:browser": "echo skipped", + "integration-test:node": "echo skipped", + "audit": "node ../../../common/scripts/rush-audit.js && rimraf node_modules package-lock.json && npm i --package-lock-only 2>&1 && npm audit", + "build:samples": "dev-tool samples publish --force", + "check-format": "dev-tool run vendored prettier --list-different --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.{ts,cts,mts}\" \"test/**/*.{ts,cts,mts}\" \"*.{js,cjs,mjs,json}\"", + "execute:samples": "dev-tool samples run samples-dev", + "format": "dev-tool run vendored prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.{ts,cts,mts}\" \"test/**/*.{ts,cts,mts}\" \"*.{js,cjs,mjs,json}\"", + "generate:client": "echo skipped", + "test:browser": "npm run clean && npm run build:test && npm run unit-test:browser && npm run integration-test:browser", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "build:test": "npm run clean && tshy && dev-tool run build-test", + "build": "npm run clean && tshy && mkdirp ./review && dev-tool run extract-api", + "test:node": "npm run clean && tshy && npm run unit-test:node && npm run integration-test:node", + "test": "npm run clean && tshy && npm run unit-test:node && dev-tool run bundle && npm run unit-test:browser && npm run integration-test" + }, + "exports": { + "./package.json": "./package.json", + ".": { + "browser": { + "source": "./src/index.ts", + "types": "./dist/browser/index.d.ts", + "default": "./dist/browser/index.js" + }, + "react-native": { + "source": "./src/index.ts", + "types": "./dist/react-native/index.d.ts", + "default": "./dist/react-native/index.js" + }, + "import": { + "source": "./src/index.ts", + "types": "./dist/esm/index.d.ts", + "default": "./dist/esm/index.js" + }, + "require": { + "source": "./src/index.ts", + "types": "./dist/commonjs/index.d.ts", + "default": "./dist/commonjs/index.js" } - ] + } }, - "browser": { - "./dist-esm/test/public/utils/env.js": "./dist-esm/test/public/utils/env.browser.js" - } -} + "main": "./dist/commonjs/index.js", + "types": "./dist/commonjs/index.d.ts" +} \ No newline at end of file diff --git a/sdk/purview/purview-datamap-rest/review/purview-datamap.api.md b/sdk/purview/purview-datamap-rest/review/purview-datamap.api.md index d665f53c37a3..b80aaabe5401 100644 --- a/sdk/purview/purview-datamap-rest/review/purview-datamap.api.md +++ b/sdk/purview/purview-datamap-rest/review/purview-datamap.api.md @@ -6,18 +6,15 @@ import { Client } from '@azure-rest/core-client'; import { ClientOptions } from '@azure-rest/core-client'; -import { createFile } from '@azure/core-rest-pipeline'; -import { createFileFromStream } from '@azure/core-rest-pipeline'; -import { CreateFileFromStreamOptions } from '@azure/core-rest-pipeline'; -import { CreateFileOptions } from '@azure/core-rest-pipeline'; import { HttpResponse } from '@azure-rest/core-client'; +import { RawHttpHeaders } from '@azure/core-rest-pipeline'; import { RequestParameters } from '@azure-rest/core-client'; import { StreamableMethod } from '@azure-rest/core-client'; import { TokenCredential } from '@azure/core-auth'; // @public export interface AtlasAttributeDef { - cardinality?: string; + cardinality?: CardinalityValue; constraints?: Array; defaultValue?: string; description?: string; @@ -34,7 +31,7 @@ export interface AtlasAttributeDef { // @public export interface AtlasAttributeDefOutput { - cardinality?: string; + cardinality?: CardinalityValueOutput; constraints?: Array; defaultValue?: string; description?: string; @@ -52,7 +49,7 @@ export interface AtlasAttributeDefOutput { // @public export interface AtlasBusinessMetadataDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -71,7 +68,7 @@ export interface AtlasBusinessMetadataDef { // @public export interface AtlasBusinessMetadataDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -91,7 +88,7 @@ export interface AtlasBusinessMetadataDefOutput { export interface AtlasClassification { attributes?: Record; entityGuid?: string; - entityStatus?: string; + entityStatus?: EntityStatus; lastModifiedTS?: string; removePropagationsOnEntityDelete?: boolean; typeName?: string; @@ -101,7 +98,7 @@ export interface AtlasClassification { // @public export interface AtlasClassificationDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -123,7 +120,7 @@ export interface AtlasClassificationDef { // @public export interface AtlasClassificationDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -146,7 +143,7 @@ export interface AtlasClassificationDefOutput { export interface AtlasClassificationOutput { attributes?: Record; entityGuid?: string; - entityStatus?: string; + entityStatus?: EntityStatusOutput; lastModifiedTS?: string; removePropagationsOnEntityDelete?: boolean; typeName?: string; @@ -158,7 +155,7 @@ export interface AtlasClassificationsOutput { list?: any[]; pageSize?: number; sortBy?: string; - sortType?: string; + sortType?: SortTypeOutput; startIndex?: number; totalCount?: number; } @@ -205,7 +202,7 @@ export interface AtlasEntity { provenanceType?: number; proxy?: boolean; relationshipAttributes?: Record; - status?: string; + status?: EntityStatus; typeName?: string; updatedBy?: string; updateTime?: number; @@ -215,7 +212,7 @@ export interface AtlasEntity { // @public export interface AtlasEntityDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -237,7 +234,7 @@ export interface AtlasEntityDef { // @public export interface AtlasEntityDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -268,7 +265,7 @@ export interface AtlasEntityHeader { lastModifiedTS?: string; meaningNames?: string[]; meanings?: Array; - status?: string; + status?: EntityStatus; typeName?: string; } @@ -284,7 +281,7 @@ export interface AtlasEntityHeaderOutput { lastModifiedTS?: string; meaningNames?: string[]; meanings?: Array; - status?: string; + status?: EntityStatusOutput; typeName?: string; } @@ -312,7 +309,7 @@ export interface AtlasEntityOutput { provenanceType?: number; proxy?: boolean; relationshipAttributes?: Record; - status?: string; + status?: EntityStatusOutput; typeName?: string; updatedBy?: string; updateTime?: number; @@ -333,7 +330,7 @@ export interface AtlasEntityWithExtInfoOutput { // @public export interface AtlasEnumDef { - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -353,7 +350,7 @@ export interface AtlasEnumDef { // @public export interface AtlasEnumDefOutput { - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -532,7 +529,7 @@ export interface AtlasGlossaryTerm { resources?: Array; seeAlso?: Array; shortDescription?: string; - status?: string; + status?: TermStatus; synonyms?: Array; templateName?: unknown[]; translatedTerms?: Array; @@ -573,7 +570,7 @@ export interface AtlasGlossaryTermOutput { resources?: Array; seeAlso?: Array; shortDescription?: string; - status?: string; + status?: TermStatusOutput; synonyms?: Array; templateName?: any[]; translatedTerms?: Array; @@ -591,7 +588,7 @@ export interface AtlasLineageInfoOutput { childrenCount?: number; guidEntityMap?: Record; lineageDepth?: number; - lineageDirection?: string; + lineageDirection?: LineageDirectionOutput; lineageWidth?: number; parentRelations?: Array; relations?: Array; @@ -633,11 +630,11 @@ export interface AtlasRelatedCategoryHeaderOutput { // @public export interface AtlasRelatedObjectId { displayText?: string; - entityStatus?: string; + entityStatus?: EntityStatus; guid?: string; relationshipAttributes?: AtlasStruct; relationshipGuid?: string; - relationshipStatus?: string; + relationshipStatus?: StatusAtlasRelationship; relationshipType?: string; typeName?: string; uniqueAttributes?: Record; @@ -646,11 +643,11 @@ export interface AtlasRelatedObjectId { // @public export interface AtlasRelatedObjectIdOutput { displayText?: string; - entityStatus?: string; + entityStatus?: EntityStatusOutput; guid?: string; relationshipAttributes?: AtlasStructOutput; relationshipGuid?: string; - relationshipStatus?: string; + relationshipStatus?: StatusAtlasRelationshipOutput; relationshipType?: string; typeName?: string; uniqueAttributes?: Record; @@ -662,7 +659,7 @@ export interface AtlasRelatedTermHeader { displayText?: string; expression?: string; relationGuid?: string; - status?: string; + status?: AtlasTermRelationshipStatus; steward?: string; termGuid?: string; } @@ -673,7 +670,7 @@ export interface AtlasRelatedTermHeaderOutput { displayText?: string; expression?: string; relationGuid?: string; - status?: string; + status?: AtlasTermRelationshipStatusOutput; steward?: string; termGuid?: string; } @@ -690,7 +687,7 @@ export interface AtlasRelationship { label?: string; lastModifiedTS?: string; provenanceType?: number; - status?: string; + status?: StatusAtlasRelationship; typeName?: string; updatedBy?: string; updateTime?: number; @@ -699,7 +696,7 @@ export interface AtlasRelationship { // @public export interface AtlasRelationshipAttributeDef { - cardinality?: string; + cardinality?: CardinalityValue; constraints?: Array; defaultValue?: string; description?: string; @@ -718,7 +715,7 @@ export interface AtlasRelationshipAttributeDef { // @public export interface AtlasRelationshipAttributeDefOutput { - cardinality?: string; + cardinality?: CardinalityValueOutput; constraints?: Array; defaultValue?: string; description?: string; @@ -738,7 +735,7 @@ export interface AtlasRelationshipAttributeDefOutput { // @public export interface AtlasRelationshipDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -749,7 +746,7 @@ export interface AtlasRelationshipDef { lastModifiedTS?: string; name?: string; options?: Record; - relationshipCategory?: string; + relationshipCategory?: RelationshipCategory; relationshipLabel?: string; serviceType?: string; typeVersion?: string; @@ -761,7 +758,7 @@ export interface AtlasRelationshipDef { // @public export interface AtlasRelationshipDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -772,7 +769,7 @@ export interface AtlasRelationshipDefOutput { lastModifiedTS?: string; name?: string; options?: Record; - relationshipCategory?: string; + relationshipCategory?: RelationshipCategoryOutput; relationshipLabel?: string; serviceType?: string; typeVersion?: string; @@ -783,7 +780,7 @@ export interface AtlasRelationshipDefOutput { // @public export interface AtlasRelationshipEndDef { - cardinality?: string; + cardinality?: CardinalityValue; description?: string; isContainer?: boolean; isLegacyAttribute?: boolean; @@ -793,7 +790,7 @@ export interface AtlasRelationshipEndDef { // @public export interface AtlasRelationshipEndDefOutput { - cardinality?: string; + cardinality?: CardinalityValueOutput; description?: string; isContainer?: boolean; isLegacyAttribute?: boolean; @@ -813,7 +810,7 @@ export interface AtlasRelationshipOutput { label?: string; lastModifiedTS?: string; provenanceType?: number; - status?: string; + status?: StatusAtlasRelationshipOutput; typeName?: string; updatedBy?: string; updateTime?: number; @@ -836,7 +833,7 @@ export interface AtlasStruct { // @public export interface AtlasStructDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -855,7 +852,7 @@ export interface AtlasStructDef { // @public export interface AtlasStructDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -886,7 +883,7 @@ export interface AtlasTermAssignmentHeader { displayText?: string; expression?: string; relationGuid?: string; - status?: string; + status?: AtlasTermAssignmentStatus; steward?: string; termGuid?: string; } @@ -899,18 +896,24 @@ export interface AtlasTermAssignmentHeaderOutput { displayText?: string; expression?: string; relationGuid?: string; - status?: string; + status?: AtlasTermAssignmentStatusOutput; steward?: string; termGuid?: string; } +// @public +export type AtlasTermAssignmentStatus = string; + +// @public +export type AtlasTermAssignmentStatusOutput = string; + // @public export interface AtlasTermCategorizationHeader { categoryGuid?: string; description?: string; displayText?: string; relationGuid?: string; - status?: string; + status?: AtlasTermRelationshipStatus; } // @public @@ -919,12 +922,18 @@ export interface AtlasTermCategorizationHeaderOutput { description?: string; displayText?: string; relationGuid?: string; - status?: string; + status?: AtlasTermRelationshipStatusOutput; } +// @public +export type AtlasTermRelationshipStatus = string; + +// @public +export type AtlasTermRelationshipStatusOutput = string; + // @public export interface AtlasTypeDefHeaderOutput { - category?: string; + category?: TypeCategoryOutput; guid?: string; name?: string; } @@ -932,7 +941,7 @@ export interface AtlasTypeDefHeaderOutput { // @public export interface AtlasTypeDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -947,7 +956,7 @@ export interface AtlasTypeDefOutput { name?: string; options?: Record; relationshipAttributeDefs?: Array; - relationshipCategory?: string; + relationshipCategory?: RelationshipCategoryOutput; relationshipLabel?: string; serviceType?: string; subTypes?: string[]; @@ -1008,15 +1017,29 @@ export interface BulkImportResultOutput { } // @public -export interface BusinessMetadataOptions { - file: string | Uint8Array | ReadableStream | NodeJS.ReadableStream | File; -} +export type BusinessAttributeUpdateBehavior = string; // @public -export interface BusinessMetadataOptionsOutput { - file: Uint8Array; +export type BusinessMetadataOptions = FormData | Array; + +// @public (undocumented) +export interface BusinessMetadataOptionsFilePartDescriptor { + // (undocumented) + body: string | Uint8Array | ReadableStream | NodeJS.ReadableStream | File; + // (undocumented) + contentType?: string; + // (undocumented) + filename?: string; + // (undocumented) + name: "file"; } +// @public +export type CardinalityValue = string; + +// @public +export type CardinalityValueOutput = string; + // @public export interface ClassificationAssociateOptions { classification?: AtlasClassification; @@ -1043,17 +1066,9 @@ export interface ContactSearchResultValueOutput { } // @public -function createClient(endpoint: string, credentials: TokenCredential, options?: ClientOptions): PurviewDataMapClient; +function createClient(endpointParam: string, credentials: TokenCredential, options?: PurviewDataMapClientOptions): PurviewDataMapClient; export default createClient; -export { createFile } - -export { createFileFromStream } - -export { CreateFileFromStreamOptions } - -export { CreateFileOptions } - // @public export interface DateFormat { availableLocales?: string[]; @@ -1082,7 +1097,7 @@ export interface DateFormatOutput { // @public (undocumented) export interface DiscoveryAutoComplete { - post(options?: DiscoveryAutoCompleteParameters): StreamableMethod; + post(options: DiscoveryAutoCompleteParameters): StreamableMethod; } // @public @@ -1095,8 +1110,7 @@ export interface DiscoveryAutoComplete200Response extends HttpResponse { // @public (undocumented) export interface DiscoveryAutoCompleteBodyParam { - // (undocumented) - body?: AutoCompleteOptions; + body: AutoCompleteOptions; } // @public (undocumented) @@ -1108,11 +1122,22 @@ export interface DiscoveryAutoCompleteDefaultResponse extends HttpResponse { } // @public (undocumented) -export type DiscoveryAutoCompleteParameters = DiscoveryAutoCompleteBodyParam & RequestParameters; +export type DiscoveryAutoCompleteParameters = DiscoveryAutoCompleteQueryParam & DiscoveryAutoCompleteBodyParam & RequestParameters; + +// @public (undocumented) +export interface DiscoveryAutoCompleteQueryParam { + // (undocumented) + queryParameters: DiscoveryAutoCompleteQueryParamProperties; +} + +// @public (undocumented) +export interface DiscoveryAutoCompleteQueryParamProperties { + "api-version": string; +} // @public (undocumented) export interface DiscoveryQuery { - post(options?: DiscoveryQueryParameters): StreamableMethod; + post(options: DiscoveryQueryParameters): StreamableMethod; } // @public @@ -1125,8 +1150,7 @@ export interface DiscoveryQuery200Response extends HttpResponse { // @public (undocumented) export interface DiscoveryQueryBodyParam { - // (undocumented) - body?: QueryOptions; + body: QueryOptions; } // @public (undocumented) @@ -1138,11 +1162,22 @@ export interface DiscoveryQueryDefaultResponse extends HttpResponse { } // @public (undocumented) -export type DiscoveryQueryParameters = DiscoveryQueryBodyParam & RequestParameters; +export type DiscoveryQueryParameters = DiscoveryQueryQueryParam & DiscoveryQueryBodyParam & RequestParameters; + +// @public (undocumented) +export interface DiscoveryQueryQueryParam { + // (undocumented) + queryParameters: DiscoveryQueryQueryParamProperties; +} + +// @public (undocumented) +export interface DiscoveryQueryQueryParamProperties { + "api-version": string; +} // @public (undocumented) export interface DiscoverySuggest { - post(options?: DiscoverySuggestParameters): StreamableMethod; + post(options: DiscoverySuggestParameters): StreamableMethod; } // @public @@ -1155,8 +1190,7 @@ export interface DiscoverySuggest200Response extends HttpResponse { // @public (undocumented) export interface DiscoverySuggestBodyParam { - // (undocumented) - body?: SuggestOptions; + body: SuggestOptions; } // @public (undocumented) @@ -1168,11 +1202,22 @@ export interface DiscoverySuggestDefaultResponse extends HttpResponse { } // @public (undocumented) -export type DiscoverySuggestParameters = DiscoverySuggestBodyParam & RequestParameters; +export type DiscoverySuggestParameters = DiscoverySuggestQueryParam & DiscoverySuggestBodyParam & RequestParameters; + +// @public (undocumented) +export interface DiscoverySuggestQueryParam { + // (undocumented) + queryParameters: DiscoverySuggestQueryParamProperties; +} + +// @public (undocumented) +export interface DiscoverySuggestQueryParamProperties { + "api-version": string; +} // @public (undocumented) export interface EntityAddClassification { - post(options?: EntityAddClassificationParameters): StreamableMethod; + post(options: EntityAddClassificationParameters): StreamableMethod; } // @public @@ -1183,8 +1228,7 @@ export interface EntityAddClassification204Response extends HttpResponse { // @public (undocumented) export interface EntityAddClassificationBodyParam { - // (undocumented) - body?: ClassificationAssociateOptions; + body: ClassificationAssociateOptions; } // @public (undocumented) @@ -1379,8 +1423,7 @@ export interface EntityBulkCreateOrUpdate200Response extends HttpResponse { // @public (undocumented) export interface EntityBulkCreateOrUpdateBodyParam { - // (undocumented) - body?: AtlasEntitiesWithExtInfo; + body: AtlasEntitiesWithExtInfo; } // @public (undocumented) @@ -1402,7 +1445,8 @@ export interface EntityBulkCreateOrUpdateQueryParam { // @public (undocumented) export interface EntityBulkCreateOrUpdateQueryParamProperties { - businessAttributeUpdateBehavior?: string; + "api-version"?: string; + businessAttributeUpdateBehavior?: BusinessAttributeUpdateBehavior; collectionId?: string; } @@ -1438,7 +1482,7 @@ export interface EntityBulkDeleteQueryParamProperties { // @public (undocumented) export interface EntityBulkSetClassifications { - post(options?: EntityBulkSetClassificationsParameters): StreamableMethod; + post(options: EntityBulkSetClassificationsParameters): StreamableMethod; } // @public @@ -1451,8 +1495,7 @@ export interface EntityBulkSetClassifications200Response extends HttpResponse { // @public (undocumented) export interface EntityBulkSetClassificationsBodyParam { - // (undocumented) - body?: AtlasEntityHeaders; + body: AtlasEntityHeaders; } // @public (undocumented) @@ -1468,7 +1511,7 @@ export type EntityBulkSetClassificationsParameters = EntityBulkSetClassification // @public (undocumented) export interface EntityCreateOrUpdate { - post(options?: EntityCreateOrUpdateParameters): StreamableMethod; + post(options: EntityCreateOrUpdateParameters): StreamableMethod; } // @public @@ -1481,8 +1524,7 @@ export interface EntityCreateOrUpdate200Response extends HttpResponse { // @public (undocumented) export interface EntityCreateOrUpdateBodyParam { - // (undocumented) - body?: AtlasEntityWithExtInfo; + body: AtlasEntityWithExtInfo; } // @public (undocumented) @@ -1504,10 +1546,19 @@ export interface EntityCreateOrUpdateQueryParam { // @public (undocumented) export interface EntityCreateOrUpdateQueryParamProperties { - businessAttributeUpdateBehavior?: string; + "api-version"?: string; + businessAttributeUpdateBehavior?: BusinessAttributeUpdateBehavior; collectionId?: string; } +// @public +export interface EntityDelete200Response extends HttpResponse { + // (undocumented) + body: EntityMutationResultOutput; + // (undocumented) + status: "200"; +} + // @public export interface EntityDeleteByUniqueAttribute200Response extends HttpResponse { // (undocumented) @@ -1538,16 +1589,8 @@ export interface EntityDeleteByUniqueAttributeQueryParamProperties { "attr:qualifiedName"?: string; } -// @public -export interface EntityDeleteOperation200Response extends HttpResponse { - // (undocumented) - body: EntityMutationResultOutput; - // (undocumented) - status: "200"; -} - // @public (undocumented) -export interface EntityDeleteOperationDefaultResponse extends HttpResponse { +export interface EntityDeleteDefaultResponse extends HttpResponse { // (undocumented) body: AtlasErrorResponseOutput; // (undocumented) @@ -1559,7 +1602,7 @@ export type EntityDeleteParameters = RequestParameters; // @public (undocumented) export interface EntityGet { - delete(options?: EntityDeleteParameters): StreamableMethod; + delete(options?: EntityDeleteParameters): StreamableMethod; get(options?: EntityGetParameters): StreamableMethod; put(options: EntityPartialUpdateAttributeByGuidParameters): StreamableMethod; } @@ -1576,7 +1619,7 @@ export interface EntityGet200Response extends HttpResponse { export interface EntityGetByUniqueAttributes { delete(options?: EntityDeleteByUniqueAttributeParameters): StreamableMethod; get(options?: EntityGetByUniqueAttributesParameters): StreamableMethod; - put(options?: EntityPartialUpdateByUniqueAttributesParameters): StreamableMethod; + put(options: EntityPartialUpdateByUniqueAttributesParameters): StreamableMethod; } // @public @@ -1714,10 +1757,18 @@ export interface EntityGetSampleBusinessMetadataTemplate { get(options?: EntityGetSampleBusinessMetadataTemplateParameters): StreamableMethod; } +// @public (undocumented) +export interface EntityGetSampleBusinessMetadataTemplate200Headers { + // (undocumented) + "content-type": "application/octet-stream"; +} + // @public export interface EntityGetSampleBusinessMetadataTemplate200Response extends HttpResponse { body: Uint8Array; // (undocumented) + headers: RawHttpHeaders & EntityGetSampleBusinessMetadataTemplate200Headers; + // (undocumented) status: "200"; } @@ -1747,8 +1798,7 @@ export interface EntityImportBusinessMetadata200Response extends HttpResponse { // @public (undocumented) export interface EntityImportBusinessMetadataBodyParam { - // (undocumented) - body?: BusinessMetadataOptions; + body: BusinessMetadataOptions; } // @public (undocumented) @@ -1771,7 +1821,7 @@ export type EntityImportBusinessMetadataParameters = EntityImportBusinessMetadat export interface EntityListByGuids { delete(options: EntityBulkDeleteParameters): StreamableMethod; get(options: EntityListByGuidsParameters): StreamableMethod; - post(options?: EntityBulkCreateOrUpdateParameters): StreamableMethod; + post(options: EntityBulkCreateOrUpdateParameters): StreamableMethod; } // @public @@ -1801,6 +1851,7 @@ export interface EntityListByGuidsQueryParam { // @public (undocumented) export interface EntityListByGuidsQueryParamProperties { + "api-version"?: string; guid: string; ignoreRelationships?: boolean; minExtInfo?: boolean; @@ -1858,8 +1909,7 @@ export interface EntityMoveEntitiesToCollection200Response extends HttpResponse // @public (undocumented) export interface EntityMoveEntitiesToCollectionBodyParam { - // (undocumented) - body?: MoveEntitiesOptions; + body: MoveEntitiesOptions; } // @public (undocumented) @@ -1881,6 +1931,7 @@ export interface EntityMoveEntitiesToCollectionQueryParam { // @public (undocumented) export interface EntityMoveEntitiesToCollectionQueryParamProperties { + "api-version": string; collectionId: string; } @@ -1936,8 +1987,7 @@ export interface EntityPartialUpdateByUniqueAttributes200Response extends HttpRe // @public (undocumented) export interface EntityPartialUpdateByUniqueAttributesBodyParam { - // (undocumented) - body?: AtlasEntityWithExtInfo; + body: AtlasEntityWithExtInfo; } // @public (undocumented) @@ -2192,6 +2242,12 @@ export interface EntitySetLabelsDefaultResponse extends HttpResponse { // @public (undocumented) export type EntitySetLabelsParameters = EntitySetLabelsBodyParam & RequestParameters; +// @public +export type EntityStatus = string; + +// @public +export type EntityStatusOutput = string; + // @public export interface EntityUpdateClassifications204Response extends HttpResponse { // (undocumented) @@ -2279,8 +2335,7 @@ export interface GlossaryCreate200Response extends HttpResponse { // @public (undocumented) export interface GlossaryCreateBodyParam { - // (undocumented) - body?: AtlasGlossary; + body: AtlasGlossary; } // @public (undocumented) @@ -2314,7 +2369,7 @@ export type GlossaryCreateCategoriesParameters = GlossaryCreateCategoriesBodyPar // @public (undocumented) export interface GlossaryCreateCategory { - post(options?: GlossaryCreateCategoryParameters): StreamableMethod; + post(options: GlossaryCreateCategoryParameters): StreamableMethod; } // @public @@ -2327,8 +2382,7 @@ export interface GlossaryCreateCategory200Response extends HttpResponse { // @public (undocumented) export interface GlossaryCreateCategoryBodyParam { - // (undocumented) - body?: AtlasGlossaryCategory; + body: AtlasGlossaryCategory; } // @public (undocumented) @@ -2355,7 +2409,7 @@ export type GlossaryCreateParameters = GlossaryCreateBodyParam & RequestParamete // @public (undocumented) export interface GlossaryCreateTerm { - post(options?: GlossaryCreateTermParameters): StreamableMethod; + post(options: GlossaryCreateTermParameters): StreamableMethod; } // @public @@ -2368,8 +2422,7 @@ export interface GlossaryCreateTerm200Response extends HttpResponse { // @public (undocumented) export interface GlossaryCreateTermBodyParam { - // (undocumented) - body?: AtlasGlossaryTerm; + body: AtlasGlossaryTerm; } // @public (undocumented) @@ -2431,9 +2484,16 @@ export interface GlossaryCreateTermsQueryParam { // @public (undocumented) export interface GlossaryCreateTermsQueryParamProperties { + "api-version"?: string; includeTermHierarchy?: boolean; } +// @public +export interface GlossaryDelete204Response extends HttpResponse { + // (undocumented) + status: "204"; +} + // @public export interface GlossaryDeleteCategory204Response extends HttpResponse { // (undocumented) @@ -2451,14 +2511,8 @@ export interface GlossaryDeleteCategoryDefaultResponse extends HttpResponse { // @public (undocumented) export type GlossaryDeleteCategoryParameters = RequestParameters; -// @public -export interface GlossaryDeleteOperation204Response extends HttpResponse { - // (undocumented) - status: "204"; -} - // @public (undocumented) -export interface GlossaryDeleteOperationDefaultResponse extends HttpResponse { +export interface GlossaryDeleteDefaultResponse extends HttpResponse { // (undocumented) body: AtlasErrorResponseOutput; // (undocumented) @@ -2509,9 +2563,9 @@ export type GlossaryDeleteTermParameters = RequestParameters; // @public (undocumented) export interface GlossaryGet { - delete(options?: GlossaryDeleteParameters): StreamableMethod; + delete(options?: GlossaryDeleteParameters): StreamableMethod; get(options?: GlossaryGetParameters): StreamableMethod; - put(options?: GlossaryUpdateParameters): StreamableMethod; + put(options: GlossaryUpdateParameters): StreamableMethod; } // @public @@ -2526,7 +2580,7 @@ export interface GlossaryGet200Response extends HttpResponse { export interface GlossaryGetCategory { delete(options?: GlossaryDeleteCategoryParameters): StreamableMethod; get(options?: GlossaryGetCategoryParameters): StreamableMethod; - put(options?: GlossaryUpdateCategoryParameters): StreamableMethod; + put(options: GlossaryUpdateCategoryParameters): StreamableMethod; } // @public @@ -2578,7 +2632,18 @@ export interface GlossaryGetDetailedDefaultResponse extends HttpResponse { } // @public (undocumented) -export type GlossaryGetDetailedParameters = RequestParameters; +export type GlossaryGetDetailedParameters = GlossaryGetDetailedQueryParam & RequestParameters; + +// @public (undocumented) +export interface GlossaryGetDetailedQueryParam { + // (undocumented) + queryParameters?: GlossaryGetDetailedQueryParamProperties; +} + +// @public (undocumented) +export interface GlossaryGetDetailedQueryParamProperties { + "api-version"?: string; +} // @public (undocumented) export type GlossaryGetParameters = RequestParameters; @@ -2587,7 +2652,7 @@ export type GlossaryGetParameters = RequestParameters; export interface GlossaryGetTerm { delete(options?: GlossaryDeleteTermParameters): StreamableMethod; get(options?: GlossaryGetTermParameters): StreamableMethod; - put(options?: GlossaryUpdateTermParameters): StreamableMethod; + put(options: GlossaryUpdateTermParameters): StreamableMethod; } // @public @@ -2607,12 +2672,23 @@ export interface GlossaryGetTermDefaultResponse extends HttpResponse { } // @public (undocumented) -export type GlossaryGetTermParameters = RequestParameters; +export type GlossaryGetTermParameters = GlossaryGetTermQueryParam & RequestParameters; + +// @public (undocumented) +export interface GlossaryGetTermQueryParam { + // (undocumented) + queryParameters?: GlossaryGetTermQueryParamProperties; +} + +// @public (undocumented) +export interface GlossaryGetTermQueryParamProperties { + "api-version"?: string; +} // @public (undocumented) export interface GlossaryList { get(options?: GlossaryListParameters): StreamableMethod; - post(options?: GlossaryCreateParameters): StreamableMethod; + post(options: GlossaryCreateParameters): StreamableMethod; } // @public @@ -2792,6 +2868,7 @@ export interface GlossaryListQueryParam { // @public (undocumented) export interface GlossaryListQueryParamProperties { + "api-version"?: string; ignoreTermsAndCategories?: boolean; limit?: number; offset?: number; @@ -2867,6 +2944,7 @@ export interface GlossaryListRelatedTermsQueryParam { // @public (undocumented) export interface GlossaryListRelatedTermsQueryParamProperties { + "api-version"?: string; limit?: number; offset?: number; sort?: string; @@ -2941,6 +3019,7 @@ export interface GlossaryListTermsQueryParam { // @public (undocumented) export interface GlossaryListTermsQueryParamProperties { + "api-version"?: string; limit?: number; offset?: number; sort?: string; @@ -3012,6 +3091,7 @@ export interface GlossaryPartialUpdateQueryParam { // @public (undocumented) export interface GlossaryPartialUpdateQueryParamProperties { + "api-version"?: string; ignoreTermsAndCategories?: boolean; } @@ -3052,6 +3132,7 @@ export interface GlossaryPartialUpdateTermQueryParam { // @public (undocumented) export interface GlossaryPartialUpdateTermQueryParamProperties { + "api-version"?: string; includeTermHierarchy?: boolean; } @@ -3065,8 +3146,7 @@ export interface GlossaryUpdate200Response extends HttpResponse { // @public (undocumented) export interface GlossaryUpdateBodyParam { - // (undocumented) - body?: AtlasGlossary; + body: AtlasGlossary; } // @public @@ -3079,8 +3159,7 @@ export interface GlossaryUpdateCategory200Response extends HttpResponse { // @public (undocumented) export interface GlossaryUpdateCategoryBodyParam { - // (undocumented) - body?: AtlasGlossaryCategory; + body: AtlasGlossaryCategory; } // @public (undocumented) @@ -3113,6 +3192,7 @@ export interface GlossaryUpdateQueryParam { // @public (undocumented) export interface GlossaryUpdateQueryParamProperties { + "api-version"?: string; ignoreTermsAndCategories?: boolean; } @@ -3126,8 +3206,7 @@ export interface GlossaryUpdateTerm200Response extends HttpResponse { // @public (undocumented) export interface GlossaryUpdateTermBodyParam { - // (undocumented) - body?: AtlasGlossaryTerm; + body: AtlasGlossaryTerm; } // @public (undocumented) @@ -3149,17 +3228,21 @@ export interface GlossaryUpdateTermQueryParam { // @public (undocumented) export interface GlossaryUpdateTermQueryParamProperties { + "api-version"?: string; includeTermHierarchy?: boolean; } // @public export interface ImportInfoOutput { childObjectName?: string; - importStatus?: string; + importStatus?: ImportStatusOutput; parentObjectName?: string; remarks?: string; } +// @public +export type ImportStatusOutput = string; + // @public (undocumented) export function isUnexpected(response: EntityCreateOrUpdate200Response | EntityCreateOrUpdateDefaultResponse): response is EntityCreateOrUpdateDefaultResponse; @@ -3182,7 +3265,7 @@ export function isUnexpected(response: EntityGet200Response | EntityGetDefaultRe export function isUnexpected(response: EntityPartialUpdateAttributeByGuid200Response | EntityPartialUpdateAttributeByGuidDefaultResponse): response is EntityPartialUpdateAttributeByGuidDefaultResponse; // @public (undocumented) -export function isUnexpected(response: EntityDeleteOperation200Response | EntityDeleteOperationDefaultResponse): response is EntityDeleteOperationDefaultResponse; +export function isUnexpected(response: EntityDelete200Response | EntityDeleteDefaultResponse): response is EntityDeleteDefaultResponse; // @public (undocumented) export function isUnexpected(response: EntityGetClassification200Response | EntityGetClassificationDefaultResponse): response is EntityGetClassificationDefaultResponse; @@ -3332,7 +3415,7 @@ export function isUnexpected(response: GlossaryGet200Response | GlossaryGetDefau export function isUnexpected(response: GlossaryUpdate200Response | GlossaryUpdateDefaultResponse): response is GlossaryUpdateDefaultResponse; // @public (undocumented) -export function isUnexpected(response: GlossaryDeleteOperation204Response | GlossaryDeleteOperationDefaultResponse): response is GlossaryDeleteOperationDefaultResponse; +export function isUnexpected(response: GlossaryDelete204Response | GlossaryDeleteDefaultResponse): response is GlossaryDeleteDefaultResponse; // @public (undocumented) export function isUnexpected(response: GlossaryListCategories200Response | GlossaryListCategoriesDefaultResponse): response is GlossaryListCategoriesDefaultResponse; @@ -3380,7 +3463,7 @@ export function isUnexpected(response: RelationshipUpdate200Response | Relations export function isUnexpected(response: RelationshipGet200Response | RelationshipGetDefaultResponse): response is RelationshipGetDefaultResponse; // @public (undocumented) -export function isUnexpected(response: RelationshipDeleteOperation204Response | RelationshipDeleteOperationDefaultResponse): response is RelationshipDeleteOperationDefaultResponse; +export function isUnexpected(response: RelationshipDelete204Response | RelationshipDeleteDefaultResponse): response is RelationshipDeleteDefaultResponse; // @public (undocumented) export function isUnexpected(response: TypeGetBusinessMetadataDefByGuid200Response | TypeGetBusinessMetadataDefByGuidDefaultResponse): response is TypeGetBusinessMetadataDefByGuidDefaultResponse; @@ -3425,7 +3508,7 @@ export function isUnexpected(response: TypeGetByGuid200Response | TypeGetByGuidD export function isUnexpected(response: TypeGetByName200Response | TypeGetByNameDefaultResponse): response is TypeGetByNameDefaultResponse; // @public (undocumented) -export function isUnexpected(response: TypeDeleteOperation204Response | TypeDeleteOperationDefaultResponse): response is TypeDeleteOperationDefaultResponse; +export function isUnexpected(response: TypeDelete204Response | TypeDeleteDefaultResponse): response is TypeDeleteDefaultResponse; // @public (undocumented) export function isUnexpected(response: TypeList200Response | TypeListDefaultResponse): response is TypeListDefaultResponse; @@ -3448,6 +3531,12 @@ export function isUnexpected(response: TypeGetTermTemplateDefByGuid200Response | // @public (undocumented) export function isUnexpected(response: TypeGetTermTemplateDefByName200Response | TypeGetTermTemplateDefByNameDefaultResponse): response is TypeGetTermTemplateDefByNameDefaultResponse; +// @public +export type LineageDirection = string; + +// @public +export type LineageDirectionOutput = string; + // @public (undocumented) export interface LineageGet { get(options: LineageGetParameters): StreamableMethod; @@ -3495,7 +3584,7 @@ export interface LineageGetByUniqueAttributeQueryParam { export interface LineageGetByUniqueAttributeQueryParamProperties { "attr:qualifiedName"?: string; depth?: number; - direction: string; + direction: LineageDirection; } // @public (undocumented) @@ -3538,7 +3627,8 @@ export interface LineageGetNextPageQueryParam { // @public (undocumented) export interface LineageGetNextPageQueryParamProperties { - direction: string; + "api-version": string; + direction: LineageDirection; limit?: number; offset?: number; } @@ -3555,7 +3645,7 @@ export interface LineageGetQueryParam { // @public (undocumented) export interface LineageGetQueryParamProperties { depth?: number; - direction: string; + direction: LineageDirection; } // @public @@ -3585,7 +3675,7 @@ export interface NumberFormat { numberInstance?: NumberFormat; parseIntegerOnly?: boolean; percentInstance?: NumberFormat; - roundingMode?: string; + roundingMode?: RoundingMode; } // @public @@ -3603,7 +3693,7 @@ export interface NumberFormatOutput { numberInstance?: NumberFormatOutput; parseIntegerOnly?: boolean; percentInstance?: NumberFormatOutput; - roundingMode?: string; + roundingMode?: RoundingModeOutput; } // @public @@ -3618,6 +3708,10 @@ export type PurviewDataMapClient = Client & { path: Routes; }; +// @public +export interface PurviewDataMapClientOptions extends ClientOptions { +} + // @public export interface PurviewObjectId { displayText?: string; @@ -3655,17 +3749,23 @@ export interface QueryOptions { // @public export interface QueryResultOutput { + "@search.count"?: number; + "@search.count.approximate"?: boolean; + "@search.facets"?: SearchFacetResultValueOutput; continuationToken?: string; - searchCount?: number; - searchCountApproximate?: boolean; - searchFacets?: SearchFacetResultValueOutput; value?: Array; } +// @public +export type RelationshipCategory = string; + +// @public +export type RelationshipCategoryOutput = string; + // @public (undocumented) export interface RelationshipCreate { - post(options?: RelationshipCreateParameters): StreamableMethod; - put(options?: RelationshipUpdateParameters): StreamableMethod; + post(options: RelationshipCreateParameters): StreamableMethod; + put(options: RelationshipUpdateParameters): StreamableMethod; } // @public @@ -3678,8 +3778,7 @@ export interface RelationshipCreate200Response extends HttpResponse { // @public (undocumented) export interface RelationshipCreateBodyParam { - // (undocumented) - body?: AtlasRelationship; + body: AtlasRelationship; } // @public (undocumented) @@ -3694,13 +3793,13 @@ export interface RelationshipCreateDefaultResponse extends HttpResponse { export type RelationshipCreateParameters = RelationshipCreateBodyParam & RequestParameters; // @public -export interface RelationshipDeleteOperation204Response extends HttpResponse { +export interface RelationshipDelete204Response extends HttpResponse { // (undocumented) status: "204"; } // @public (undocumented) -export interface RelationshipDeleteOperationDefaultResponse extends HttpResponse { +export interface RelationshipDeleteDefaultResponse extends HttpResponse { // (undocumented) body: AtlasErrorResponseOutput; // (undocumented) @@ -3712,7 +3811,7 @@ export type RelationshipDeleteParameters = RequestParameters; // @public (undocumented) export interface RelationshipGet { - delete(options?: RelationshipDeleteParameters): StreamableMethod; + delete(options?: RelationshipDeleteParameters): StreamableMethod; get(options?: RelationshipGetParameters): StreamableMethod; } @@ -3756,8 +3855,7 @@ export interface RelationshipUpdate200Response extends HttpResponse { // @public (undocumented) export interface RelationshipUpdateBodyParam { - // (undocumented) - body?: AtlasRelationship; + body: AtlasRelationship; } // @public (undocumented) @@ -3783,6 +3881,12 @@ export interface ResourceLinkOutput { url?: string; } +// @public +export type RoundingMode = string; + +// @public +export type RoundingModeOutput = string; + // @public (undocumented) export interface Routes { (path: "/atlas/v2/entity"): EntityCreateOrUpdate; @@ -3881,8 +3985,8 @@ export interface SearchFacetResultValueOutput { // @public export interface SearchFacetSort { - count?: string; - value?: string; + count?: SearchSortOrder; + value?: SearchSortOrder; } // @public @@ -3896,6 +4000,8 @@ export interface SearchHighlightsOutput { // @public export interface SearchResultValueOutput { + "@search.highlights"?: SearchHighlightsOutput; + "@search.score"?: number; assetType?: string[]; classification?: string[]; contact?: Array; @@ -3912,20 +4018,30 @@ export interface SearchResultValueOutput { objectType?: string; owner?: string; qualifiedName?: string; - searchHighlights?: SearchHighlightsOutput; - searchScore?: number; term?: Array; termStatus?: string; termTemplate?: string[]; updateTime?: number; } +// @public +export type SearchSortOrder = string; + // @public export interface SearchTaxonomySetting { assetTypes?: string[]; facet?: SearchFacetItem; } +// @public +export type SortTypeOutput = string; + +// @public +export type StatusAtlasRelationship = string; + +// @public +export type StatusAtlasRelationshipOutput = string; + // @public export interface SuggestOptions { filter?: unknown; @@ -3940,6 +4056,8 @@ export interface SuggestResultOutput { // @public export interface SuggestResultValueOutput { + "@search.score"?: number; + "@search.text"?: string; assetType?: string[]; classification?: string[]; contact?: Array; @@ -3956,8 +4074,6 @@ export interface SuggestResultValueOutput { objectType?: string; owner?: string; qualifiedName?: string; - searchScore?: number; - searchText?: string; term?: Array; termStatus?: string; termTemplate?: string[]; @@ -3971,10 +4087,16 @@ export interface TermSearchResultValueOutput { name?: string; } +// @public +export type TermStatus = string; + +// @public +export type TermStatusOutput = string; + // @public export interface TermTemplateDef { attributeDefs?: Array; - category?: string; + category?: TypeCategory; createdBy?: string; createTime?: number; dateFormatter?: DateFormat; @@ -3993,7 +4115,7 @@ export interface TermTemplateDef { // @public export interface TermTemplateDefOutput { attributeDefs?: Array; - category?: string; + category?: TypeCategoryOutput; createdBy?: string; createTime?: number; dateFormatter?: DateFormatOutput; @@ -4053,8 +4175,7 @@ export interface TypeBulkCreate200Response extends HttpResponse { // @public (undocumented) export interface TypeBulkCreateBodyParam { - // (undocumented) - body?: AtlasTypesDef; + body: AtlasTypesDef; } // @public (undocumented) @@ -4076,8 +4197,7 @@ export interface TypeBulkDelete204Response extends HttpResponse { // @public (undocumented) export interface TypeBulkDeleteBodyParam { - // (undocumented) - body?: AtlasTypesDef; + body: AtlasTypesDef; } // @public (undocumented) @@ -4101,8 +4221,7 @@ export interface TypeBulkUpdate200Response extends HttpResponse { // @public (undocumented) export interface TypeBulkUpdateBodyParam { - // (undocumented) - body?: AtlasTypesDef; + body: AtlasTypesDef; } // @public (undocumented) @@ -4117,13 +4236,19 @@ export interface TypeBulkUpdateDefaultResponse extends HttpResponse { export type TypeBulkUpdateParameters = TypeBulkUpdateBodyParam & RequestParameters; // @public -export interface TypeDeleteOperation204Response extends HttpResponse { +export type TypeCategory = string; + +// @public +export type TypeCategoryOutput = string; + +// @public +export interface TypeDelete204Response extends HttpResponse { // (undocumented) status: "204"; } // @public (undocumented) -export interface TypeDeleteOperationDefaultResponse extends HttpResponse { +export interface TypeDeleteDefaultResponse extends HttpResponse { // (undocumented) body: AtlasErrorResponseOutput; // (undocumented) @@ -4207,7 +4332,7 @@ export type TypeGetByGuidParameters = RequestParameters; // @public (undocumented) export interface TypeGetByName { - delete(options?: TypeDeleteParameters): StreamableMethod; + delete(options?: TypeDeleteParameters): StreamableMethod; get(options?: TypeGetByNameParameters): StreamableMethod; } @@ -4492,7 +4617,18 @@ export interface TypeGetTermTemplateDefByGuidDefaultResponse extends HttpRespons } // @public (undocumented) -export type TypeGetTermTemplateDefByGuidParameters = RequestParameters; +export type TypeGetTermTemplateDefByGuidParameters = TypeGetTermTemplateDefByGuidQueryParam & RequestParameters; + +// @public (undocumented) +export interface TypeGetTermTemplateDefByGuidQueryParam { + // (undocumented) + queryParameters: TypeGetTermTemplateDefByGuidQueryParamProperties; +} + +// @public (undocumented) +export interface TypeGetTermTemplateDefByGuidQueryParamProperties { + "api-version": string; +} // @public (undocumented) export interface TypeGetTermTemplateDefByName { @@ -4516,14 +4652,25 @@ export interface TypeGetTermTemplateDefByNameDefaultResponse extends HttpRespons } // @public (undocumented) -export type TypeGetTermTemplateDefByNameParameters = RequestParameters; +export type TypeGetTermTemplateDefByNameParameters = TypeGetTermTemplateDefByNameQueryParam & RequestParameters; + +// @public (undocumented) +export interface TypeGetTermTemplateDefByNameQueryParam { + // (undocumented) + queryParameters: TypeGetTermTemplateDefByNameQueryParamProperties; +} + +// @public (undocumented) +export interface TypeGetTermTemplateDefByNameQueryParamProperties { + "api-version": string; +} // @public (undocumented) export interface TypeList { - delete(options?: TypeBulkDeleteParameters): StreamableMethod; + delete(options: TypeBulkDeleteParameters): StreamableMethod; get(options?: TypeListParameters): StreamableMethod; - post(options?: TypeBulkCreateParameters): StreamableMethod; - put(options?: TypeBulkUpdateParameters): StreamableMethod; + post(options: TypeBulkCreateParameters): StreamableMethod; + put(options: TypeBulkUpdateParameters): StreamableMethod; } // @public @@ -4574,8 +4721,9 @@ export interface TypeListHeadersQueryParam { // @public (undocumented) export interface TypeListHeadersQueryParamProperties { + "api-version"?: string; includeTermTemplate?: boolean; - type?: string; + type?: TypeCategory; } // @public (undocumented) @@ -4589,8 +4737,9 @@ export interface TypeListQueryParam { // @public (undocumented) export interface TypeListQueryParamProperties { + "api-version"?: string; includeTermTemplate?: boolean; - type?: string; + type?: TypeCategory; } // (No @packageDocumentation comment for this package) diff --git a/sdk/purview/purview-datamap-rest/src/clientDefinitions.ts b/sdk/purview/purview-datamap-rest/src/clientDefinitions.ts index c067378d52f3..f6ea5fd40b1d 100644 --- a/sdk/purview/purview-datamap-rest/src/clientDefinitions.ts +++ b/sdk/purview/purview-datamap-rest/src/clientDefinitions.ts @@ -98,7 +98,7 @@ import { TypeListHeadersParameters, TypeGetTermTemplateDefByGuidParameters, TypeGetTermTemplateDefByNameParameters, -} from "./parameters"; +} from "./parameters.js"; import { EntityCreateOrUpdate200Response, EntityCreateOrUpdateDefaultResponse, @@ -114,8 +114,8 @@ import { EntityGetDefaultResponse, EntityPartialUpdateAttributeByGuid200Response, EntityPartialUpdateAttributeByGuidDefaultResponse, - EntityDeleteOperation200Response, - EntityDeleteOperationDefaultResponse, + EntityDelete200Response, + EntityDeleteDefaultResponse, EntityGetClassification200Response, EntityGetClassificationDefaultResponse, EntityRemoveClassification204Response, @@ -214,8 +214,8 @@ import { GlossaryGetDefaultResponse, GlossaryUpdate200Response, GlossaryUpdateDefaultResponse, - GlossaryDeleteOperation204Response, - GlossaryDeleteOperationDefaultResponse, + GlossaryDelete204Response, + GlossaryDeleteDefaultResponse, GlossaryListCategories200Response, GlossaryListCategoriesDefaultResponse, GlossaryListCategoriesHeaders200Response, @@ -246,8 +246,8 @@ import { RelationshipUpdateDefaultResponse, RelationshipGet200Response, RelationshipGetDefaultResponse, - RelationshipDeleteOperation204Response, - RelationshipDeleteOperationDefaultResponse, + RelationshipDelete204Response, + RelationshipDeleteDefaultResponse, TypeGetBusinessMetadataDefByGuid200Response, TypeGetBusinessMetadataDefByGuidDefaultResponse, TypeGetBusinessMetadataDefByName200Response, @@ -276,8 +276,8 @@ import { TypeGetByGuidDefaultResponse, TypeGetByName200Response, TypeGetByNameDefaultResponse, - TypeDeleteOperation204Response, - TypeDeleteOperationDefaultResponse, + TypeDelete204Response, + TypeDeleteDefaultResponse, TypeList200Response, TypeListDefaultResponse, TypeBulkCreate200Response, @@ -292,7 +292,7 @@ import { TypeGetTermTemplateDefByGuidDefaultResponse, TypeGetTermTemplateDefByName200Response, TypeGetTermTemplateDefByNameDefaultResponse, -} from "./responses"; +} from "./responses.js"; import { Client, StreamableMethod } from "@azure-rest/core-client"; export interface EntityCreateOrUpdate { @@ -306,15 +306,19 @@ export interface EntityCreateOrUpdate { * For each contact type, the maximum number of contacts is 20. */ post( - options?: EntityCreateOrUpdateParameters, - ): StreamableMethod; + options: EntityCreateOrUpdateParameters, + ): StreamableMethod< + EntityCreateOrUpdate200Response | EntityCreateOrUpdateDefaultResponse + >; } export interface EntityListByGuids { /** List entities in bulk identified by its GUIDs. */ get( options: EntityListByGuidsParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityListByGuids200Response | EntityListByGuidsDefaultResponse + >; /** * Create or update entities in bulk. * Existing entity is matched using its unique @@ -326,9 +330,10 @@ export interface EntityListByGuids { * is 20. */ post( - options?: EntityBulkCreateOrUpdateParameters, + options: EntityBulkCreateOrUpdateParameters, ): StreamableMethod< - EntityBulkCreateOrUpdate200Response | EntityBulkCreateOrUpdateDefaultResponse + | EntityBulkCreateOrUpdate200Response + | EntityBulkCreateOrUpdateDefaultResponse >; /** * Delete a list of entities in bulk identified by their GUIDs or unique @@ -336,14 +341,18 @@ export interface EntityListByGuids { */ delete( options: EntityBulkDeleteParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityBulkDelete200Response | EntityBulkDeleteDefaultResponse + >; } export interface EntityAddClassification { /** Associate a classification to multiple entities in bulk. */ post( - options?: EntityAddClassificationParameters, - ): StreamableMethod; + options: EntityAddClassificationParameters, + ): StreamableMethod< + EntityAddClassification204Response | EntityAddClassificationDefaultResponse + >; } export interface EntityGet { @@ -367,19 +376,22 @@ export interface EntityGet { /** Delete an entity identified by its GUID. */ delete( options?: EntityDeleteParameters, - ): StreamableMethod; + ): StreamableMethod; } export interface EntityGetClassification { /** Get classification for a given entity represented by a GUID. */ get( options?: EntityGetClassificationParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityGetClassification200Response | EntityGetClassificationDefaultResponse + >; /** Delete a given classification from an existing entity represented by a GUID. */ delete( options?: EntityRemoveClassificationParameters, ): StreamableMethod< - EntityRemoveClassification204Response | EntityRemoveClassificationDefaultResponse + | EntityRemoveClassification204Response + | EntityRemoveClassificationDefaultResponse >; } @@ -388,19 +400,22 @@ export interface EntityGetClassifications { get( options?: EntityGetClassificationsParameters, ): StreamableMethod< - EntityGetClassifications200Response | EntityGetClassificationsDefaultResponse + | EntityGetClassifications200Response + | EntityGetClassificationsDefaultResponse >; /** Add classifications to an existing entity represented by a GUID. */ post( options: EntityAddClassificationsParameters, ): StreamableMethod< - EntityAddClassifications204Response | EntityAddClassificationsDefaultResponse + | EntityAddClassifications204Response + | EntityAddClassificationsDefaultResponse >; /** Update classifications to an existing entity represented by a guid. */ put( options: EntityUpdateClassificationsParameters, ): StreamableMethod< - EntityUpdateClassifications204Response | EntityUpdateClassificationsDefaultResponse + | EntityUpdateClassifications204Response + | EntityUpdateClassificationsDefaultResponse >; } @@ -424,7 +439,8 @@ export interface EntityGetByUniqueAttributes { get( options?: EntityGetByUniqueAttributesParameters, ): StreamableMethod< - EntityGetByUniqueAttributes200Response | EntityGetByUniqueAttributesDefaultResponse + | EntityGetByUniqueAttributes200Response + | EntityGetByUniqueAttributesDefaultResponse >; /** * Update entity partially - Allow a subset of attributes to be updated on an @@ -445,7 +461,7 @@ export interface EntityGetByUniqueAttributes { * /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. */ put( - options?: EntityPartialUpdateByUniqueAttributesParameters, + options: EntityPartialUpdateByUniqueAttributesParameters, ): StreamableMethod< | EntityPartialUpdateByUniqueAttributes200Response | EntityPartialUpdateByUniqueAttributesDefaultResponse @@ -467,7 +483,8 @@ export interface EntityGetByUniqueAttributes { delete( options?: EntityDeleteByUniqueAttributeParameters, ): StreamableMethod< - EntityDeleteByUniqueAttribute200Response | EntityDeleteByUniqueAttributeDefaultResponse + | EntityDeleteByUniqueAttribute200Response + | EntityDeleteByUniqueAttributeDefaultResponse >; } @@ -504,9 +521,10 @@ export interface EntityAddClassificationsByUniqueAttribute { export interface EntityBulkSetClassifications { /** Set classifications on entities in bulk. */ post( - options?: EntityBulkSetClassificationsParameters, + options: EntityBulkSetClassificationsParameters, ): StreamableMethod< - EntityBulkSetClassifications200Response | EntityBulkSetClassificationsDefaultResponse + | EntityBulkSetClassifications200Response + | EntityBulkSetClassificationsDefaultResponse >; } @@ -534,7 +552,8 @@ export interface EntityListByUniqueAttributes { get( options?: EntityListByUniqueAttributesParameters, ): StreamableMethod< - EntityListByUniqueAttributes200Response | EntityListByUniqueAttributesDefaultResponse + | EntityListByUniqueAttributes200Response + | EntityListByUniqueAttributesDefaultResponse >; } @@ -542,7 +561,9 @@ export interface EntityGetHeader { /** Get entity header given its GUID. */ get( options?: EntityGetHeaderParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityGetHeader200Response | EntityGetHeaderDefaultResponse + >; } export interface EntityRemoveBusinessMetadata { @@ -550,13 +571,15 @@ export interface EntityRemoveBusinessMetadata { delete( options: EntityRemoveBusinessMetadataParameters, ): StreamableMethod< - EntityRemoveBusinessMetadata204Response | EntityRemoveBusinessMetadataDefaultResponse + | EntityRemoveBusinessMetadata204Response + | EntityRemoveBusinessMetadataDefaultResponse >; /** Add business metadata to an entity. */ post( options: EntityAddOrUpdateBusinessMetadataParameters, ): StreamableMethod< - EntityAddOrUpdateBusinessMetadata204Response | EntityAddOrUpdateBusinessMetadataDefaultResponse + | EntityAddOrUpdateBusinessMetadata204Response + | EntityAddOrUpdateBusinessMetadataDefaultResponse >; } @@ -592,7 +615,8 @@ export interface EntityImportBusinessMetadata { post( options: EntityImportBusinessMetadataParameters, ): StreamableMethod< - EntityImportBusinessMetadata200Response | EntityImportBusinessMetadataDefaultResponse + | EntityImportBusinessMetadata200Response + | EntityImportBusinessMetadataDefaultResponse >; } @@ -600,15 +624,21 @@ export interface EntityRemoveLabels { /** Delete given labels to a given entity. */ delete( options?: EntityRemoveLabelsParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityRemoveLabels204Response | EntityRemoveLabelsDefaultResponse + >; /** Set labels to a given entity. */ post( options?: EntitySetLabelsParameters, - ): StreamableMethod; + ): StreamableMethod< + EntitySetLabels204Response | EntitySetLabelsDefaultResponse + >; /** Add given labels to a given entity. */ put( options?: EntityAddLabelParameters, - ): StreamableMethod; + ): StreamableMethod< + EntityAddLabel204Response | EntityAddLabelDefaultResponse + >; } export interface EntityRemoveLabelsByUniqueAttribute { @@ -653,7 +683,8 @@ export interface EntityRemoveLabelsByUniqueAttribute { post( options?: EntitySetLabelsByUniqueAttributeParameters, ): StreamableMethod< - EntitySetLabelsByUniqueAttribute204Response | EntitySetLabelsByUniqueAttributeDefaultResponse + | EntitySetLabelsByUniqueAttribute204Response + | EntitySetLabelsByUniqueAttributeDefaultResponse >; /** * Add given labels to a given entity identified by its type and unique @@ -675,7 +706,8 @@ export interface EntityRemoveLabelsByUniqueAttribute { put( options?: EntityAddLabelsByUniqueAttributeParameters, ): StreamableMethod< - EntityAddLabelsByUniqueAttribute204Response | EntityAddLabelsByUniqueAttributeDefaultResponse + | EntityAddLabelsByUniqueAttribute204Response + | EntityAddLabelsByUniqueAttributeDefaultResponse >; } @@ -684,7 +716,8 @@ export interface EntityMoveEntitiesToCollection { post( options: EntityMoveEntitiesToCollectionParameters, ): StreamableMethod< - EntityMoveEntitiesToCollection200Response | EntityMoveEntitiesToCollectionDefaultResponse + | EntityMoveEntitiesToCollection200Response + | EntityMoveEntitiesToCollectionDefaultResponse >; } @@ -692,20 +725,18 @@ export interface GlossaryList { /** * Get all glossaries. Recommend using limit/offset to get pagination result. * Recommend using 'ignoreTermsAndCategories=true' and fetch terms/categories - * separately using - * - * 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' - * and - * - * 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. + * separately using 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' + * and 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. */ get( options?: GlossaryListParameters, ): StreamableMethod; /** Create a glossary. */ post( - options?: GlossaryCreateParameters, - ): StreamableMethod; + options: GlossaryCreateParameters, + ): StreamableMethod< + GlossaryCreate200Response | GlossaryCreateDefaultResponse + >; } export interface GlossaryCreateCategories { @@ -713,30 +744,39 @@ export interface GlossaryCreateCategories { post( options: GlossaryCreateCategoriesParameters, ): StreamableMethod< - GlossaryCreateCategories200Response | GlossaryCreateCategoriesDefaultResponse + | GlossaryCreateCategories200Response + | GlossaryCreateCategoriesDefaultResponse >; } export interface GlossaryCreateCategory { /** Create a glossary category. */ post( - options?: GlossaryCreateCategoryParameters, - ): StreamableMethod; + options: GlossaryCreateCategoryParameters, + ): StreamableMethod< + GlossaryCreateCategory200Response | GlossaryCreateCategoryDefaultResponse + >; } export interface GlossaryGetCategory { /** Get specific glossary category by its GUID. */ get( options?: GlossaryGetCategoryParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryGetCategory200Response | GlossaryGetCategoryDefaultResponse + >; /** Update the given glossary category by its GUID. */ put( - options?: GlossaryUpdateCategoryParameters, - ): StreamableMethod; + options: GlossaryUpdateCategoryParameters, + ): StreamableMethod< + GlossaryUpdateCategory200Response | GlossaryUpdateCategoryDefaultResponse + >; /** Delete a glossary category. */ delete( options?: GlossaryDeleteCategoryParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryDeleteCategory204Response | GlossaryDeleteCategoryDefaultResponse + >; } export interface GlossaryPartialUpdateCategory { @@ -747,7 +787,8 @@ export interface GlossaryPartialUpdateCategory { put( options: GlossaryPartialUpdateCategoryParameters, ): StreamableMethod< - GlossaryPartialUpdateCategory200Response | GlossaryPartialUpdateCategoryDefaultResponse + | GlossaryPartialUpdateCategory200Response + | GlossaryPartialUpdateCategoryDefaultResponse >; } @@ -759,7 +800,8 @@ export interface GlossaryListRelatedCategories { get( options?: GlossaryListRelatedCategoriesParameters, ): StreamableMethod< - GlossaryListRelatedCategories200Response | GlossaryListRelatedCategoriesDefaultResponse + | GlossaryListRelatedCategories200Response + | GlossaryListRelatedCategoriesDefaultResponse >; } @@ -768,30 +810,39 @@ export interface GlossaryListCategoryTerms { get( options?: GlossaryListCategoryTermsParameters, ): StreamableMethod< - GlossaryListCategoryTerms200Response | GlossaryListCategoryTermsDefaultResponse + | GlossaryListCategoryTerms200Response + | GlossaryListCategoryTermsDefaultResponse >; } export interface GlossaryCreateTerm { /** Create a glossary term. */ post( - options?: GlossaryCreateTermParameters, - ): StreamableMethod; + options: GlossaryCreateTermParameters, + ): StreamableMethod< + GlossaryCreateTerm200Response | GlossaryCreateTermDefaultResponse + >; } export interface GlossaryGetTerm { /** Get a specific glossary term by its GUID. */ get( options?: GlossaryGetTermParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryGetTerm200Response | GlossaryGetTermDefaultResponse + >; /** Update the given glossary term by its GUID. */ put( - options?: GlossaryUpdateTermParameters, - ): StreamableMethod; + options: GlossaryUpdateTermParameters, + ): StreamableMethod< + GlossaryUpdateTerm200Response | GlossaryUpdateTermDefaultResponse + >; /** Delete a glossary term. */ delete( options?: GlossaryDeleteTermParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryDeleteTerm204Response | GlossaryDeleteTermDefaultResponse + >; } export interface GlossaryPartialUpdateTerm { @@ -802,7 +853,8 @@ export interface GlossaryPartialUpdateTerm { put( options: GlossaryPartialUpdateTermParameters, ): StreamableMethod< - GlossaryPartialUpdateTerm200Response | GlossaryPartialUpdateTermDefaultResponse + | GlossaryPartialUpdateTerm200Response + | GlossaryPartialUpdateTermDefaultResponse >; } @@ -810,7 +862,9 @@ export interface GlossaryCreateTerms { /** Create glossary terms in bulk. */ post( options: GlossaryCreateTermsParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryCreateTerms200Response | GlossaryCreateTermsDefaultResponse + >; } export interface GlossaryListEntitiesAssignedWithTerm { @@ -835,7 +889,8 @@ export interface GlossaryListEntitiesAssignedWithTerm { post( options: GlossaryAssignTermToEntitiesParameters, ): StreamableMethod< - GlossaryAssignTermToEntities204Response | GlossaryAssignTermToEntitiesDefaultResponse + | GlossaryAssignTermToEntities204Response + | GlossaryAssignTermToEntitiesDefaultResponse >; /** Delete the term assignment for the given list of related objects. */ delete( @@ -854,7 +909,8 @@ export interface GlossaryListRelatedTerms { get( options?: GlossaryListRelatedTermsParameters, ): StreamableMethod< - GlossaryListRelatedTerms200Response | GlossaryListRelatedTermsDefaultResponse + | GlossaryListRelatedTerms200Response + | GlossaryListRelatedTermsDefaultResponse >; } @@ -865,15 +921,19 @@ export interface GlossaryGet { ): StreamableMethod; /** Update the given glossary. */ put( - options?: GlossaryUpdateParameters, - ): StreamableMethod; + options: GlossaryUpdateParameters, + ): StreamableMethod< + GlossaryUpdate200Response | GlossaryUpdateDefaultResponse + >; /** * Delete a glossary. Will delete underlying terms/categories together. Recommend * separate delete terms and categories. */ delete( options?: GlossaryDeleteParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryDelete204Response | GlossaryDeleteDefaultResponse + >; } export interface GlossaryListCategories { @@ -883,7 +943,9 @@ export interface GlossaryListCategories { */ get( options?: GlossaryListCategoriesParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryListCategories200Response | GlossaryListCategoriesDefaultResponse + >; } export interface GlossaryListCategoriesHeaders { @@ -894,7 +956,8 @@ export interface GlossaryListCategoriesHeaders { get( options?: GlossaryListCategoriesHeadersParameters, ): StreamableMethod< - GlossaryListCategoriesHeaders200Response | GlossaryListCategoriesHeadersDefaultResponse + | GlossaryListCategoriesHeaders200Response + | GlossaryListCategoriesHeadersDefaultResponse >; } @@ -911,7 +974,9 @@ export interface GlossaryGetDetailed { */ get( options?: GlossaryGetDetailedParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryGetDetailed200Response | GlossaryGetDetailedDefaultResponse + >; } export interface GlossaryPartialUpdate { @@ -927,7 +992,9 @@ export interface GlossaryPartialUpdate { */ put( options: GlossaryPartialUpdateParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryPartialUpdate200Response | GlossaryPartialUpdateDefaultResponse + >; } export interface GlossaryListTerms { @@ -937,7 +1004,9 @@ export interface GlossaryListTerms { */ get( options?: GlossaryListTermsParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryListTerms200Response | GlossaryListTermsDefaultResponse + >; } export interface GlossaryListTermHeaders { @@ -947,28 +1016,36 @@ export interface GlossaryListTermHeaders { */ get( options?: GlossaryListTermHeadersParameters, - ): StreamableMethod; + ): StreamableMethod< + GlossaryListTermHeaders200Response | GlossaryListTermHeadersDefaultResponse + >; } export interface DiscoveryQuery { /** Get data using search. */ post( - options?: DiscoveryQueryParameters, - ): StreamableMethod; + options: DiscoveryQueryParameters, + ): StreamableMethod< + DiscoveryQuery200Response | DiscoveryQueryDefaultResponse + >; } export interface DiscoverySuggest { /** Get search suggestions by query criteria. */ post( - options?: DiscoverySuggestParameters, - ): StreamableMethod; + options: DiscoverySuggestParameters, + ): StreamableMethod< + DiscoverySuggest200Response | DiscoverySuggestDefaultResponse + >; } export interface DiscoveryAutoComplete { /** Get auto complete options. */ post( - options?: DiscoveryAutoCompleteParameters, - ): StreamableMethod; + options: DiscoveryAutoCompleteParameters, + ): StreamableMethod< + DiscoveryAutoComplete200Response | DiscoveryAutoCompleteDefaultResponse + >; } export interface LineageGet { @@ -982,7 +1059,9 @@ export interface LineageGetNextPage { /** Return immediate next page lineage info about entity with pagination */ get( options: LineageGetNextPageParameters, - ): StreamableMethod; + ): StreamableMethod< + LineageGetNextPage200Response | LineageGetNextPageDefaultResponse + >; } export interface LineageGetByUniqueAttribute { @@ -1007,31 +1086,38 @@ export interface LineageGetByUniqueAttribute { get( options: LineageGetByUniqueAttributeParameters, ): StreamableMethod< - LineageGetByUniqueAttribute200Response | LineageGetByUniqueAttributeDefaultResponse + | LineageGetByUniqueAttribute200Response + | LineageGetByUniqueAttributeDefaultResponse >; } export interface RelationshipCreate { /** Create a new relationship between entities. */ post( - options?: RelationshipCreateParameters, - ): StreamableMethod; + options: RelationshipCreateParameters, + ): StreamableMethod< + RelationshipCreate200Response | RelationshipCreateDefaultResponse + >; /** Update an existing relationship between entities. */ put( - options?: RelationshipUpdateParameters, - ): StreamableMethod; + options: RelationshipUpdateParameters, + ): StreamableMethod< + RelationshipUpdate200Response | RelationshipUpdateDefaultResponse + >; } export interface RelationshipGet { /** Get relationship information between entities by its GUID. */ get( options?: RelationshipGetParameters, - ): StreamableMethod; + ): StreamableMethod< + RelationshipGet200Response | RelationshipGetDefaultResponse + >; /** Delete a relationship between entities by its GUID. */ delete( options?: RelationshipDeleteParameters, ): StreamableMethod< - RelationshipDeleteOperation204Response | RelationshipDeleteOperationDefaultResponse + RelationshipDelete204Response | RelationshipDeleteDefaultResponse >; } @@ -1040,7 +1126,8 @@ export interface TypeGetBusinessMetadataDefByGuid { get( options?: TypeGetBusinessMetadataDefByGuidParameters, ): StreamableMethod< - TypeGetBusinessMetadataDefByGuid200Response | TypeGetBusinessMetadataDefByGuidDefaultResponse + | TypeGetBusinessMetadataDefByGuid200Response + | TypeGetBusinessMetadataDefByGuidDefaultResponse >; } @@ -1049,7 +1136,8 @@ export interface TypeGetBusinessMetadataDefByName { get( options?: TypeGetBusinessMetadataDefByNameParameters, ): StreamableMethod< - TypeGetBusinessMetadataDefByName200Response | TypeGetBusinessMetadataDefByNameDefaultResponse + | TypeGetBusinessMetadataDefByName200Response + | TypeGetBusinessMetadataDefByNameDefaultResponse >; } @@ -1058,7 +1146,8 @@ export interface TypeGetClassificationDefByGuid { get( options?: TypeGetClassificationDefByGuidParameters, ): StreamableMethod< - TypeGetClassificationDefByGuid200Response | TypeGetClassificationDefByGuidDefaultResponse + | TypeGetClassificationDefByGuid200Response + | TypeGetClassificationDefByGuidDefaultResponse >; } @@ -1067,7 +1156,8 @@ export interface TypeGetClassificationDefByName { get( options?: TypeGetClassificationDefByNameParameters, ): StreamableMethod< - TypeGetClassificationDefByName200Response | TypeGetClassificationDefByNameDefaultResponse + | TypeGetClassificationDefByName200Response + | TypeGetClassificationDefByNameDefaultResponse >; } @@ -1075,28 +1165,36 @@ export interface TypeGetEntityDefByGuid { /** Get the Entity definition for the given GUID. */ get( options?: TypeGetEntityDefByGuidParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetEntityDefByGuid200Response | TypeGetEntityDefByGuidDefaultResponse + >; } export interface TypeGetEntityDefByName { /** Get the entity definition by its name (unique). */ get( options?: TypeGetEntityDefByNameParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetEntityDefByName200Response | TypeGetEntityDefByNameDefaultResponse + >; } export interface TypeGetEnumDefByGuid { /** Get the enum definition for the given GUID. */ get( options?: TypeGetEnumDefByGuidParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetEnumDefByGuid200Response | TypeGetEnumDefByGuidDefaultResponse + >; } export interface TypeGetEnumDefByName { /** Get the enum definition by its name (unique). */ get( options?: TypeGetEnumDefByNameParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetEnumDefByName200Response | TypeGetEnumDefByNameDefaultResponse + >; } export interface TypeGetRelationshipDefByGuid { @@ -1104,7 +1202,8 @@ export interface TypeGetRelationshipDefByGuid { get( options?: TypeGetRelationshipDefByGuidParameters, ): StreamableMethod< - TypeGetRelationshipDefByGuid200Response | TypeGetRelationshipDefByGuidDefaultResponse + | TypeGetRelationshipDefByGuid200Response + | TypeGetRelationshipDefByGuidDefaultResponse >; } @@ -1113,7 +1212,8 @@ export interface TypeGetRelationshipDefByName { get( options?: TypeGetRelationshipDefByNameParameters, ): StreamableMethod< - TypeGetRelationshipDefByName200Response | TypeGetRelationshipDefByNameDefaultResponse + | TypeGetRelationshipDefByName200Response + | TypeGetRelationshipDefByNameDefaultResponse >; } @@ -1121,14 +1221,18 @@ export interface TypeGetStructDefByGuid { /** Get the struct definition for the given GUID. */ get( options?: TypeGetStructDefByGuidParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetStructDefByGuid200Response | TypeGetStructDefByGuidDefaultResponse + >; } export interface TypeGetStructDefByName { /** Get the struct definition by its name (unique). */ get( options?: TypeGetStructDefByNameParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeGetStructDefByName200Response | TypeGetStructDefByNameDefaultResponse + >; } export interface TypeGetByGuid { @@ -1146,7 +1250,7 @@ export interface TypeGetByName { /** Delete API for type identified by its name. */ delete( options?: TypeDeleteParameters, - ): StreamableMethod; + ): StreamableMethod; } export interface TypeList { @@ -1154,32 +1258,36 @@ export interface TypeList { get( options?: TypeListParameters, ): StreamableMethod; - /** - * Create all atlas type definitions in bulk, only new definitions will be - * created. - * Any changes to the existing definitions will be discarded. - */ + /** Create all atlas type definitions in bulk. Please avoid recreating existing types. */ post( - options?: TypeBulkCreateParameters, - ): StreamableMethod; + options: TypeBulkCreateParameters, + ): StreamableMethod< + TypeBulkCreate200Response | TypeBulkCreateDefaultResponse + >; /** * Update all types in bulk, changes detected in the type definitions would be * persisted. */ put( - options?: TypeBulkUpdateParameters, - ): StreamableMethod; + options: TypeBulkUpdateParameters, + ): StreamableMethod< + TypeBulkUpdate200Response | TypeBulkUpdateDefaultResponse + >; /** Delete API for all types in bulk. */ delete( - options?: TypeBulkDeleteParameters, - ): StreamableMethod; + options: TypeBulkDeleteParameters, + ): StreamableMethod< + TypeBulkDelete204Response | TypeBulkDeleteDefaultResponse + >; } export interface TypeListHeaders { /** List all type definitions returned as a list of minimal information header. */ get( options?: TypeListHeadersParameters, - ): StreamableMethod; + ): StreamableMethod< + TypeListHeaders200Response | TypeListHeadersDefaultResponse + >; } export interface TypeGetTermTemplateDefByGuid { @@ -1187,7 +1295,8 @@ export interface TypeGetTermTemplateDefByGuid { get( options?: TypeGetTermTemplateDefByGuidParameters, ): StreamableMethod< - TypeGetTermTemplateDefByGuid200Response | TypeGetTermTemplateDefByGuidDefaultResponse + | TypeGetTermTemplateDefByGuid200Response + | TypeGetTermTemplateDefByGuidDefaultResponse >; } @@ -1196,7 +1305,8 @@ export interface TypeGetTermTemplateDefByName { get( options?: TypeGetTermTemplateDefByNameParameters, ): StreamableMethod< - TypeGetTermTemplateDefByName200Response | TypeGetTermTemplateDefByNameDefaultResponse + | TypeGetTermTemplateDefByName200Response + | TypeGetTermTemplateDefByNameDefaultResponse >; } @@ -1216,7 +1326,10 @@ export interface Routes { classificationName: string, ): EntityGetClassification; /** Resource for '/atlas/v2/entity/guid/\{guid\}/classifications' has methods for the following verbs: get, post, put */ - (path: "/atlas/v2/entity/guid/{guid}/classifications", guid: string): EntityGetClassifications; + ( + path: "/atlas/v2/entity/guid/{guid}/classifications", + guid: string, + ): EntityGetClassifications; /** Resource for '/atlas/v2/entity/uniqueAttribute/type/\{typeName\}' has methods for the following verbs: get, put, delete */ ( path: "/atlas/v2/entity/uniqueAttribute/type/{typeName}", @@ -1234,7 +1347,9 @@ export interface Routes { typeName: string, ): EntityAddClassificationsByUniqueAttribute; /** Resource for '/atlas/v2/entity/bulk/setClassifications' has methods for the following verbs: post */ - (path: "/atlas/v2/entity/bulk/setClassifications"): EntityBulkSetClassifications; + ( + path: "/atlas/v2/entity/bulk/setClassifications", + ): EntityBulkSetClassifications; /** Resource for '/atlas/v2/entity/bulk/uniqueAttribute/type/\{typeName\}' has methods for the following verbs: get */ ( path: "/atlas/v2/entity/bulk/uniqueAttribute/type/{typeName}", @@ -1258,9 +1373,14 @@ export interface Routes { path: "/atlas/v2/entity/businessmetadata/import/template", ): EntityGetSampleBusinessMetadataTemplate; /** Resource for '/atlas/v2/entity/businessmetadata/import' has methods for the following verbs: post */ - (path: "/atlas/v2/entity/businessmetadata/import"): EntityImportBusinessMetadata; + ( + path: "/atlas/v2/entity/businessmetadata/import", + ): EntityImportBusinessMetadata; /** Resource for '/atlas/v2/entity/guid/\{guid\}/labels' has methods for the following verbs: delete, post, put */ - (path: "/atlas/v2/entity/guid/{guid}/labels", guid: string): EntityRemoveLabels; + ( + path: "/atlas/v2/entity/guid/{guid}/labels", + guid: string, + ): EntityRemoveLabels; /** Resource for '/atlas/v2/entity/uniqueAttribute/type/\{typeName\}/labels' has methods for the following verbs: delete, post, put */ ( path: "/atlas/v2/entity/uniqueAttribute/type/{typeName}/labels", @@ -1275,7 +1395,10 @@ export interface Routes { /** Resource for '/atlas/v2/glossary/category' has methods for the following verbs: post */ (path: "/atlas/v2/glossary/category"): GlossaryCreateCategory; /** Resource for '/atlas/v2/glossary/category/\{categoryId\}' has methods for the following verbs: get, put, delete */ - (path: "/atlas/v2/glossary/category/{categoryId}", categoryId: string): GlossaryGetCategory; + ( + path: "/atlas/v2/glossary/category/{categoryId}", + categoryId: string, + ): GlossaryGetCategory; /** Resource for '/atlas/v2/glossary/category/\{categoryId\}/partial' has methods for the following verbs: put */ ( path: "/atlas/v2/glossary/category/{categoryId}/partial", @@ -1296,7 +1419,10 @@ export interface Routes { /** Resource for '/atlas/v2/glossary/term/\{termId\}' has methods for the following verbs: get, put, delete */ (path: "/atlas/v2/glossary/term/{termId}", termId: string): GlossaryGetTerm; /** Resource for '/atlas/v2/glossary/term/\{termId\}/partial' has methods for the following verbs: put */ - (path: "/atlas/v2/glossary/term/{termId}/partial", termId: string): GlossaryPartialUpdateTerm; + ( + path: "/atlas/v2/glossary/term/{termId}/partial", + termId: string, + ): GlossaryPartialUpdateTerm; /** Resource for '/atlas/v2/glossary/terms' has methods for the following verbs: post */ (path: "/atlas/v2/glossary/terms"): GlossaryCreateTerms; /** Resource for '/atlas/v2/glossary/terms/\{termId\}/assignedEntities' has methods for the following verbs: get, post, delete */ @@ -1305,22 +1431,37 @@ export interface Routes { termId: string, ): GlossaryListEntitiesAssignedWithTerm; /** Resource for '/atlas/v2/glossary/terms/\{termId\}/related' has methods for the following verbs: get */ - (path: "/atlas/v2/glossary/terms/{termId}/related", termId: string): GlossaryListRelatedTerms; + ( + path: "/atlas/v2/glossary/terms/{termId}/related", + termId: string, + ): GlossaryListRelatedTerms; /** Resource for '/atlas/v2/glossary/\{glossaryId\}' has methods for the following verbs: get, put, delete */ (path: "/atlas/v2/glossary/{glossaryId}", glossaryId: string): GlossaryGet; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/categories' has methods for the following verbs: get */ - (path: "/atlas/v2/glossary/{glossaryId}/categories", glossaryId: string): GlossaryListCategories; + ( + path: "/atlas/v2/glossary/{glossaryId}/categories", + glossaryId: string, + ): GlossaryListCategories; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/categories/headers' has methods for the following verbs: get */ ( path: "/atlas/v2/glossary/{glossaryId}/categories/headers", glossaryId: string, ): GlossaryListCategoriesHeaders; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/detailed' has methods for the following verbs: get */ - (path: "/atlas/v2/glossary/{glossaryId}/detailed", glossaryId: string): GlossaryGetDetailed; + ( + path: "/atlas/v2/glossary/{glossaryId}/detailed", + glossaryId: string, + ): GlossaryGetDetailed; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/partial' has methods for the following verbs: put */ - (path: "/atlas/v2/glossary/{glossaryId}/partial", glossaryId: string): GlossaryPartialUpdate; + ( + path: "/atlas/v2/glossary/{glossaryId}/partial", + glossaryId: string, + ): GlossaryPartialUpdate; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/terms' has methods for the following verbs: get */ - (path: "/atlas/v2/glossary/{glossaryId}/terms", glossaryId: string): GlossaryListTerms; + ( + path: "/atlas/v2/glossary/{glossaryId}/terms", + glossaryId: string, + ): GlossaryListTerms; /** Resource for '/atlas/v2/glossary/\{glossaryId\}/terms/headers' has methods for the following verbs: get */ ( path: "/atlas/v2/glossary/{glossaryId}/terms/headers", @@ -1366,21 +1507,45 @@ export interface Routes { name: string, ): TypeGetClassificationDefByName; /** Resource for '/atlas/v2/types/entitydef/guid/\{guid\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/entitydef/guid/{guid}", guid: string): TypeGetEntityDefByGuid; + ( + path: "/atlas/v2/types/entitydef/guid/{guid}", + guid: string, + ): TypeGetEntityDefByGuid; /** Resource for '/atlas/v2/types/entitydef/name/\{name\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/entitydef/name/{name}", name: string): TypeGetEntityDefByName; + ( + path: "/atlas/v2/types/entitydef/name/{name}", + name: string, + ): TypeGetEntityDefByName; /** Resource for '/atlas/v2/types/enumdef/guid/\{guid\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/enumdef/guid/{guid}", guid: string): TypeGetEnumDefByGuid; + ( + path: "/atlas/v2/types/enumdef/guid/{guid}", + guid: string, + ): TypeGetEnumDefByGuid; /** Resource for '/atlas/v2/types/enumdef/name/\{name\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/enumdef/name/{name}", name: string): TypeGetEnumDefByName; + ( + path: "/atlas/v2/types/enumdef/name/{name}", + name: string, + ): TypeGetEnumDefByName; /** Resource for '/atlas/v2/types/relationshipdef/guid/\{guid\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/relationshipdef/guid/{guid}", guid: string): TypeGetRelationshipDefByGuid; + ( + path: "/atlas/v2/types/relationshipdef/guid/{guid}", + guid: string, + ): TypeGetRelationshipDefByGuid; /** Resource for '/atlas/v2/types/relationshipdef/name/\{name\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/relationshipdef/name/{name}", name: string): TypeGetRelationshipDefByName; + ( + path: "/atlas/v2/types/relationshipdef/name/{name}", + name: string, + ): TypeGetRelationshipDefByName; /** Resource for '/atlas/v2/types/structdef/guid/\{guid\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/structdef/guid/{guid}", guid: string): TypeGetStructDefByGuid; + ( + path: "/atlas/v2/types/structdef/guid/{guid}", + guid: string, + ): TypeGetStructDefByGuid; /** Resource for '/atlas/v2/types/structdef/name/\{name\}' has methods for the following verbs: get */ - (path: "/atlas/v2/types/structdef/name/{name}", name: string): TypeGetStructDefByName; + ( + path: "/atlas/v2/types/structdef/name/{name}", + name: string, + ): TypeGetStructDefByName; /** Resource for '/atlas/v2/types/typedef/guid/\{guid\}' has methods for the following verbs: get */ (path: "/atlas/v2/types/typedef/guid/{guid}", guid: string): TypeGetByGuid; /** Resource for '/atlas/v2/types/typedef/name/\{name\}' has methods for the following verbs: get, delete */ @@ -1390,9 +1555,15 @@ export interface Routes { /** Resource for '/atlas/v2/types/typedefs/headers' has methods for the following verbs: get */ (path: "/atlas/v2/types/typedefs/headers"): TypeListHeaders; /** Resource for '/types/termtemplatedef/guid/\{guid\}' has methods for the following verbs: get */ - (path: "/types/termtemplatedef/guid/{guid}", guid: string): TypeGetTermTemplateDefByGuid; + ( + path: "/types/termtemplatedef/guid/{guid}", + guid: string, + ): TypeGetTermTemplateDefByGuid; /** Resource for '/types/termtemplatedef/name/\{name\}' has methods for the following verbs: get */ - (path: "/types/termtemplatedef/name/{name}", name: string): TypeGetTermTemplateDefByName; + ( + path: "/types/termtemplatedef/name/{name}", + name: string, + ): TypeGetTermTemplateDefByName; } export type PurviewDataMapClient = Client & { diff --git a/sdk/purview/purview-datamap-rest/src/index.ts b/sdk/purview/purview-datamap-rest/src/index.ts index 96e237139b05..a6e6ed289107 100644 --- a/sdk/purview/purview-datamap-rest/src/index.ts +++ b/sdk/purview/purview-datamap-rest/src/index.ts @@ -1,21 +1,15 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT license. -import PurviewDataMapClient from "./purviewDataMapClient"; +import PurviewDataMapClient from "./purviewDataMapClient.js"; -export * from "./purviewDataMapClient"; -export * from "./parameters"; -export * from "./responses"; -export * from "./clientDefinitions"; -export * from "./isUnexpected"; -export * from "./models"; -export * from "./outputModels"; -export * from "./serializeHelper"; -export { - createFile, - createFileFromStream, - type CreateFileOptions, - type CreateFileFromStreamOptions, -} from "@azure/core-rest-pipeline"; +export * from "./purviewDataMapClient.js"; +export * from "./parameters.js"; +export * from "./responses.js"; +export * from "./clientDefinitions.js"; +export * from "./isUnexpected.js"; +export * from "./models.js"; +export * from "./outputModels.js"; +export * from "./serializeHelper.js"; export default PurviewDataMapClient; diff --git a/sdk/purview/purview-datamap-rest/src/isUnexpected.ts b/sdk/purview/purview-datamap-rest/src/isUnexpected.ts index 246921ad09f9..8d33e71c270d 100644 --- a/sdk/purview/purview-datamap-rest/src/isUnexpected.ts +++ b/sdk/purview/purview-datamap-rest/src/isUnexpected.ts @@ -16,8 +16,8 @@ import { EntityGetDefaultResponse, EntityPartialUpdateAttributeByGuid200Response, EntityPartialUpdateAttributeByGuidDefaultResponse, - EntityDeleteOperation200Response, - EntityDeleteOperationDefaultResponse, + EntityDelete200Response, + EntityDeleteDefaultResponse, EntityGetClassification200Response, EntityGetClassificationDefaultResponse, EntityRemoveClassification204Response, @@ -116,8 +116,8 @@ import { GlossaryGetDefaultResponse, GlossaryUpdate200Response, GlossaryUpdateDefaultResponse, - GlossaryDeleteOperation204Response, - GlossaryDeleteOperationDefaultResponse, + GlossaryDelete204Response, + GlossaryDeleteDefaultResponse, GlossaryListCategories200Response, GlossaryListCategoriesDefaultResponse, GlossaryListCategoriesHeaders200Response, @@ -148,8 +148,8 @@ import { RelationshipUpdateDefaultResponse, RelationshipGet200Response, RelationshipGetDefaultResponse, - RelationshipDeleteOperation204Response, - RelationshipDeleteOperationDefaultResponse, + RelationshipDelete204Response, + RelationshipDeleteDefaultResponse, TypeGetBusinessMetadataDefByGuid200Response, TypeGetBusinessMetadataDefByGuidDefaultResponse, TypeGetBusinessMetadataDefByName200Response, @@ -178,8 +178,8 @@ import { TypeGetByGuidDefaultResponse, TypeGetByName200Response, TypeGetByNameDefaultResponse, - TypeDeleteOperation204Response, - TypeDeleteOperationDefaultResponse, + TypeDelete204Response, + TypeDeleteDefaultResponse, TypeList200Response, TypeListDefaultResponse, TypeBulkCreate200Response, @@ -194,7 +194,7 @@ import { TypeGetTermTemplateDefByGuidDefaultResponse, TypeGetTermTemplateDefByName200Response, TypeGetTermTemplateDefByNameDefaultResponse, -} from "./responses"; +} from "./responses.js"; const responseMap: Record = { "POST /atlas/v2/entity": ["200"], @@ -205,26 +205,36 @@ const responseMap: Record = { "GET /atlas/v2/entity/guid/{guid}": ["200"], "PUT /atlas/v2/entity/guid/{guid}": ["200"], "DELETE /atlas/v2/entity/guid/{guid}": ["200"], - "GET /atlas/v2/entity/guid/{guid}/classification/{classificationName}": ["200"], - "DELETE /atlas/v2/entity/guid/{guid}/classification/{classificationName}": ["204"], + "GET /atlas/v2/entity/guid/{guid}/classification/{classificationName}": [ + "200", + ], + "DELETE /atlas/v2/entity/guid/{guid}/classification/{classificationName}": [ + "204", + ], "GET /atlas/v2/entity/guid/{guid}/classifications": ["200"], "POST /atlas/v2/entity/guid/{guid}/classifications": ["204"], "PUT /atlas/v2/entity/guid/{guid}/classifications": ["204"], "GET /atlas/v2/entity/uniqueAttribute/type/{typeName}": ["200"], "PUT /atlas/v2/entity/uniqueAttribute/type/{typeName}": ["200"], "DELETE /atlas/v2/entity/uniqueAttribute/type/{typeName}": ["200"], - "DELETE /atlas/v2/entity/uniqueAttribute/type/{typeName}/classification/{classificationName}": [ + "DELETE /atlas/v2/entity/uniqueAttribute/type/{typeName}/classification/{classificationName}": + ["204"], + "POST /atlas/v2/entity/uniqueAttribute/type/{typeName}/classifications": [ + "204", + ], + "PUT /atlas/v2/entity/uniqueAttribute/type/{typeName}/classifications": [ "204", ], - "POST /atlas/v2/entity/uniqueAttribute/type/{typeName}/classifications": ["204"], - "PUT /atlas/v2/entity/uniqueAttribute/type/{typeName}/classifications": ["204"], "POST /atlas/v2/entity/bulk/setClassifications": ["200"], "GET /atlas/v2/entity/bulk/uniqueAttribute/type/{typeName}": ["200"], "GET /atlas/v2/entity/guid/{guid}/header": ["200"], "DELETE /atlas/v2/entity/guid/{guid}/businessmetadata": ["204"], "POST /atlas/v2/entity/guid/{guid}/businessmetadata": ["204"], - "DELETE /atlas/v2/entity/guid/{guid}/businessmetadata/{businessMetadataName}": ["204"], - "POST /atlas/v2/entity/guid/{guid}/businessmetadata/{businessMetadataName}": ["204"], + "DELETE /atlas/v2/entity/guid/{guid}/businessmetadata/{businessMetadataName}": + ["204"], + "POST /atlas/v2/entity/guid/{guid}/businessmetadata/{businessMetadataName}": [ + "204", + ], "GET /atlas/v2/entity/businessmetadata/import/template": ["200"], "POST /atlas/v2/entity/businessmetadata/import": ["200"], "DELETE /atlas/v2/entity/guid/{guid}/labels": ["204"], @@ -298,19 +308,25 @@ const responseMap: Record = { }; export function isUnexpected( - response: EntityCreateOrUpdate200Response | EntityCreateOrUpdateDefaultResponse, + response: + | EntityCreateOrUpdate200Response + | EntityCreateOrUpdateDefaultResponse, ): response is EntityCreateOrUpdateDefaultResponse; export function isUnexpected( response: EntityListByGuids200Response | EntityListByGuidsDefaultResponse, ): response is EntityListByGuidsDefaultResponse; export function isUnexpected( - response: EntityBulkCreateOrUpdate200Response | EntityBulkCreateOrUpdateDefaultResponse, + response: + | EntityBulkCreateOrUpdate200Response + | EntityBulkCreateOrUpdateDefaultResponse, ): response is EntityBulkCreateOrUpdateDefaultResponse; export function isUnexpected( response: EntityBulkDelete200Response | EntityBulkDeleteDefaultResponse, ): response is EntityBulkDeleteDefaultResponse; export function isUnexpected( - response: EntityAddClassification204Response | EntityAddClassificationDefaultResponse, + response: + | EntityAddClassification204Response + | EntityAddClassificationDefaultResponse, ): response is EntityAddClassificationDefaultResponse; export function isUnexpected( response: EntityGet200Response | EntityGetDefaultResponse, @@ -321,25 +337,37 @@ export function isUnexpected( | EntityPartialUpdateAttributeByGuidDefaultResponse, ): response is EntityPartialUpdateAttributeByGuidDefaultResponse; export function isUnexpected( - response: EntityDeleteOperation200Response | EntityDeleteOperationDefaultResponse, -): response is EntityDeleteOperationDefaultResponse; + response: EntityDelete200Response | EntityDeleteDefaultResponse, +): response is EntityDeleteDefaultResponse; export function isUnexpected( - response: EntityGetClassification200Response | EntityGetClassificationDefaultResponse, + response: + | EntityGetClassification200Response + | EntityGetClassificationDefaultResponse, ): response is EntityGetClassificationDefaultResponse; export function isUnexpected( - response: EntityRemoveClassification204Response | EntityRemoveClassificationDefaultResponse, + response: + | EntityRemoveClassification204Response + | EntityRemoveClassificationDefaultResponse, ): response is EntityRemoveClassificationDefaultResponse; export function isUnexpected( - response: EntityGetClassifications200Response | EntityGetClassificationsDefaultResponse, + response: + | EntityGetClassifications200Response + | EntityGetClassificationsDefaultResponse, ): response is EntityGetClassificationsDefaultResponse; export function isUnexpected( - response: EntityAddClassifications204Response | EntityAddClassificationsDefaultResponse, + response: + | EntityAddClassifications204Response + | EntityAddClassificationsDefaultResponse, ): response is EntityAddClassificationsDefaultResponse; export function isUnexpected( - response: EntityUpdateClassifications204Response | EntityUpdateClassificationsDefaultResponse, + response: + | EntityUpdateClassifications204Response + | EntityUpdateClassificationsDefaultResponse, ): response is EntityUpdateClassificationsDefaultResponse; export function isUnexpected( - response: EntityGetByUniqueAttributes200Response | EntityGetByUniqueAttributesDefaultResponse, + response: + | EntityGetByUniqueAttributes200Response + | EntityGetByUniqueAttributesDefaultResponse, ): response is EntityGetByUniqueAttributesDefaultResponse; export function isUnexpected( response: @@ -347,7 +375,9 @@ export function isUnexpected( | EntityPartialUpdateByUniqueAttributesDefaultResponse, ): response is EntityPartialUpdateByUniqueAttributesDefaultResponse; export function isUnexpected( - response: EntityDeleteByUniqueAttribute200Response | EntityDeleteByUniqueAttributeDefaultResponse, + response: + | EntityDeleteByUniqueAttribute200Response + | EntityDeleteByUniqueAttributeDefaultResponse, ): response is EntityDeleteByUniqueAttributeDefaultResponse; export function isUnexpected( response: @@ -365,16 +395,22 @@ export function isUnexpected( | EntityUpdateClassificationsByUniqueAttributeDefaultResponse, ): response is EntityUpdateClassificationsByUniqueAttributeDefaultResponse; export function isUnexpected( - response: EntityBulkSetClassifications200Response | EntityBulkSetClassificationsDefaultResponse, + response: + | EntityBulkSetClassifications200Response + | EntityBulkSetClassificationsDefaultResponse, ): response is EntityBulkSetClassificationsDefaultResponse; export function isUnexpected( - response: EntityListByUniqueAttributes200Response | EntityListByUniqueAttributesDefaultResponse, + response: + | EntityListByUniqueAttributes200Response + | EntityListByUniqueAttributesDefaultResponse, ): response is EntityListByUniqueAttributesDefaultResponse; export function isUnexpected( response: EntityGetHeader200Response | EntityGetHeaderDefaultResponse, ): response is EntityGetHeaderDefaultResponse; export function isUnexpected( - response: EntityRemoveBusinessMetadata204Response | EntityRemoveBusinessMetadataDefaultResponse, + response: + | EntityRemoveBusinessMetadata204Response + | EntityRemoveBusinessMetadataDefaultResponse, ): response is EntityRemoveBusinessMetadataDefaultResponse; export function isUnexpected( response: @@ -397,7 +433,9 @@ export function isUnexpected( | EntityGetSampleBusinessMetadataTemplateDefaultResponse, ): response is EntityGetSampleBusinessMetadataTemplateDefaultResponse; export function isUnexpected( - response: EntityImportBusinessMetadata200Response | EntityImportBusinessMetadataDefaultResponse, + response: + | EntityImportBusinessMetadata200Response + | EntityImportBusinessMetadataDefaultResponse, ): response is EntityImportBusinessMetadataDefaultResponse; export function isUnexpected( response: EntityRemoveLabels204Response | EntityRemoveLabelsDefaultResponse, @@ -435,28 +473,42 @@ export function isUnexpected( response: GlossaryCreate200Response | GlossaryCreateDefaultResponse, ): response is GlossaryCreateDefaultResponse; export function isUnexpected( - response: GlossaryCreateCategories200Response | GlossaryCreateCategoriesDefaultResponse, + response: + | GlossaryCreateCategories200Response + | GlossaryCreateCategoriesDefaultResponse, ): response is GlossaryCreateCategoriesDefaultResponse; export function isUnexpected( - response: GlossaryCreateCategory200Response | GlossaryCreateCategoryDefaultResponse, + response: + | GlossaryCreateCategory200Response + | GlossaryCreateCategoryDefaultResponse, ): response is GlossaryCreateCategoryDefaultResponse; export function isUnexpected( response: GlossaryGetCategory200Response | GlossaryGetCategoryDefaultResponse, ): response is GlossaryGetCategoryDefaultResponse; export function isUnexpected( - response: GlossaryUpdateCategory200Response | GlossaryUpdateCategoryDefaultResponse, + response: + | GlossaryUpdateCategory200Response + | GlossaryUpdateCategoryDefaultResponse, ): response is GlossaryUpdateCategoryDefaultResponse; export function isUnexpected( - response: GlossaryDeleteCategory204Response | GlossaryDeleteCategoryDefaultResponse, + response: + | GlossaryDeleteCategory204Response + | GlossaryDeleteCategoryDefaultResponse, ): response is GlossaryDeleteCategoryDefaultResponse; export function isUnexpected( - response: GlossaryPartialUpdateCategory200Response | GlossaryPartialUpdateCategoryDefaultResponse, + response: + | GlossaryPartialUpdateCategory200Response + | GlossaryPartialUpdateCategoryDefaultResponse, ): response is GlossaryPartialUpdateCategoryDefaultResponse; export function isUnexpected( - response: GlossaryListRelatedCategories200Response | GlossaryListRelatedCategoriesDefaultResponse, + response: + | GlossaryListRelatedCategories200Response + | GlossaryListRelatedCategoriesDefaultResponse, ): response is GlossaryListRelatedCategoriesDefaultResponse; export function isUnexpected( - response: GlossaryListCategoryTerms200Response | GlossaryListCategoryTermsDefaultResponse, + response: + | GlossaryListCategoryTerms200Response + | GlossaryListCategoryTermsDefaultResponse, ): response is GlossaryListCategoryTermsDefaultResponse; export function isUnexpected( response: GlossaryCreateTerm200Response | GlossaryCreateTermDefaultResponse, @@ -471,7 +523,9 @@ export function isUnexpected( response: GlossaryDeleteTerm204Response | GlossaryDeleteTermDefaultResponse, ): response is GlossaryDeleteTermDefaultResponse; export function isUnexpected( - response: GlossaryPartialUpdateTerm200Response | GlossaryPartialUpdateTermDefaultResponse, + response: + | GlossaryPartialUpdateTerm200Response + | GlossaryPartialUpdateTermDefaultResponse, ): response is GlossaryPartialUpdateTermDefaultResponse; export function isUnexpected( response: GlossaryCreateTerms200Response | GlossaryCreateTermsDefaultResponse, @@ -482,7 +536,9 @@ export function isUnexpected( | GlossaryListEntitiesAssignedWithTermDefaultResponse, ): response is GlossaryListEntitiesAssignedWithTermDefaultResponse; export function isUnexpected( - response: GlossaryAssignTermToEntities204Response | GlossaryAssignTermToEntitiesDefaultResponse, + response: + | GlossaryAssignTermToEntities204Response + | GlossaryAssignTermToEntitiesDefaultResponse, ): response is GlossaryAssignTermToEntitiesDefaultResponse; export function isUnexpected( response: @@ -490,7 +546,9 @@ export function isUnexpected( | GlossaryDeleteTermAssignmentFromEntitiesDefaultResponse, ): response is GlossaryDeleteTermAssignmentFromEntitiesDefaultResponse; export function isUnexpected( - response: GlossaryListRelatedTerms200Response | GlossaryListRelatedTermsDefaultResponse, + response: + | GlossaryListRelatedTerms200Response + | GlossaryListRelatedTermsDefaultResponse, ): response is GlossaryListRelatedTermsDefaultResponse; export function isUnexpected( response: GlossaryGet200Response | GlossaryGetDefaultResponse, @@ -499,25 +557,33 @@ export function isUnexpected( response: GlossaryUpdate200Response | GlossaryUpdateDefaultResponse, ): response is GlossaryUpdateDefaultResponse; export function isUnexpected( - response: GlossaryDeleteOperation204Response | GlossaryDeleteOperationDefaultResponse, -): response is GlossaryDeleteOperationDefaultResponse; + response: GlossaryDelete204Response | GlossaryDeleteDefaultResponse, +): response is GlossaryDeleteDefaultResponse; export function isUnexpected( - response: GlossaryListCategories200Response | GlossaryListCategoriesDefaultResponse, + response: + | GlossaryListCategories200Response + | GlossaryListCategoriesDefaultResponse, ): response is GlossaryListCategoriesDefaultResponse; export function isUnexpected( - response: GlossaryListCategoriesHeaders200Response | GlossaryListCategoriesHeadersDefaultResponse, + response: + | GlossaryListCategoriesHeaders200Response + | GlossaryListCategoriesHeadersDefaultResponse, ): response is GlossaryListCategoriesHeadersDefaultResponse; export function isUnexpected( response: GlossaryGetDetailed200Response | GlossaryGetDetailedDefaultResponse, ): response is GlossaryGetDetailedDefaultResponse; export function isUnexpected( - response: GlossaryPartialUpdate200Response | GlossaryPartialUpdateDefaultResponse, + response: + | GlossaryPartialUpdate200Response + | GlossaryPartialUpdateDefaultResponse, ): response is GlossaryPartialUpdateDefaultResponse; export function isUnexpected( response: GlossaryListTerms200Response | GlossaryListTermsDefaultResponse, ): response is GlossaryListTermsDefaultResponse; export function isUnexpected( - response: GlossaryListTermHeaders200Response | GlossaryListTermHeadersDefaultResponse, + response: + | GlossaryListTermHeaders200Response + | GlossaryListTermHeadersDefaultResponse, ): response is GlossaryListTermHeadersDefaultResponse; export function isUnexpected( response: DiscoveryQuery200Response | DiscoveryQueryDefaultResponse, @@ -526,7 +592,9 @@ export function isUnexpected( response: DiscoverySuggest200Response | DiscoverySuggestDefaultResponse, ): response is DiscoverySuggestDefaultResponse; export function isUnexpected( - response: DiscoveryAutoComplete200Response | DiscoveryAutoCompleteDefaultResponse, + response: + | DiscoveryAutoComplete200Response + | DiscoveryAutoCompleteDefaultResponse, ): response is DiscoveryAutoCompleteDefaultResponse; export function isUnexpected( response: LineageGet200Response | LineageGetDefaultResponse, @@ -535,7 +603,9 @@ export function isUnexpected( response: LineageGetNextPage200Response | LineageGetNextPageDefaultResponse, ): response is LineageGetNextPageDefaultResponse; export function isUnexpected( - response: LineageGetByUniqueAttribute200Response | LineageGetByUniqueAttributeDefaultResponse, + response: + | LineageGetByUniqueAttribute200Response + | LineageGetByUniqueAttributeDefaultResponse, ): response is LineageGetByUniqueAttributeDefaultResponse; export function isUnexpected( response: RelationshipCreate200Response | RelationshipCreateDefaultResponse, @@ -547,8 +617,8 @@ export function isUnexpected( response: RelationshipGet200Response | RelationshipGetDefaultResponse, ): response is RelationshipGetDefaultResponse; export function isUnexpected( - response: RelationshipDeleteOperation204Response | RelationshipDeleteOperationDefaultResponse, -): response is RelationshipDeleteOperationDefaultResponse; + response: RelationshipDelete204Response | RelationshipDeleteDefaultResponse, +): response is RelationshipDeleteDefaultResponse; export function isUnexpected( response: | TypeGetBusinessMetadataDefByGuid200Response @@ -570,28 +640,44 @@ export function isUnexpected( | TypeGetClassificationDefByNameDefaultResponse, ): response is TypeGetClassificationDefByNameDefaultResponse; export function isUnexpected( - response: TypeGetEntityDefByGuid200Response | TypeGetEntityDefByGuidDefaultResponse, + response: + | TypeGetEntityDefByGuid200Response + | TypeGetEntityDefByGuidDefaultResponse, ): response is TypeGetEntityDefByGuidDefaultResponse; export function isUnexpected( - response: TypeGetEntityDefByName200Response | TypeGetEntityDefByNameDefaultResponse, + response: + | TypeGetEntityDefByName200Response + | TypeGetEntityDefByNameDefaultResponse, ): response is TypeGetEntityDefByNameDefaultResponse; export function isUnexpected( - response: TypeGetEnumDefByGuid200Response | TypeGetEnumDefByGuidDefaultResponse, + response: + | TypeGetEnumDefByGuid200Response + | TypeGetEnumDefByGuidDefaultResponse, ): response is TypeGetEnumDefByGuidDefaultResponse; export function isUnexpected( - response: TypeGetEnumDefByName200Response | TypeGetEnumDefByNameDefaultResponse, + response: + | TypeGetEnumDefByName200Response + | TypeGetEnumDefByNameDefaultResponse, ): response is TypeGetEnumDefByNameDefaultResponse; export function isUnexpected( - response: TypeGetRelationshipDefByGuid200Response | TypeGetRelationshipDefByGuidDefaultResponse, + response: + | TypeGetRelationshipDefByGuid200Response + | TypeGetRelationshipDefByGuidDefaultResponse, ): response is TypeGetRelationshipDefByGuidDefaultResponse; export function isUnexpected( - response: TypeGetRelationshipDefByName200Response | TypeGetRelationshipDefByNameDefaultResponse, + response: + | TypeGetRelationshipDefByName200Response + | TypeGetRelationshipDefByNameDefaultResponse, ): response is TypeGetRelationshipDefByNameDefaultResponse; export function isUnexpected( - response: TypeGetStructDefByGuid200Response | TypeGetStructDefByGuidDefaultResponse, + response: + | TypeGetStructDefByGuid200Response + | TypeGetStructDefByGuidDefaultResponse, ): response is TypeGetStructDefByGuidDefaultResponse; export function isUnexpected( - response: TypeGetStructDefByName200Response | TypeGetStructDefByNameDefaultResponse, + response: + | TypeGetStructDefByName200Response + | TypeGetStructDefByNameDefaultResponse, ): response is TypeGetStructDefByNameDefaultResponse; export function isUnexpected( response: TypeGetByGuid200Response | TypeGetByGuidDefaultResponse, @@ -600,8 +686,8 @@ export function isUnexpected( response: TypeGetByName200Response | TypeGetByNameDefaultResponse, ): response is TypeGetByNameDefaultResponse; export function isUnexpected( - response: TypeDeleteOperation204Response | TypeDeleteOperationDefaultResponse, -): response is TypeDeleteOperationDefaultResponse; + response: TypeDelete204Response | TypeDeleteDefaultResponse, +): response is TypeDeleteDefaultResponse; export function isUnexpected( response: TypeList200Response | TypeListDefaultResponse, ): response is TypeListDefaultResponse; @@ -618,10 +704,14 @@ export function isUnexpected( response: TypeListHeaders200Response | TypeListHeadersDefaultResponse, ): response is TypeListHeadersDefaultResponse; export function isUnexpected( - response: TypeGetTermTemplateDefByGuid200Response | TypeGetTermTemplateDefByGuidDefaultResponse, + response: + | TypeGetTermTemplateDefByGuid200Response + | TypeGetTermTemplateDefByGuidDefaultResponse, ): response is TypeGetTermTemplateDefByGuidDefaultResponse; export function isUnexpected( - response: TypeGetTermTemplateDefByName200Response | TypeGetTermTemplateDefByNameDefaultResponse, + response: + | TypeGetTermTemplateDefByName200Response + | TypeGetTermTemplateDefByNameDefaultResponse, ): response is TypeGetTermTemplateDefByNameDefaultResponse; export function isUnexpected( response: @@ -639,8 +729,8 @@ export function isUnexpected( | EntityGetDefaultResponse | EntityPartialUpdateAttributeByGuid200Response | EntityPartialUpdateAttributeByGuidDefaultResponse - | EntityDeleteOperation200Response - | EntityDeleteOperationDefaultResponse + | EntityDelete200Response + | EntityDeleteDefaultResponse | EntityGetClassification200Response | EntityGetClassificationDefaultResponse | EntityRemoveClassification204Response @@ -739,8 +829,8 @@ export function isUnexpected( | GlossaryGetDefaultResponse | GlossaryUpdate200Response | GlossaryUpdateDefaultResponse - | GlossaryDeleteOperation204Response - | GlossaryDeleteOperationDefaultResponse + | GlossaryDelete204Response + | GlossaryDeleteDefaultResponse | GlossaryListCategories200Response | GlossaryListCategoriesDefaultResponse | GlossaryListCategoriesHeaders200Response @@ -771,8 +861,8 @@ export function isUnexpected( | RelationshipUpdateDefaultResponse | RelationshipGet200Response | RelationshipGetDefaultResponse - | RelationshipDeleteOperation204Response - | RelationshipDeleteOperationDefaultResponse + | RelationshipDelete204Response + | RelationshipDeleteDefaultResponse | TypeGetBusinessMetadataDefByGuid200Response | TypeGetBusinessMetadataDefByGuidDefaultResponse | TypeGetBusinessMetadataDefByName200Response @@ -801,8 +891,8 @@ export function isUnexpected( | TypeGetByGuidDefaultResponse | TypeGetByName200Response | TypeGetByNameDefaultResponse - | TypeDeleteOperation204Response - | TypeDeleteOperationDefaultResponse + | TypeDelete204Response + | TypeDeleteDefaultResponse | TypeList200Response | TypeListDefaultResponse | TypeBulkCreate200Response @@ -825,7 +915,7 @@ export function isUnexpected( | EntityAddClassificationDefaultResponse | EntityGetDefaultResponse | EntityPartialUpdateAttributeByGuidDefaultResponse - | EntityDeleteOperationDefaultResponse + | EntityDeleteDefaultResponse | EntityGetClassificationDefaultResponse | EntityRemoveClassificationDefaultResponse | EntityGetClassificationsDefaultResponse @@ -875,7 +965,7 @@ export function isUnexpected( | GlossaryListRelatedTermsDefaultResponse | GlossaryGetDefaultResponse | GlossaryUpdateDefaultResponse - | GlossaryDeleteOperationDefaultResponse + | GlossaryDeleteDefaultResponse | GlossaryListCategoriesDefaultResponse | GlossaryListCategoriesHeadersDefaultResponse | GlossaryGetDetailedDefaultResponse @@ -891,7 +981,7 @@ export function isUnexpected( | RelationshipCreateDefaultResponse | RelationshipUpdateDefaultResponse | RelationshipGetDefaultResponse - | RelationshipDeleteOperationDefaultResponse + | RelationshipDeleteDefaultResponse | TypeGetBusinessMetadataDefByGuidDefaultResponse | TypeGetBusinessMetadataDefByNameDefaultResponse | TypeGetClassificationDefByGuidDefaultResponse @@ -906,7 +996,7 @@ export function isUnexpected( | TypeGetStructDefByNameDefaultResponse | TypeGetByGuidDefaultResponse | TypeGetByNameDefaultResponse - | TypeDeleteOperationDefaultResponse + | TypeDeleteDefaultResponse | TypeListDefaultResponse | TypeBulkCreateDefaultResponse | TypeBulkUpdateDefaultResponse @@ -946,17 +1036,24 @@ function getParametrizedPathSuccess(method: string, path: string): string[] { // track if we have found a match to return the values found. let found = true; - for (let i = candidateParts.length - 1, j = pathParts.length - 1; i >= 1 && j >= 1; i--, j--) { - if (candidateParts[i]?.startsWith("{") && candidateParts[i]?.indexOf("}") !== -1) { + for ( + let i = candidateParts.length - 1, j = pathParts.length - 1; + i >= 1 && j >= 1; + i--, j-- + ) { + if ( + candidateParts[i]?.startsWith("{") && + candidateParts[i]?.indexOf("}") !== -1 + ) { const start = candidateParts[i]!.indexOf("}") + 1, end = candidateParts[i]?.length; // If the current part of the candidate is a "template" part // Try to use the suffix of pattern to match the path // {guid} ==> $ // {guid}:export ==> :export$ - const isMatched = new RegExp(`${candidateParts[i]?.slice(start, end)}`).test( - pathParts[j] || "", - ); + const isMatched = new RegExp( + `${candidateParts[i]?.slice(start, end)}`, + ).test(pathParts[j] || ""); if (!isMatched) { found = false; diff --git a/sdk/purview/purview-datamap-rest/src/models.ts b/sdk/purview/purview-datamap-rest/src/models.ts index fca5784602ed..0e7c27d40eff 100644 --- a/sdk/purview/purview-datamap-rest/src/models.ts +++ b/sdk/purview/purview-datamap-rest/src/models.ts @@ -49,10 +49,8 @@ export interface AtlasEntity { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - status?: string; + status?: EntityStatus; /** The update time of the record. */ updateTime?: number; /** The user who updated the record. */ @@ -79,10 +77,8 @@ export interface AtlasClassification { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - entityStatus?: string; + entityStatus?: EntityStatus; /** Determines if propagations will be removed on entity deletion. */ removePropagationsOnEntityDelete?: boolean; /** An array of time boundaries indicating validity periods. */ @@ -113,12 +109,8 @@ export interface AtlasTermAssignmentHeader { expression?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of terms assignment. - * - * Possible values: "DISCOVERED", "PROPOSED", "IMPORTED", "VALIDATED", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of terms assignment. */ + status?: AtlasTermAssignmentStatus; /** The steward of the term. */ steward?: string; /** The GUID of the term. */ @@ -160,10 +152,8 @@ export interface AtlasEntityHeader { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - status?: string; + status?: EntityStatus; } /** @@ -194,15 +184,16 @@ export interface AtlasEntityHeaders { guidHeaderMap?: Record; } -/** Business metadata to send to the service */ -export interface BusinessMetadataOptions { - /** - * InputStream of file - * - * NOTE: The following type 'File' is part of WebAPI and available since Node 20. If your Node version is lower than Node 20. - * You could leverage our helpers 'createFile' or 'createFileFromStream' to create a File object. They could help you specify filename, type, and others. - */ - file: string | Uint8Array | ReadableStream | NodeJS.ReadableStream | File; +export interface BusinessMetadataOptionsFilePartDescriptor { + name: "file"; + body: + | string + | Uint8Array + | ReadableStream + | NodeJS.ReadableStream + | File; + filename?: string; + contentType?: string; } /** MoveEntitiesOptions */ @@ -269,12 +260,8 @@ export interface AtlasRelatedTermHeader { expression?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of term relationship. - * - * Possible values: "DRAFT", "ACTIVE", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of term relationship. */ + status?: AtlasTermRelationshipStatus; /** The steward of the term. */ steward?: string; /** The GUID of the term. */ @@ -357,12 +344,8 @@ export interface AtlasGlossaryTerm { anchor?: AtlasGlossaryHeader; /** An array of related term headers as antonyms. */ antonyms?: Array; - /** - * Status of the AtlasGlossaryTerm - * - * Possible values: "Draft", "Approved", "Alert", "Expired" - */ - status?: string; + /** Status of the AtlasGlossaryTerm */ + status?: TermStatus; /** The nick name of the term. */ nickName?: string; /** The hierarchy information of the term. */ @@ -455,10 +438,8 @@ export interface AtlasRelatedObjectId { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - entityStatus?: string; + entityStatus?: EntityStatus; /** Relationship type */ relationshipType?: string; /** @@ -468,12 +449,8 @@ export interface AtlasRelatedObjectId { relationshipAttributes?: AtlasStruct; /** The GUID of the relationship. */ relationshipGuid?: string; - /** - * The enum of relationship status. - * - * Possible values: "ACTIVE", "DELETED" - */ - relationshipStatus?: string; + /** The enum of relationship status. */ + relationshipStatus?: StatusAtlasRelationship; } /** @@ -499,12 +476,8 @@ export interface AtlasTermCategorizationHeader { displayText?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of term relationship. - * - * Possible values: "DRAFT", "ACTIVE", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of term relationship. */ + status?: AtlasTermRelationshipStatus; } /** The search query of advanced search request. */ @@ -543,18 +516,10 @@ export interface SearchFacetItem { /** The sorting criteria */ export interface SearchFacetSort { - /** - * Order by count - * - * Possible values: "asc", "desc" - */ - count?: string; - /** - * Order by value - * - * Possible values: "asc", "desc" - */ - value?: string; + /** Order by count */ + count?: SearchSortOrder; + /** Order by value */ + value?: SearchSortOrder; } /** Taxonomy setting for search request */ @@ -623,12 +588,8 @@ export interface AtlasRelationship { label?: string; /** Used to record the provenance of an instance of an entity or relationship */ provenanceType?: number; - /** - * The enum of relationship status. - * - * Possible values: "ACTIVE", "DELETED" - */ - status?: string; + /** The enum of relationship status. */ + status?: StatusAtlasRelationship; /** The update time of the record. */ updateTime?: number; /** The user who updated the record. */ @@ -649,12 +610,8 @@ export interface AtlasObjectId { /** class that captures details of a struct-type. */ export interface AtlasBusinessMetadataDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -735,12 +692,8 @@ export interface NumberFormat { parseIntegerOnly?: boolean; /** The number format. */ percentInstance?: NumberFormat; - /** - * The enum of rounding mode. - * - * Possible values: "UP", "DOWN", "CEILING", "FLOOR", "HALF_UP", "HALF_DOWN", "HALF_EVEN", "UNNECESSARY" - */ - roundingMode?: string; + /** The enum of rounding mode. */ + roundingMode?: RoundingMode; } /** The timezone information. */ @@ -761,12 +714,8 @@ export interface TimeZone { /** class that captures details of a struct-attribute. */ export interface AtlasAttributeDef { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValue; /** An array of constraints. */ constraints?: Array; /** The default value of the attribute. */ @@ -803,12 +752,8 @@ export interface AtlasConstraintDef { /** class that captures details of a classification-type. */ export interface AtlasClassificationDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -870,12 +815,8 @@ export interface AtlasClassificationDef { /** class that captures details of a entity-type. */ export interface AtlasEntityDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -919,12 +860,8 @@ export interface AtlasEntityDef { * it is the container end of the relationship. */ export interface AtlasRelationshipAttributeDef { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValue; /** An array of constraints. */ constraints?: Array; /** The default value of the attribute. */ @@ -957,12 +894,8 @@ export interface AtlasRelationshipAttributeDef { /** class that captures details of an enum-type. */ export interface AtlasEnumDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1046,12 +979,8 @@ export interface AtlasEnumElementDef { * the entity instances */ export interface AtlasRelationshipDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1103,10 +1032,8 @@ export interface AtlasRelationshipDef { * The difference being in the lifecycles of the container and its children. * In the COMPOSITION case, the children cannot exist without the container. * For AGGREGATION, the life cycles of the container and children are totally independent. - * - * Possible values: "ASSOCIATION", "AGGREGATION", "COMPOSITION" */ - relationshipCategory?: string; + relationshipCategory?: RelationshipCategory; /** The label of the relationship. */ relationshipLabel?: string; } @@ -1118,12 +1045,8 @@ export interface AtlasRelationshipDef { * it is the container end of the relationship. */ export interface AtlasRelationshipEndDef { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValue; /** The description of the relationship end definition. */ description?: string; /** Determines if it is container. */ @@ -1138,12 +1061,8 @@ export interface AtlasRelationshipEndDef { /** class that captures details of a struct-type. */ export interface AtlasStructDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1194,12 +1113,8 @@ export interface AtlasTypesDef { /** Term template definition for glossary term. */ export interface TermTemplateDef { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategory; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1229,3 +1144,32 @@ export interface TermTemplateDef { /** An array of attribute definitions. */ attributeDefs?: Array; } + +/** Alias for BusinessAttributeUpdateBehavior */ +export type BusinessAttributeUpdateBehavior = string; +/** Alias for EntityStatus */ +export type EntityStatus = string; +/** Alias for AtlasTermAssignmentStatus */ +export type AtlasTermAssignmentStatus = string; +/** Business metadata to send to the service */ +export type BusinessMetadataOptions = + | FormData + | Array; +/** Alias for AtlasTermRelationshipStatus */ +export type AtlasTermRelationshipStatus = string; +/** Alias for TermStatus */ +export type TermStatus = string; +/** Alias for StatusAtlasRelationship */ +export type StatusAtlasRelationship = string; +/** Alias for SearchSortOrder */ +export type SearchSortOrder = string; +/** Alias for LineageDirection */ +export type LineageDirection = string; +/** Alias for TypeCategory */ +export type TypeCategory = string; +/** Alias for RoundingMode */ +export type RoundingMode = string; +/** Alias for CardinalityValue */ +export type CardinalityValue = string; +/** Alias for RelationshipCategory */ +export type RelationshipCategory = string; diff --git a/sdk/purview/purview-datamap-rest/src/outputModels.ts b/sdk/purview/purview-datamap-rest/src/outputModels.ts index 0828d12b2798..ef55288ba1e3 100644 --- a/sdk/purview/purview-datamap-rest/src/outputModels.ts +++ b/sdk/purview/purview-datamap-rest/src/outputModels.ts @@ -51,10 +51,8 @@ export interface AtlasEntityOutput { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - status?: string; + status?: EntityStatusOutput; /** The update time of the record. */ updateTime?: number; /** The user who updated the record. */ @@ -81,10 +79,8 @@ export interface AtlasClassificationOutput { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - entityStatus?: string; + entityStatus?: EntityStatusOutput; /** Determines if propagations will be removed on entity deletion. */ removePropagationsOnEntityDelete?: boolean; /** An array of time boundaries indicating validity periods. */ @@ -115,12 +111,8 @@ export interface AtlasTermAssignmentHeaderOutput { expression?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of terms assignment. - * - * Possible values: "DISCOVERED", "PROPOSED", "IMPORTED", "VALIDATED", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of terms assignment. */ + status?: AtlasTermAssignmentStatusOutput; /** The steward of the term. */ steward?: string; /** The GUID of the term. */ @@ -172,10 +164,8 @@ export interface AtlasEntityHeaderOutput { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - status?: string; + status?: EntityStatusOutput; } /** An error response from the service */ @@ -207,29 +197,14 @@ export interface AtlasClassificationsOutput { pageSize?: number; /** The sorted by field. */ sortBy?: string; - /** - * to specify whether the result should be sorted? If yes, whether asc or desc. - * - * Possible values: "NONE", "ASC", "DESC" - */ - sortType?: string; + /** to specify whether the result should be sorted? If yes, whether asc or desc. */ + sortType?: SortTypeOutput; /** The start index of the page. */ startIndex?: number; /** The total count of items. */ totalCount?: number; } -/** Business metadata to send to the service */ -export interface BusinessMetadataOptionsOutput { - /** - * InputStream of file - * - * NOTE: The following type 'File' is part of WebAPI and available since Node 20. If your Node version is lower than Node 20. - * You could leverage our helpers 'createFile' or 'createFileFromStream' to create a File object. They could help you specify filename, type, and others. - */ - file: Uint8Array; -} - /** Bulk import result */ export interface BulkImportResultOutput { /** failed importInfoList */ @@ -242,12 +217,8 @@ export interface BulkImportResultOutput { export interface ImportInfoOutput { /** childObjectName */ childObjectName?: string; - /** - * importStatus - * - * Possible values: "SUCCESS", "FAILED" - */ - importStatus?: string; + /** importStatus */ + importStatus?: ImportStatusOutput; /** parentObjectName */ parentObjectName?: string; /** remarks */ @@ -312,12 +283,8 @@ export interface AtlasRelatedTermHeaderOutput { expression?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of term relationship. - * - * Possible values: "DRAFT", "ACTIVE", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of term relationship. */ + status?: AtlasTermRelationshipStatusOutput; /** The steward of the term. */ steward?: string; /** The GUID of the term. */ @@ -400,12 +367,8 @@ export interface AtlasGlossaryTermOutput { anchor?: AtlasGlossaryHeaderOutput; /** An array of related term headers as antonyms. */ antonyms?: Array; - /** - * Status of the AtlasGlossaryTerm - * - * Possible values: "Draft", "Approved", "Alert", "Expired" - */ - status?: string; + /** Status of the AtlasGlossaryTerm */ + status?: TermStatusOutput; /** The nick name of the term. */ nickName?: string; /** The hierarchy information of the term. */ @@ -498,10 +461,8 @@ export interface AtlasRelatedObjectIdOutput { /** * Status of the entity - can be active or deleted. Deleted entities are not * removed. - * - * Possible values: "ACTIVE", "DELETED" */ - entityStatus?: string; + entityStatus?: EntityStatusOutput; /** Relationship type */ relationshipType?: string; /** @@ -511,12 +472,8 @@ export interface AtlasRelatedObjectIdOutput { relationshipAttributes?: AtlasStructOutput; /** The GUID of the relationship. */ relationshipGuid?: string; - /** - * The enum of relationship status. - * - * Possible values: "ACTIVE", "DELETED" - */ - relationshipStatus?: string; + /** The enum of relationship status. */ + relationshipStatus?: StatusAtlasRelationshipOutput; } /** @@ -542,12 +499,8 @@ export interface AtlasTermCategorizationHeaderOutput { displayText?: string; /** The GUID of the relationship. */ relationGuid?: string; - /** - * The status of term relationship. - * - * Possible values: "DRAFT", "ACTIVE", "DEPRECATED", "OBSOLETE", "OTHER" - */ - status?: string; + /** The status of term relationship. */ + status?: AtlasTermRelationshipStatusOutput; } /** The extended information of glossary. */ @@ -594,9 +547,9 @@ export interface QueryResultOutput { * The total number of search results (not the number of documents in a single * page). */ - searchCount?: number; + "@search.count"?: number; /** 'True' if the '@search.count' is an approximate value and vise versa. */ - searchCountApproximate?: boolean; + "@search.count.approximate"?: boolean; /** The token used to get next batch of data. Absent if there's no more data. */ continuationToken?: string; /** @@ -604,7 +557,7 @@ export interface QueryResultOutput { * contactId, and label. When the facet is specified in the request, the value of * the facet is returned as an element of @search.facets. */ - searchFacets?: SearchFacetResultValueOutput; + "@search.facets"?: SearchFacetResultValueOutput; /** Search result value */ value?: Array; } @@ -651,14 +604,14 @@ export interface SearchResultValueOutput { * The search score calculated by the search engine. The results are ordered by * search score by default. */ - searchScore?: number; + "@search.score"?: number; /** * A highlight list that consists of index fields id ,qualifiedName, name, * description, entityType. When the keyword appears in those fields, the value of * the field, attached with emphasis mark, is returned as an element of * @search.highlights. */ - searchHighlights?: SearchHighlightsOutput; + "@search.highlights"?: SearchHighlightsOutput; /** * The object type of the record. Object type is the top-level property to * distinguish whether a record is an asset or a term. @@ -761,12 +714,12 @@ export interface SuggestResultValueOutput { * The search score calculated by the search engine. The results are ordered by * search score by default. */ - searchScore?: number; + "@search.score"?: number; /** * The target text that contains the keyword as prefix. The keyword is wrapped * with emphasis mark. */ - searchText?: string; + "@search.text"?: string; /** * The object type of the record. Object type is the top-level property to * distinguish whether a record is an asset or a term. @@ -843,12 +796,8 @@ export interface AtlasLineageInfoOutput { lineageWidth?: number; /** The number of children node. */ childrenCount?: number; - /** - * The enum of lineage direction. - * - * Possible values: "INPUT", "OUTPUT", "BOTH" - */ - lineageDirection?: string; + /** The enum of lineage direction. */ + lineageDirection?: LineageDirectionOutput; /** An array of parentRelations relations. */ parentRelations?: Array; /** An array of lineage relations. */ @@ -899,12 +848,8 @@ export interface AtlasRelationshipOutput { label?: string; /** Used to record the provenance of an instance of an entity or relationship */ provenanceType?: number; - /** - * The enum of relationship status. - * - * Possible values: "ACTIVE", "DELETED" - */ - status?: string; + /** The enum of relationship status. */ + status?: StatusAtlasRelationshipOutput; /** The update time of the record. */ updateTime?: number; /** The user who updated the record. */ @@ -933,12 +878,8 @@ export interface AtlasRelationshipWithExtInfoOutput { /** class that captures details of a struct-type. */ export interface AtlasBusinessMetadataDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1019,12 +960,8 @@ export interface NumberFormatOutput { parseIntegerOnly?: boolean; /** The number format. */ percentInstance?: NumberFormatOutput; - /** - * The enum of rounding mode. - * - * Possible values: "UP", "DOWN", "CEILING", "FLOOR", "HALF_UP", "HALF_DOWN", "HALF_EVEN", "UNNECESSARY" - */ - roundingMode?: string; + /** The enum of rounding mode. */ + roundingMode?: RoundingModeOutput; } /** The timezone information. */ @@ -1045,12 +982,8 @@ export interface TimeZoneOutput { /** class that captures details of a struct-attribute. */ export interface AtlasAttributeDefOutput { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValueOutput; /** An array of constraints. */ constraints?: Array; /** The default value of the attribute. */ @@ -1087,12 +1020,8 @@ export interface AtlasConstraintDefOutput { /** class that captures details of a classification-type. */ export interface AtlasClassificationDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1154,12 +1083,8 @@ export interface AtlasClassificationDefOutput { /** class that captures details of a entity-type. */ export interface AtlasEntityDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1203,12 +1128,8 @@ export interface AtlasEntityDefOutput { * it is the container end of the relationship. */ export interface AtlasRelationshipAttributeDefOutput { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValueOutput; /** An array of constraints. */ constraints?: Array; /** The default value of the attribute. */ @@ -1241,12 +1162,8 @@ export interface AtlasRelationshipAttributeDefOutput { /** class that captures details of an enum-type. */ export interface AtlasEnumDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1330,12 +1247,8 @@ export interface AtlasEnumElementDefOutput { * the entity instances */ export interface AtlasRelationshipDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1387,10 +1300,8 @@ export interface AtlasRelationshipDefOutput { * The difference being in the lifecycles of the container and its children. * In the COMPOSITION case, the children cannot exist without the container. * For AGGREGATION, the life cycles of the container and children are totally independent. - * - * Possible values: "ASSOCIATION", "AGGREGATION", "COMPOSITION" */ - relationshipCategory?: string; + relationshipCategory?: RelationshipCategoryOutput; /** The label of the relationship. */ relationshipLabel?: string; } @@ -1402,12 +1313,8 @@ export interface AtlasRelationshipDefOutput { * it is the container end of the relationship. */ export interface AtlasRelationshipEndDefOutput { - /** - * single-valued attribute or multi-valued attribute. - * - * Possible values: "SINGLE", "LIST", "SET" - */ - cardinality?: string; + /** single-valued attribute or multi-valued attribute. */ + cardinality?: CardinalityValueOutput; /** The description of the relationship end definition. */ description?: string; /** Determines if it is container. */ @@ -1422,12 +1329,8 @@ export interface AtlasRelationshipEndDefOutput { /** class that captures details of a struct-type. */ export interface AtlasStructDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1460,12 +1363,8 @@ export interface AtlasStructDefOutput { /** The definitions of type. */ export interface AtlasTypeDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1552,10 +1451,8 @@ export interface AtlasTypeDefOutput { * The difference being in the lifecycles of the container and its children. * In the COMPOSITION case, the children cannot exist without the container. * For AGGREGATION, the life cycles of the container and children are totally independent. - * - * Possible values: "ASSOCIATION", "AGGREGATION", "COMPOSITION" */ - relationshipCategory?: string; + relationshipCategory?: RelationshipCategoryOutput; /** The label of the relationship. */ relationshipLabel?: string; /** An array of attribute definitions. */ @@ -1582,12 +1479,8 @@ export interface AtlasTypesDefOutput { /** Term template definition for glossary term. */ export interface TermTemplateDefOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The created time of the record. */ createTime?: number; /** The user who created the record. */ @@ -1620,14 +1513,35 @@ export interface TermTemplateDefOutput { /** The basic information of the type definition. */ export interface AtlasTypeDefHeaderOutput { - /** - * The enum of type category. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - category?: string; + /** The enum of type category. */ + category?: TypeCategoryOutput; /** The GUID of the type definition. */ guid?: string; /** The name of the type definition. */ name?: string; } + +/** Alias for EntityStatusOutput */ +export type EntityStatusOutput = string; +/** Alias for AtlasTermAssignmentStatusOutput */ +export type AtlasTermAssignmentStatusOutput = string; +/** Alias for SortTypeOutput */ +export type SortTypeOutput = string; +/** Alias for ImportStatusOutput */ +export type ImportStatusOutput = string; +/** Alias for AtlasTermRelationshipStatusOutput */ +export type AtlasTermRelationshipStatusOutput = string; +/** Alias for TermStatusOutput */ +export type TermStatusOutput = string; +/** Alias for StatusAtlasRelationshipOutput */ +export type StatusAtlasRelationshipOutput = string; +/** Alias for LineageDirectionOutput */ +export type LineageDirectionOutput = string; +/** Alias for TypeCategoryOutput */ +export type TypeCategoryOutput = string; +/** Alias for RoundingModeOutput */ +export type RoundingModeOutput = string; +/** Alias for CardinalityValueOutput */ +export type CardinalityValueOutput = string; +/** Alias for RelationshipCategoryOutput */ +export type RelationshipCategoryOutput = string; diff --git a/sdk/purview/purview-datamap-rest/src/parameters.ts b/sdk/purview/purview-datamap-rest/src/parameters.ts index 60c512a3469e..426b2fff8cae 100644 --- a/sdk/purview/purview-datamap-rest/src/parameters.ts +++ b/sdk/purview/purview-datamap-rest/src/parameters.ts @@ -3,6 +3,7 @@ import { RequestParameters } from "@azure-rest/core-client"; import { + BusinessAttributeUpdateBehavior, AtlasEntityWithExtInfo, AtlasEntitiesWithExtInfo, ClassificationAssociateOptions, @@ -17,22 +18,25 @@ import { QueryOptions, SuggestOptions, AutoCompleteOptions, + LineageDirection, AtlasRelationship, + TypeCategory, AtlasTypesDef, -} from "./models"; +} from "./models.js"; export interface EntityCreateOrUpdateBodyParam { - body?: AtlasEntityWithExtInfo; + /** Body parameter. */ + body: AtlasEntityWithExtInfo; } export interface EntityCreateOrUpdateQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** * Used to define the update behavior for business attributes when updating * entities. - * - * Possible values: "ignore", "replace", "merge" */ - businessAttributeUpdateBehavior?: string; + businessAttributeUpdateBehavior?: BusinessAttributeUpdateBehavior; /** * The collection where entities will be moved to. Only specify a value if you * need to move an entity to another collection. @@ -49,6 +53,8 @@ export type EntityCreateOrUpdateParameters = EntityCreateOrUpdateQueryParam & RequestParameters; export interface EntityListByGuidsQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** An array of GUIDs of entities to list. This parameter needs to be formatted as multi collection, we provide buildMultiCollection from serializeHelper.ts to help, you will probably need to set skipUrlEncoding as true when sending the request */ guid: string; /** Whether to return minimal information for referred entities. */ @@ -61,13 +67,17 @@ export interface EntityListByGuidsQueryParam { queryParameters: EntityListByGuidsQueryParamProperties; } -export type EntityListByGuidsParameters = EntityListByGuidsQueryParam & RequestParameters; +export type EntityListByGuidsParameters = EntityListByGuidsQueryParam & + RequestParameters; export interface EntityBulkCreateOrUpdateBodyParam { - body?: AtlasEntitiesWithExtInfo; + /** Body parameter. */ + body: AtlasEntitiesWithExtInfo; } export interface EntityBulkCreateOrUpdateQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** * The collection where entities will be moved to. Only specify a value if you * need to move an entity to another collection. @@ -76,19 +86,18 @@ export interface EntityBulkCreateOrUpdateQueryParamProperties { /** * Used to define the update behavior for business attributes when updating * entities. - * - * Possible values: "ignore", "replace", "merge" */ - businessAttributeUpdateBehavior?: string; + businessAttributeUpdateBehavior?: BusinessAttributeUpdateBehavior; } export interface EntityBulkCreateOrUpdateQueryParam { queryParameters?: EntityBulkCreateOrUpdateQueryParamProperties; } -export type EntityBulkCreateOrUpdateParameters = EntityBulkCreateOrUpdateQueryParam & - EntityBulkCreateOrUpdateBodyParam & - RequestParameters; +export type EntityBulkCreateOrUpdateParameters = + EntityBulkCreateOrUpdateQueryParam & + EntityBulkCreateOrUpdateBodyParam & + RequestParameters; export interface EntityBulkDeleteQueryParamProperties { /** An array of GUIDs of entities to delete. This parameter needs to be formatted as multi collection, we provide buildMultiCollection from serializeHelper.ts to help, you will probably need to set skipUrlEncoding as true when sending the request */ @@ -99,14 +108,16 @@ export interface EntityBulkDeleteQueryParam { queryParameters: EntityBulkDeleteQueryParamProperties; } -export type EntityBulkDeleteParameters = EntityBulkDeleteQueryParam & RequestParameters; +export type EntityBulkDeleteParameters = EntityBulkDeleteQueryParam & + RequestParameters; export interface EntityAddClassificationBodyParam { - body?: ClassificationAssociateOptions; + /** Body parameter. */ + body: ClassificationAssociateOptions; } -export type EntityAddClassificationParameters = EntityAddClassificationBodyParam & - RequestParameters; +export type EntityAddClassificationParameters = + EntityAddClassificationBodyParam & RequestParameters; export interface EntityGetQueryParamProperties { /** Whether to return minimal information for referred entities. */ @@ -149,16 +160,16 @@ export interface EntityAddClassificationsBodyParam { body: Array; } -export type EntityAddClassificationsParameters = EntityAddClassificationsBodyParam & - RequestParameters; +export type EntityAddClassificationsParameters = + EntityAddClassificationsBodyParam & RequestParameters; export interface EntityUpdateClassificationsBodyParam { /** An array of classifications to be updated. */ body: Array; } -export type EntityUpdateClassificationsParameters = EntityUpdateClassificationsBodyParam & - RequestParameters; +export type EntityUpdateClassificationsParameters = + EntityUpdateClassificationsBodyParam & RequestParameters; export interface EntityGetByUniqueAttributesQueryParamProperties { /** Whether to return minimal information for referred entities. */ @@ -176,11 +187,12 @@ export interface EntityGetByUniqueAttributesQueryParam { queryParameters?: EntityGetByUniqueAttributesQueryParamProperties; } -export type EntityGetByUniqueAttributesParameters = EntityGetByUniqueAttributesQueryParam & - RequestParameters; +export type EntityGetByUniqueAttributesParameters = + EntityGetByUniqueAttributesQueryParam & RequestParameters; export interface EntityPartialUpdateByUniqueAttributesBodyParam { - body?: AtlasEntityWithExtInfo; + /** Body parameter. */ + body: AtlasEntityWithExtInfo; } export interface EntityPartialUpdateByUniqueAttributesQueryParamProperties { @@ -212,8 +224,8 @@ export interface EntityDeleteByUniqueAttributeQueryParam { queryParameters?: EntityDeleteByUniqueAttributeQueryParamProperties; } -export type EntityDeleteByUniqueAttributeParameters = EntityDeleteByUniqueAttributeQueryParam & - RequestParameters; +export type EntityDeleteByUniqueAttributeParameters = + EntityDeleteByUniqueAttributeQueryParam & RequestParameters; export interface EntityRemoveClassificationByUniqueAttributeQueryParamProperties { /** @@ -275,11 +287,12 @@ export type EntityUpdateClassificationsByUniqueAttributeParameters = RequestParameters; export interface EntityBulkSetClassificationsBodyParam { - body?: AtlasEntityHeaders; + /** Body parameter. */ + body: AtlasEntityHeaders; } -export type EntityBulkSetClassificationsParameters = EntityBulkSetClassificationsBodyParam & - RequestParameters; +export type EntityBulkSetClassificationsParameters = + EntityBulkSetClassificationsBodyParam & RequestParameters; export interface EntityListByUniqueAttributesQueryParamProperties { /** Whether to return minimal information for referred entities. */ @@ -298,8 +311,8 @@ export interface EntityListByUniqueAttributesQueryParam { queryParameters?: EntityListByUniqueAttributesQueryParamProperties; } -export type EntityListByUniqueAttributesParameters = EntityListByUniqueAttributesQueryParam & - RequestParameters; +export type EntityListByUniqueAttributesParameters = + EntityListByUniqueAttributesQueryParam & RequestParameters; export type EntityGetHeaderParameters = RequestParameters; export interface EntityRemoveBusinessMetadataBodyParam { @@ -307,8 +320,8 @@ export interface EntityRemoveBusinessMetadataBodyParam { body: Record>; } -export type EntityRemoveBusinessMetadataParameters = EntityRemoveBusinessMetadataBodyParam & - RequestParameters; +export type EntityRemoveBusinessMetadataParameters = + EntityRemoveBusinessMetadataBodyParam & RequestParameters; export interface EntityAddOrUpdateBusinessMetadataBodyParam { /** BusinessMetadata payload */ @@ -347,10 +360,12 @@ export interface EntityAddOrUpdateBusinessMetadataAttributesBodyParam { export type EntityAddOrUpdateBusinessMetadataAttributesParameters = EntityAddOrUpdateBusinessMetadataAttributesBodyParam & RequestParameters; -export type EntityGetSampleBusinessMetadataTemplateParameters = RequestParameters; +export type EntityGetSampleBusinessMetadataTemplateParameters = + RequestParameters; export interface EntityImportBusinessMetadataBodyParam { - body?: BusinessMetadataOptions; + /** Body parameter. */ + body: BusinessMetadataOptions; } export interface EntityImportBusinessMetadataMediaTypesParam { @@ -358,30 +373,34 @@ export interface EntityImportBusinessMetadataMediaTypesParam { contentType: "multipart/form-data"; } -export type EntityImportBusinessMetadataParameters = EntityImportBusinessMetadataMediaTypesParam & - EntityImportBusinessMetadataBodyParam & - RequestParameters; +export type EntityImportBusinessMetadataParameters = + EntityImportBusinessMetadataMediaTypesParam & + EntityImportBusinessMetadataBodyParam & + RequestParameters; export interface EntityRemoveLabelsBodyParam { /** set of labels to be deleted */ body?: string[]; } -export type EntityRemoveLabelsParameters = EntityRemoveLabelsBodyParam & RequestParameters; +export type EntityRemoveLabelsParameters = EntityRemoveLabelsBodyParam & + RequestParameters; export interface EntitySetLabelsBodyParam { /** set of labels to be set to the entity */ body?: string[]; } -export type EntitySetLabelsParameters = EntitySetLabelsBodyParam & RequestParameters; +export type EntitySetLabelsParameters = EntitySetLabelsBodyParam & + RequestParameters; export interface EntityAddLabelBodyParam { /** set of labels to be added */ body?: string[]; } -export type EntityAddLabelParameters = EntityAddLabelBodyParam & RequestParameters; +export type EntityAddLabelParameters = EntityAddLabelBodyParam & + RequestParameters; export interface EntityRemoveLabelsByUniqueAttributeBodyParam { /** set of labels to be deleted */ @@ -450,10 +469,13 @@ export type EntityAddLabelsByUniqueAttributeParameters = RequestParameters; export interface EntityMoveEntitiesToCollectionBodyParam { - body?: MoveEntitiesOptions; + /** Body parameter. */ + body: MoveEntitiesOptions; } export interface EntityMoveEntitiesToCollectionQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; /** The collection where entities will be moved to. */ collectionId: string; } @@ -462,11 +484,14 @@ export interface EntityMoveEntitiesToCollectionQueryParam { queryParameters: EntityMoveEntitiesToCollectionQueryParamProperties; } -export type EntityMoveEntitiesToCollectionParameters = EntityMoveEntitiesToCollectionQueryParam & - EntityMoveEntitiesToCollectionBodyParam & - RequestParameters; +export type EntityMoveEntitiesToCollectionParameters = + EntityMoveEntitiesToCollectionQueryParam & + EntityMoveEntitiesToCollectionBodyParam & + RequestParameters; export interface GlossaryListQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** The page size - by default there is no paging. */ limit?: number; /** The offset for pagination purpose. */ @@ -484,31 +509,37 @@ export interface GlossaryListQueryParam { export type GlossaryListParameters = GlossaryListQueryParam & RequestParameters; export interface GlossaryCreateBodyParam { - body?: AtlasGlossary; + /** Body parameter. */ + body: AtlasGlossary; } -export type GlossaryCreateParameters = GlossaryCreateBodyParam & RequestParameters; +export type GlossaryCreateParameters = GlossaryCreateBodyParam & + RequestParameters; export interface GlossaryCreateCategoriesBodyParam { /** An array of glossary category definitions to be created. */ body: Array; } -export type GlossaryCreateCategoriesParameters = GlossaryCreateCategoriesBodyParam & - RequestParameters; +export type GlossaryCreateCategoriesParameters = + GlossaryCreateCategoriesBodyParam & RequestParameters; export interface GlossaryCreateCategoryBodyParam { - body?: AtlasGlossaryCategory; + /** Body parameter. */ + body: AtlasGlossaryCategory; } -export type GlossaryCreateCategoryParameters = GlossaryCreateCategoryBodyParam & RequestParameters; +export type GlossaryCreateCategoryParameters = GlossaryCreateCategoryBodyParam & + RequestParameters; export type GlossaryGetCategoryParameters = RequestParameters; export interface GlossaryUpdateCategoryBodyParam { - body?: AtlasGlossaryCategory; + /** Body parameter. */ + body: AtlasGlossaryCategory; } -export type GlossaryUpdateCategoryParameters = GlossaryUpdateCategoryBodyParam & RequestParameters; +export type GlossaryUpdateCategoryParameters = GlossaryUpdateCategoryBodyParam & + RequestParameters; export type GlossaryDeleteCategoryParameters = RequestParameters; export interface GlossaryPartialUpdateCategoryBodyParam { @@ -519,8 +550,8 @@ export interface GlossaryPartialUpdateCategoryBodyParam { body: Record; } -export type GlossaryPartialUpdateCategoryParameters = GlossaryPartialUpdateCategoryBodyParam & - RequestParameters; +export type GlossaryPartialUpdateCategoryParameters = + GlossaryPartialUpdateCategoryBodyParam & RequestParameters; export interface GlossaryListRelatedCategoriesQueryParamProperties { /** The page size - by default there is no paging. */ @@ -535,8 +566,8 @@ export interface GlossaryListRelatedCategoriesQueryParam { queryParameters?: GlossaryListRelatedCategoriesQueryParamProperties; } -export type GlossaryListRelatedCategoriesParameters = GlossaryListRelatedCategoriesQueryParam & - RequestParameters; +export type GlossaryListRelatedCategoriesParameters = + GlossaryListRelatedCategoriesQueryParam & RequestParameters; export interface GlossaryListCategoryTermsQueryParamProperties { /** The page size - by default there is no paging. */ @@ -551,11 +582,12 @@ export interface GlossaryListCategoryTermsQueryParam { queryParameters?: GlossaryListCategoryTermsQueryParamProperties; } -export type GlossaryListCategoryTermsParameters = GlossaryListCategoryTermsQueryParam & - RequestParameters; +export type GlossaryListCategoryTermsParameters = + GlossaryListCategoryTermsQueryParam & RequestParameters; export interface GlossaryCreateTermBodyParam { - body?: AtlasGlossaryTerm; + /** Body parameter. */ + body: AtlasGlossaryTerm; } export interface GlossaryCreateTermQueryParamProperties { @@ -570,13 +602,27 @@ export interface GlossaryCreateTermQueryParam { export type GlossaryCreateTermParameters = GlossaryCreateTermQueryParam & GlossaryCreateTermBodyParam & RequestParameters; -export type GlossaryGetTermParameters = RequestParameters; + +export interface GlossaryGetTermQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; +} + +export interface GlossaryGetTermQueryParam { + queryParameters?: GlossaryGetTermQueryParamProperties; +} + +export type GlossaryGetTermParameters = GlossaryGetTermQueryParam & + RequestParameters; export interface GlossaryUpdateTermBodyParam { - body?: AtlasGlossaryTerm; + /** Body parameter. */ + body: AtlasGlossaryTerm; } export interface GlossaryUpdateTermQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** Whether include term hierarchy */ includeTermHierarchy?: boolean; } @@ -599,6 +645,8 @@ export interface GlossaryPartialUpdateTermBodyParam { } export interface GlossaryPartialUpdateTermQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** Whether include term hierarchy */ includeTermHierarchy?: boolean; } @@ -607,9 +655,10 @@ export interface GlossaryPartialUpdateTermQueryParam { queryParameters?: GlossaryPartialUpdateTermQueryParamProperties; } -export type GlossaryPartialUpdateTermParameters = GlossaryPartialUpdateTermQueryParam & - GlossaryPartialUpdateTermBodyParam & - RequestParameters; +export type GlossaryPartialUpdateTermParameters = + GlossaryPartialUpdateTermQueryParam & + GlossaryPartialUpdateTermBodyParam & + RequestParameters; export interface GlossaryCreateTermsBodyParam { /** An array of glossary term definitions to be created in bulk. */ @@ -617,6 +666,8 @@ export interface GlossaryCreateTermsBodyParam { } export interface GlossaryCreateTermsQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** Whether include term hierarchy */ includeTermHierarchy?: boolean; } @@ -650,8 +701,8 @@ export interface GlossaryAssignTermToEntitiesBodyParam { body: Array; } -export type GlossaryAssignTermToEntitiesParameters = GlossaryAssignTermToEntitiesBodyParam & - RequestParameters; +export type GlossaryAssignTermToEntitiesParameters = + GlossaryAssignTermToEntitiesBodyParam & RequestParameters; export interface GlossaryDeleteTermAssignmentFromEntitiesBodyParam { /** An array of related object IDs from which the term has to be dissociated. */ @@ -662,6 +713,8 @@ export type GlossaryDeleteTermAssignmentFromEntitiesParameters = GlossaryDeleteTermAssignmentFromEntitiesBodyParam & RequestParameters; export interface GlossaryListRelatedTermsQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** The page size - by default there is no paging. */ limit?: number; /** The offset for pagination purpose. */ @@ -674,15 +727,18 @@ export interface GlossaryListRelatedTermsQueryParam { queryParameters?: GlossaryListRelatedTermsQueryParamProperties; } -export type GlossaryListRelatedTermsParameters = GlossaryListRelatedTermsQueryParam & - RequestParameters; +export type GlossaryListRelatedTermsParameters = + GlossaryListRelatedTermsQueryParam & RequestParameters; export type GlossaryGetParameters = RequestParameters; export interface GlossaryUpdateBodyParam { - body?: AtlasGlossary; + /** Body parameter. */ + body: AtlasGlossary; } export interface GlossaryUpdateQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** Whether ignore terms and categories */ ignoreTermsAndCategories?: boolean; } @@ -709,7 +765,8 @@ export interface GlossaryListCategoriesQueryParam { queryParameters?: GlossaryListCategoriesQueryParamProperties; } -export type GlossaryListCategoriesParameters = GlossaryListCategoriesQueryParam & RequestParameters; +export type GlossaryListCategoriesParameters = + GlossaryListCategoriesQueryParam & RequestParameters; export interface GlossaryListCategoriesHeadersQueryParamProperties { /** The page size - by default there is no paging. */ @@ -724,9 +781,20 @@ export interface GlossaryListCategoriesHeadersQueryParam { queryParameters?: GlossaryListCategoriesHeadersQueryParamProperties; } -export type GlossaryListCategoriesHeadersParameters = GlossaryListCategoriesHeadersQueryParam & +export type GlossaryListCategoriesHeadersParameters = + GlossaryListCategoriesHeadersQueryParam & RequestParameters; + +export interface GlossaryGetDetailedQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; +} + +export interface GlossaryGetDetailedQueryParam { + queryParameters?: GlossaryGetDetailedQueryParamProperties; +} + +export type GlossaryGetDetailedParameters = GlossaryGetDetailedQueryParam & RequestParameters; -export type GlossaryGetDetailedParameters = RequestParameters; export interface GlossaryPartialUpdateBodyParam { /** @@ -737,6 +805,8 @@ export interface GlossaryPartialUpdateBodyParam { } export interface GlossaryPartialUpdateQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** Whether ignore terms and categories */ ignoreTermsAndCategories?: boolean; } @@ -750,6 +820,8 @@ export type GlossaryPartialUpdateParameters = GlossaryPartialUpdateQueryParam & RequestParameters; export interface GlossaryListTermsQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** The page size - by default there is no paging. */ limit?: number; /** The offset for pagination purpose. */ @@ -762,7 +834,8 @@ export interface GlossaryListTermsQueryParam { queryParameters?: GlossaryListTermsQueryParamProperties; } -export type GlossaryListTermsParameters = GlossaryListTermsQueryParam & RequestParameters; +export type GlossaryListTermsParameters = GlossaryListTermsQueryParam & + RequestParameters; export interface GlossaryListTermHeadersQueryParamProperties { /** The page size - by default there is no paging. */ @@ -777,36 +850,68 @@ export interface GlossaryListTermHeadersQueryParam { queryParameters?: GlossaryListTermHeadersQueryParamProperties; } -export type GlossaryListTermHeadersParameters = GlossaryListTermHeadersQueryParam & - RequestParameters; +export type GlossaryListTermHeadersParameters = + GlossaryListTermHeadersQueryParam & RequestParameters; export interface DiscoveryQueryBodyParam { - body?: QueryOptions; + /** Body parameter. */ + body: QueryOptions; } -export type DiscoveryQueryParameters = DiscoveryQueryBodyParam & RequestParameters; +export interface DiscoveryQueryQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; +} + +export interface DiscoveryQueryQueryParam { + queryParameters: DiscoveryQueryQueryParamProperties; +} + +export type DiscoveryQueryParameters = DiscoveryQueryQueryParam & + DiscoveryQueryBodyParam & + RequestParameters; export interface DiscoverySuggestBodyParam { - body?: SuggestOptions; + /** Body parameter. */ + body: SuggestOptions; } -export type DiscoverySuggestParameters = DiscoverySuggestBodyParam & RequestParameters; +export interface DiscoverySuggestQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; +} + +export interface DiscoverySuggestQueryParam { + queryParameters: DiscoverySuggestQueryParamProperties; +} + +export type DiscoverySuggestParameters = DiscoverySuggestQueryParam & + DiscoverySuggestBodyParam & + RequestParameters; export interface DiscoveryAutoCompleteBodyParam { - body?: AutoCompleteOptions; + /** Body parameter. */ + body: AutoCompleteOptions; +} + +export interface DiscoveryAutoCompleteQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; +} + +export interface DiscoveryAutoCompleteQueryParam { + queryParameters: DiscoveryAutoCompleteQueryParamProperties; } -export type DiscoveryAutoCompleteParameters = DiscoveryAutoCompleteBodyParam & RequestParameters; +export type DiscoveryAutoCompleteParameters = DiscoveryAutoCompleteQueryParam & + DiscoveryAutoCompleteBodyParam & + RequestParameters; export interface LineageGetQueryParamProperties { /** The number of hops for lineage. */ depth?: number; - /** - * The direction of the lineage, which could be INPUT, OUTPUT or BOTH. - * - * Possible values: "INPUT", "OUTPUT", "BOTH" - */ - direction: string; + /** The direction of the lineage, which could be INPUT, OUTPUT or BOTH. */ + direction: LineageDirection; } export interface LineageGetQueryParam { @@ -816,12 +921,10 @@ export interface LineageGetQueryParam { export type LineageGetParameters = LineageGetQueryParam & RequestParameters; export interface LineageGetNextPageQueryParamProperties { - /** - * The direction of the lineage, which could be INPUT, OUTPUT or BOTH. - * - * Possible values: "INPUT", "OUTPUT", "BOTH" - */ - direction: string; + /** The API version to use for this operation. */ + "api-version": string; + /** The direction of the lineage, which could be INPUT, OUTPUT or BOTH. */ + direction: LineageDirection; /** The offset for pagination purpose. */ offset?: number; /** The page size - by default there is no paging. */ @@ -832,17 +935,14 @@ export interface LineageGetNextPageQueryParam { queryParameters: LineageGetNextPageQueryParamProperties; } -export type LineageGetNextPageParameters = LineageGetNextPageQueryParam & RequestParameters; +export type LineageGetNextPageParameters = LineageGetNextPageQueryParam & + RequestParameters; export interface LineageGetByUniqueAttributeQueryParamProperties { /** The number of hops for lineage. */ depth?: number; - /** - * The direction of the lineage, which could be INPUT, OUTPUT or BOTH. - * - * Possible values: "INPUT", "OUTPUT", "BOTH" - */ - direction: string; + /** The direction of the lineage, which could be INPUT, OUTPUT or BOTH. */ + direction: LineageDirection; /** * The qualified name of the entity. (This is only an example. qualifiedName can * be changed to other unique attributes) @@ -854,20 +954,24 @@ export interface LineageGetByUniqueAttributeQueryParam { queryParameters: LineageGetByUniqueAttributeQueryParamProperties; } -export type LineageGetByUniqueAttributeParameters = LineageGetByUniqueAttributeQueryParam & - RequestParameters; +export type LineageGetByUniqueAttributeParameters = + LineageGetByUniqueAttributeQueryParam & RequestParameters; export interface RelationshipCreateBodyParam { - body?: AtlasRelationship; + /** Body parameter. */ + body: AtlasRelationship; } -export type RelationshipCreateParameters = RelationshipCreateBodyParam & RequestParameters; +export type RelationshipCreateParameters = RelationshipCreateBodyParam & + RequestParameters; export interface RelationshipUpdateBodyParam { - body?: AtlasRelationship; + /** Body parameter. */ + body: AtlasRelationship; } -export type RelationshipUpdateParameters = RelationshipUpdateBodyParam & RequestParameters; +export type RelationshipUpdateParameters = RelationshipUpdateBodyParam & + RequestParameters; export interface RelationshipGetQueryParamProperties { /** Limits whether includes extended information. */ @@ -878,7 +982,8 @@ export interface RelationshipGetQueryParam { queryParameters?: RelationshipGetQueryParamProperties; } -export type RelationshipGetParameters = RelationshipGetQueryParam & RequestParameters; +export type RelationshipGetParameters = RelationshipGetQueryParam & + RequestParameters; export type RelationshipDeleteParameters = RequestParameters; export type TypeGetBusinessMetadataDefByGuidParameters = RequestParameters; export type TypeGetBusinessMetadataDefByNameParameters = RequestParameters; @@ -897,18 +1002,16 @@ export type TypeGetByNameParameters = RequestParameters; export type TypeDeleteParameters = RequestParameters; export interface TypeListQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** * Whether include termtemplatedef when return all typedefs. * This is always true * when search filter type=term_template */ includeTermTemplate?: boolean; - /** - * Typedef name as search filter when get typedefs. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - type?: string; + /** Typedef name as search filter when get typedefs. */ + type?: TypeCategory; } export interface TypeListQueryParam { @@ -918,42 +1021,69 @@ export interface TypeListQueryParam { export type TypeListParameters = TypeListQueryParam & RequestParameters; export interface TypeBulkCreateBodyParam { - body?: AtlasTypesDef; + /** Body parameter. */ + body: AtlasTypesDef; } -export type TypeBulkCreateParameters = TypeBulkCreateBodyParam & RequestParameters; +export type TypeBulkCreateParameters = TypeBulkCreateBodyParam & + RequestParameters; export interface TypeBulkUpdateBodyParam { - body?: AtlasTypesDef; + /** Body parameter. */ + body: AtlasTypesDef; } -export type TypeBulkUpdateParameters = TypeBulkUpdateBodyParam & RequestParameters; +export type TypeBulkUpdateParameters = TypeBulkUpdateBodyParam & + RequestParameters; export interface TypeBulkDeleteBodyParam { - body?: AtlasTypesDef; + /** Body parameter. */ + body: AtlasTypesDef; } -export type TypeBulkDeleteParameters = TypeBulkDeleteBodyParam & RequestParameters; +export type TypeBulkDeleteParameters = TypeBulkDeleteBodyParam & + RequestParameters; export interface TypeListHeadersQueryParamProperties { + /** The API version to use for this operation. */ + "api-version"?: string; /** * Whether include termtemplatedef when return all typedefs. * This is always true * when search filter type=term_template */ includeTermTemplate?: boolean; - /** - * Typedef name as search filter when get typedefs. - * - * Possible values: "PRIMITIVE", "OBJECT_ID_TYPE", "ENUM", "STRUCT", "CLASSIFICATION", "ENTITY", "ARRAY", "MAP", "RELATIONSHIP", "TERM_TEMPLATE" - */ - type?: string; + /** Typedef name as search filter when get typedefs. */ + type?: TypeCategory; } export interface TypeListHeadersQueryParam { queryParameters?: TypeListHeadersQueryParamProperties; } -export type TypeListHeadersParameters = TypeListHeadersQueryParam & RequestParameters; -export type TypeGetTermTemplateDefByGuidParameters = RequestParameters; -export type TypeGetTermTemplateDefByNameParameters = RequestParameters; +export type TypeListHeadersParameters = TypeListHeadersQueryParam & + RequestParameters; + +export interface TypeGetTermTemplateDefByGuidQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; +} + +export interface TypeGetTermTemplateDefByGuidQueryParam { + queryParameters: TypeGetTermTemplateDefByGuidQueryParamProperties; +} + +export type TypeGetTermTemplateDefByGuidParameters = + TypeGetTermTemplateDefByGuidQueryParam & RequestParameters; + +export interface TypeGetTermTemplateDefByNameQueryParamProperties { + /** The API version to use for this operation. */ + "api-version": string; +} + +export interface TypeGetTermTemplateDefByNameQueryParam { + queryParameters: TypeGetTermTemplateDefByNameQueryParamProperties; +} + +export type TypeGetTermTemplateDefByNameParameters = + TypeGetTermTemplateDefByNameQueryParam & RequestParameters; diff --git a/sdk/purview/purview-datamap-rest/src/purviewDataMapClient.ts b/sdk/purview/purview-datamap-rest/src/purviewDataMapClient.ts index 1a1b4cc08f2b..fcc523943789 100644 --- a/sdk/purview/purview-datamap-rest/src/purviewDataMapClient.ts +++ b/sdk/purview/purview-datamap-rest/src/purviewDataMapClient.ts @@ -2,24 +2,27 @@ // Licensed under the MIT license. import { getClient, ClientOptions } from "@azure-rest/core-client"; -import { logger } from "./logger"; +import { logger } from "./logger.js"; import { TokenCredential } from "@azure/core-auth"; -import { PurviewDataMapClient } from "./clientDefinitions"; +import { PurviewDataMapClient } from "./clientDefinitions.js"; + +/** The optional parameters for the client */ +export interface PurviewDataMapClientOptions extends ClientOptions {} /** * Initialize a new instance of `PurviewDataMapClient` - * @param endpoint - A sequence of textual characters. + * @param endpointParam - A sequence of textual characters. * @param credentials - uniquely identify client credential * @param options - the parameter for all optional parameters */ export default function createClient( - endpoint: string, + endpointParam: string, credentials: TokenCredential, - options: ClientOptions = {}, + options: PurviewDataMapClientOptions = {}, ): PurviewDataMapClient { - const baseUrl = options.baseUrl ?? `${endpoint}/datamap/api`; - options.apiVersion = options.apiVersion ?? "2023-09-01"; - const userAgentInfo = `azsdk-js-purview-datamap-rest/1.0.0-beta.2`; + const endpointUrl = + options.endpoint ?? options.baseUrl ?? `${endpointParam}/datamap/api`; + const userAgentInfo = `azsdk-js-purview-datamap-rest/1.0.0-beta.1`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${userAgentInfo}` @@ -33,11 +36,23 @@ export default function createClient( logger: options.loggingOptions?.logger ?? logger.info, }, credentials: { - scopes: options.credentials?.scopes ?? ["https://purview.azure.net/.default"], + scopes: options.credentials?.scopes ?? [ + "https://purview.azure.net/.default", + ], }, }; + const client = getClient( + endpointUrl, + credentials, + options, + ) as PurviewDataMapClient; - const client = getClient(baseUrl, credentials, options) as PurviewDataMapClient; + client.pipeline.removePolicy({ name: "ApiVersionPolicy" }); + if (options.apiVersion) { + logger.warning( + "This client does not support client api-version, please change it at the operation level", + ); + } return client; } diff --git a/sdk/purview/purview-datamap-rest/src/responses.ts b/sdk/purview/purview-datamap-rest/src/responses.ts index c86e35ad83c1..ea6b864660ab 100644 --- a/sdk/purview/purview-datamap-rest/src/responses.ts +++ b/sdk/purview/purview-datamap-rest/src/responses.ts @@ -1,6 +1,7 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT license. +import { RawHttpHeaders } from "@azure/core-rest-pipeline"; import { HttpResponse } from "@azure-rest/core-client"; import { EntityMutationResultOutput, @@ -13,10 +14,10 @@ import { BulkImportResultOutput, AtlasGlossaryOutput, AtlasGlossaryCategoryOutput, + AtlasRelatedCategoryHeaderOutput, AtlasRelatedTermHeaderOutput, AtlasGlossaryTermOutput, AtlasRelatedObjectIdOutput, - AtlasRelatedCategoryHeaderOutput, AtlasGlossaryExtInfoOutput, QueryResultOutput, SuggestResultOutput, @@ -34,7 +35,7 @@ import { AtlasTypesDefOutput, AtlasTypeDefHeaderOutput, TermTemplateDefOutput, -} from "./outputModels"; +} from "./outputModels.js"; /** The request has succeeded. */ export interface EntityCreateOrUpdate200Response extends HttpResponse { @@ -102,23 +103,25 @@ export interface EntityGetDefaultResponse extends HttpResponse { } /** The request has succeeded. */ -export interface EntityPartialUpdateAttributeByGuid200Response extends HttpResponse { +export interface EntityPartialUpdateAttributeByGuid200Response + extends HttpResponse { status: "200"; body: EntityMutationResultOutput; } -export interface EntityPartialUpdateAttributeByGuidDefaultResponse extends HttpResponse { +export interface EntityPartialUpdateAttributeByGuidDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface EntityDeleteOperation200Response extends HttpResponse { +export interface EntityDelete200Response extends HttpResponse { status: "200"; body: EntityMutationResultOutput; } -export interface EntityDeleteOperationDefaultResponse extends HttpResponse { +export interface EntityDeleteDefaultResponse extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -139,7 +142,8 @@ export interface EntityRemoveClassification204Response extends HttpResponse { status: "204"; } -export interface EntityRemoveClassificationDefaultResponse extends HttpResponse { +export interface EntityRemoveClassificationDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -170,7 +174,8 @@ export interface EntityUpdateClassifications204Response extends HttpResponse { status: "204"; } -export interface EntityUpdateClassificationsDefaultResponse extends HttpResponse { +export interface EntityUpdateClassificationsDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -181,18 +186,21 @@ export interface EntityGetByUniqueAttributes200Response extends HttpResponse { body: AtlasEntityWithExtInfoOutput; } -export interface EntityGetByUniqueAttributesDefaultResponse extends HttpResponse { +export interface EntityGetByUniqueAttributesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface EntityPartialUpdateByUniqueAttributes200Response extends HttpResponse { +export interface EntityPartialUpdateByUniqueAttributes200Response + extends HttpResponse { status: "200"; body: EntityMutationResultOutput; } -export interface EntityPartialUpdateByUniqueAttributesDefaultResponse extends HttpResponse { +export interface EntityPartialUpdateByUniqueAttributesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -203,37 +211,44 @@ export interface EntityDeleteByUniqueAttribute200Response extends HttpResponse { body: EntityMutationResultOutput; } -export interface EntityDeleteByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityDeleteByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityRemoveClassificationByUniqueAttribute204Response extends HttpResponse { +export interface EntityRemoveClassificationByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntityRemoveClassificationByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityRemoveClassificationByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityAddClassificationsByUniqueAttribute204Response extends HttpResponse { +export interface EntityAddClassificationsByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntityAddClassificationsByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityAddClassificationsByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityUpdateClassificationsByUniqueAttribute204Response extends HttpResponse { +export interface EntityUpdateClassificationsByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntityUpdateClassificationsByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityUpdateClassificationsByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -244,7 +259,8 @@ export interface EntityBulkSetClassifications200Response extends HttpResponse { body: string[]; } -export interface EntityBulkSetClassificationsDefaultResponse extends HttpResponse { +export interface EntityBulkSetClassificationsDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -255,7 +271,8 @@ export interface EntityListByUniqueAttributes200Response extends HttpResponse { body: AtlasEntitiesWithExtInfoOutput; } -export interface EntityListByUniqueAttributesDefaultResponse extends HttpResponse { +export interface EntityListByUniqueAttributesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -276,49 +293,63 @@ export interface EntityRemoveBusinessMetadata204Response extends HttpResponse { status: "204"; } -export interface EntityRemoveBusinessMetadataDefaultResponse extends HttpResponse { +export interface EntityRemoveBusinessMetadataDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityAddOrUpdateBusinessMetadata204Response extends HttpResponse { +export interface EntityAddOrUpdateBusinessMetadata204Response + extends HttpResponse { status: "204"; } -export interface EntityAddOrUpdateBusinessMetadataDefaultResponse extends HttpResponse { +export interface EntityAddOrUpdateBusinessMetadataDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityRemoveBusinessMetadataAttributes204Response extends HttpResponse { +export interface EntityRemoveBusinessMetadataAttributes204Response + extends HttpResponse { status: "204"; } -export interface EntityRemoveBusinessMetadataAttributesDefaultResponse extends HttpResponse { +export interface EntityRemoveBusinessMetadataAttributesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityAddOrUpdateBusinessMetadataAttributes204Response extends HttpResponse { +export interface EntityAddOrUpdateBusinessMetadataAttributes204Response + extends HttpResponse { status: "204"; } -export interface EntityAddOrUpdateBusinessMetadataAttributesDefaultResponse extends HttpResponse { +export interface EntityAddOrUpdateBusinessMetadataAttributesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } +export interface EntityGetSampleBusinessMetadataTemplate200Headers { + "content-type": "application/octet-stream"; +} + /** The request has succeeded. */ -export interface EntityGetSampleBusinessMetadataTemplate200Response extends HttpResponse { +export interface EntityGetSampleBusinessMetadataTemplate200Response + extends HttpResponse { status: "200"; /** Value may contain any sequence of octets */ body: Uint8Array; + headers: RawHttpHeaders & EntityGetSampleBusinessMetadataTemplate200Headers; } -export interface EntityGetSampleBusinessMetadataTemplateDefaultResponse extends HttpResponse { +export interface EntityGetSampleBusinessMetadataTemplateDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -329,7 +360,8 @@ export interface EntityImportBusinessMetadata200Response extends HttpResponse { body: BulkImportResultOutput; } -export interface EntityImportBusinessMetadataDefaultResponse extends HttpResponse { +export interface EntityImportBusinessMetadataDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -365,42 +397,50 @@ export interface EntityAddLabelDefaultResponse extends HttpResponse { } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityRemoveLabelsByUniqueAttribute204Response extends HttpResponse { +export interface EntityRemoveLabelsByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntityRemoveLabelsByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityRemoveLabelsByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntitySetLabelsByUniqueAttribute204Response extends HttpResponse { +export interface EntitySetLabelsByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntitySetLabelsByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntitySetLabelsByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface EntityAddLabelsByUniqueAttribute204Response extends HttpResponse { +export interface EntityAddLabelsByUniqueAttribute204Response + extends HttpResponse { status: "204"; } -export interface EntityAddLabelsByUniqueAttributeDefaultResponse extends HttpResponse { +export interface EntityAddLabelsByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface EntityMoveEntitiesToCollection200Response extends HttpResponse { +export interface EntityMoveEntitiesToCollection200Response + extends HttpResponse { status: "200"; body: EntityMutationResultOutput; } -export interface EntityMoveEntitiesToCollectionDefaultResponse extends HttpResponse { +export interface EntityMoveEntitiesToCollectionDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -487,7 +527,8 @@ export interface GlossaryPartialUpdateCategory200Response extends HttpResponse { body: AtlasGlossaryCategoryOutput; } -export interface GlossaryPartialUpdateCategoryDefaultResponse extends HttpResponse { +export interface GlossaryPartialUpdateCategoryDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -498,7 +539,8 @@ export interface GlossaryListRelatedCategories200Response extends HttpResponse { body: Record>; } -export interface GlossaryListRelatedCategoriesDefaultResponse extends HttpResponse { +export interface GlossaryListRelatedCategoriesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -580,12 +622,14 @@ export interface GlossaryCreateTermsDefaultResponse extends HttpResponse { } /** The request has succeeded. */ -export interface GlossaryListEntitiesAssignedWithTerm200Response extends HttpResponse { +export interface GlossaryListEntitiesAssignedWithTerm200Response + extends HttpResponse { status: "200"; body: Array; } -export interface GlossaryListEntitiesAssignedWithTermDefaultResponse extends HttpResponse { +export interface GlossaryListEntitiesAssignedWithTermDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -595,17 +639,20 @@ export interface GlossaryAssignTermToEntities204Response extends HttpResponse { status: "204"; } -export interface GlossaryAssignTermToEntitiesDefaultResponse extends HttpResponse { +export interface GlossaryAssignTermToEntitiesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** There is no content to send for this request, but the headers may be useful. */ -export interface GlossaryDeleteTermAssignmentFromEntities204Response extends HttpResponse { +export interface GlossaryDeleteTermAssignmentFromEntities204Response + extends HttpResponse { status: "204"; } -export interface GlossaryDeleteTermAssignmentFromEntitiesDefaultResponse extends HttpResponse { +export interface GlossaryDeleteTermAssignmentFromEntitiesDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -644,11 +691,11 @@ export interface GlossaryUpdateDefaultResponse extends HttpResponse { } /** There is no content to send for this request, but the headers may be useful. */ -export interface GlossaryDeleteOperation204Response extends HttpResponse { +export interface GlossaryDelete204Response extends HttpResponse { status: "204"; } -export interface GlossaryDeleteOperationDefaultResponse extends HttpResponse { +export interface GlossaryDeleteDefaultResponse extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -670,7 +717,8 @@ export interface GlossaryListCategoriesHeaders200Response extends HttpResponse { body: Array; } -export interface GlossaryListCategoriesHeadersDefaultResponse extends HttpResponse { +export interface GlossaryListCategoriesHeadersDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -780,7 +828,8 @@ export interface LineageGetByUniqueAttribute200Response extends HttpResponse { body: AtlasLineageInfoOutput; } -export interface LineageGetByUniqueAttributeDefaultResponse extends HttpResponse { +export interface LineageGetByUniqueAttributeDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -819,55 +868,63 @@ export interface RelationshipGetDefaultResponse extends HttpResponse { } /** There is no content to send for this request, but the headers may be useful. */ -export interface RelationshipDeleteOperation204Response extends HttpResponse { +export interface RelationshipDelete204Response extends HttpResponse { status: "204"; } -export interface RelationshipDeleteOperationDefaultResponse extends HttpResponse { +export interface RelationshipDeleteDefaultResponse extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface TypeGetBusinessMetadataDefByGuid200Response extends HttpResponse { +export interface TypeGetBusinessMetadataDefByGuid200Response + extends HttpResponse { status: "200"; body: AtlasBusinessMetadataDefOutput; } -export interface TypeGetBusinessMetadataDefByGuidDefaultResponse extends HttpResponse { +export interface TypeGetBusinessMetadataDefByGuidDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface TypeGetBusinessMetadataDefByName200Response extends HttpResponse { +export interface TypeGetBusinessMetadataDefByName200Response + extends HttpResponse { status: "200"; body: AtlasBusinessMetadataDefOutput; } -export interface TypeGetBusinessMetadataDefByNameDefaultResponse extends HttpResponse { +export interface TypeGetBusinessMetadataDefByNameDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface TypeGetClassificationDefByGuid200Response extends HttpResponse { +export interface TypeGetClassificationDefByGuid200Response + extends HttpResponse { status: "200"; body: AtlasClassificationDefOutput; } -export interface TypeGetClassificationDefByGuidDefaultResponse extends HttpResponse { +export interface TypeGetClassificationDefByGuidDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } /** The request has succeeded. */ -export interface TypeGetClassificationDefByName200Response extends HttpResponse { +export interface TypeGetClassificationDefByName200Response + extends HttpResponse { status: "200"; body: AtlasClassificationDefOutput; } -export interface TypeGetClassificationDefByNameDefaultResponse extends HttpResponse { +export interface TypeGetClassificationDefByNameDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -922,7 +979,8 @@ export interface TypeGetRelationshipDefByGuid200Response extends HttpResponse { body: AtlasRelationshipDefOutput; } -export interface TypeGetRelationshipDefByGuidDefaultResponse extends HttpResponse { +export interface TypeGetRelationshipDefByGuidDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -933,7 +991,8 @@ export interface TypeGetRelationshipDefByName200Response extends HttpResponse { body: AtlasRelationshipDefOutput; } -export interface TypeGetRelationshipDefByNameDefaultResponse extends HttpResponse { +export interface TypeGetRelationshipDefByNameDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -983,11 +1042,11 @@ export interface TypeGetByNameDefaultResponse extends HttpResponse { } /** There is no content to send for this request, but the headers may be useful. */ -export interface TypeDeleteOperation204Response extends HttpResponse { +export interface TypeDelete204Response extends HttpResponse { status: "204"; } -export interface TypeDeleteOperationDefaultResponse extends HttpResponse { +export interface TypeDeleteDefaultResponse extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -1052,7 +1111,8 @@ export interface TypeGetTermTemplateDefByGuid200Response extends HttpResponse { body: TermTemplateDefOutput; } -export interface TypeGetTermTemplateDefByGuidDefaultResponse extends HttpResponse { +export interface TypeGetTermTemplateDefByGuidDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } @@ -1063,7 +1123,8 @@ export interface TypeGetTermTemplateDefByName200Response extends HttpResponse { body: TermTemplateDefOutput; } -export interface TypeGetTermTemplateDefByNameDefaultResponse extends HttpResponse { +export interface TypeGetTermTemplateDefByNameDefaultResponse + extends HttpResponse { status: string; body: AtlasErrorResponseOutput; } diff --git a/sdk/purview/purview-datamap-rest/src/serializeHelper.ts b/sdk/purview/purview-datamap-rest/src/serializeHelper.ts index 4a0a83f7ce0e..951b4a54e913 100644 --- a/sdk/purview/purview-datamap-rest/src/serializeHelper.ts +++ b/sdk/purview/purview-datamap-rest/src/serializeHelper.ts @@ -1,7 +1,10 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT license. -export function buildMultiCollection(items: string[], parameterName: string): string { +export function buildMultiCollection( + items: string[], + parameterName: string, +): string { return items .map((item, index) => { if (index === 0) { diff --git a/sdk/purview/purview-datamap-rest/test/public/sampleTest.spec.ts b/sdk/purview/purview-datamap-rest/test/public/sampleTest.spec.ts new file mode 100644 index 000000000000..344657d6f17e --- /dev/null +++ b/sdk/purview/purview-datamap-rest/test/public/sampleTest.spec.ts @@ -0,0 +1,21 @@ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT license. + +import { createRecorder } from "./utils/recordedClient.js"; +import { assert, beforeEach, afterEach, it, describe } from "vitest"; + +describe("My test", () => { + // let recorder: Recorder; + + beforeEach(async function () { + // recorder = await createRecorder(this); + }); + + afterEach(async function () { + // await recorder.stop(); + }); + + it("sample test", async function () { + assert.equal(1, 1); + }); +}); diff --git a/sdk/purview/purview-datamap-rest/test/public/utils/recordedClient.ts b/sdk/purview/purview-datamap-rest/test/public/utils/recordedClient.ts index 3383a88ccf3b..231e0b7c22fa 100644 --- a/sdk/purview/purview-datamap-rest/test/public/utils/recordedClient.ts +++ b/sdk/purview/purview-datamap-rest/test/public/utils/recordedClient.ts @@ -2,14 +2,10 @@ // Licensed under the MIT license. import { Context } from "mocha"; -import PurviewDataMap, { PurviewDataMapClient } from "../../../src"; -import { env, Recorder, RecorderStartOptions } from "@azure-tools/test-recorder"; -import { createTestCredential } from "@azure-tools/test-credential"; -import "./env"; -import { ClientOptions } from "@azure-rest/core-client"; +import { Recorder, RecorderStartOptions } from "@azure-tools/test-recorder"; const envSetupForPlayback: Record = { - ENDPOINT: "https://fakeAccount.purview.azure.com/", + ENDPOINT: "https://endpoint", AZURE_CLIENT_ID: "azure_client_id", AZURE_CLIENT_SECRET: "azure_client_secret", AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", @@ -30,18 +26,3 @@ export async function createRecorder(context: Context): Promise { await recorder.start(recorderEnvSetup); return recorder; } - -export async function createClient( - recorder: Recorder, - options?: ClientOptions, -): Promise { - const credential = createTestCredential(); - - return PurviewDataMap( - env.ENDPOINT ?? "", - credential, - recorder.configureClientOptions({ - options, - }), - ); -} diff --git a/sdk/purview/purview-datamap-rest/tsconfig.browser.config.json b/sdk/purview/purview-datamap-rest/tsconfig.browser.config.json new file mode 100644 index 000000000000..1b37aebc5457 --- /dev/null +++ b/sdk/purview/purview-datamap-rest/tsconfig.browser.config.json @@ -0,0 +1,10 @@ +{ + "extends": "./.tshy/build.json", + "include": ["./src/**/*.ts", "./src/**/*.mts", "./test/**/*.spec.ts"], + "exclude": ["./test/**/node/**/*.ts"], + "compilerOptions": { + "outDir": "./dist-test/browser", + "rootDir": ".", + "skipLibCheck": true + } +} diff --git a/sdk/purview/purview-datamap-rest/tsconfig.json b/sdk/purview/purview-datamap-rest/tsconfig.json index 064a66156b54..b21bfb510a9d 100644 --- a/sdk/purview/purview-datamap-rest/tsconfig.json +++ b/sdk/purview/purview-datamap-rest/tsconfig.json @@ -1,5 +1,15 @@ { "extends": "../../../tsconfig.package", - "compilerOptions": { "outDir": "./dist-esm", "declarationDir": "./types" }, - "include": ["src/**/*.ts", "./test/**/*.ts"] -} + "compilerOptions": { + "module": "NodeNext", + "moduleResolution": "NodeNext", + "rootDir": "." + }, + "include": [ + "./src/**/*.ts", + "./src/**/*.mts", + "./src/**/*.cts", + "test/**/*.ts", + "./test/**/*.ts" + ] +} \ No newline at end of file diff --git a/sdk/purview/purview-datamap-rest/tsp-location.yaml b/sdk/purview/purview-datamap-rest/tsp-location.yaml index 2a823d141089..17f38eab6ae4 100644 --- a/sdk/purview/purview-datamap-rest/tsp-location.yaml +++ b/sdk/purview/purview-datamap-rest/tsp-location.yaml @@ -1,5 +1,5 @@ directory: specification/purview/Azure.Analytics.Purview.DataMap +commit: 62f2c8a9ff7d25a917c7b9dd95326db9c3a8d620 repo: Azure/azure-rest-api-specs -commit: e4dd3e7e4d0402a81b2bef7dd754d3e46e8a8ab5 additionalDirectories: [] diff --git a/sdk/purview/purview-datamap-rest/vitest.browser.config.ts b/sdk/purview/purview-datamap-rest/vitest.browser.config.ts new file mode 100644 index 000000000000..cc2bbfc362c0 --- /dev/null +++ b/sdk/purview/purview-datamap-rest/vitest.browser.config.ts @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT license. + +import { defineConfig } from "vitest/config"; +import { relativeRecordingsPath } from "@azure-tools/test-recorder"; + +process.env.RECORDINGS_RELATIVE_PATH = relativeRecordingsPath(); + +export default defineConfig({ + define: { + "process.env": process.env, + }, + test: { + reporters: ["basic", "junit"], + outputFile: { + junit: "test-results.browser.xml", + }, + browser: { + enabled: true, + headless: true, + name: "chromium", + provider: "playwright", + }, + fakeTimers: { + toFake: ["setTimeout", "Date"], + }, + watch: false, + include: ["dist-test/browser/**/*.spec.js"], + coverage: { + include: ["dist-test/browser/**/*.spec.js"], + provider: "istanbul", + reporter: ["text", "json", "html"], + reportsDirectory: "coverage-browser", + }, + }, +}); diff --git a/sdk/purview/purview-datamap-rest/vitest.config.ts b/sdk/purview/purview-datamap-rest/vitest.config.ts new file mode 100644 index 000000000000..367c90fa4e72 --- /dev/null +++ b/sdk/purview/purview-datamap-rest/vitest.config.ts @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT license. + +import { defineConfig } from "vitest/config"; +import { relativeRecordingsPath } from "@azure-tools/test-recorder"; + +export default defineConfig({ + test: { + reporters: ["basic", "junit"], + outputFile: { + junit: "test-results.browser.xml", + }, + fakeTimers: { + toFake: ["setTimeout", "Date"], + }, + watch: false, + include: ["test/**/*.spec.ts"], + exclude: ["test/**/browser/*.spec.ts"], + coverage: { + include: ["src/**/*.ts"], + exclude: [ + "src/**/*-browser.mts", + "src/**/*-react-native.mts", + "vitest*.config.ts", + "samples-dev/**/*.ts", + ], + provider: "istanbul", + reporter: ["text", "json", "html"], + reportsDirectory: "coverage", + }, + }, +});