diff --git a/sdk/cognitiveservices/arm-cognitiveservices/CHANGELOG.md b/sdk/cognitiveservices/arm-cognitiveservices/CHANGELOG.md index 107bb00cb4c0..553ce805f4ed 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/CHANGELOG.md +++ b/sdk/cognitiveservices/arm-cognitiveservices/CHANGELOG.md @@ -1,5 +1,23 @@ # Release History +## 7.3.0 (2022-09-22) + +**Features** + + - Added Interface Account + - Added Interface AccountModel + - Added Interface AzureEntityResource + - Added Interface CommitmentPlan + - Added Interface Deployment + - Added Interface PrivateEndpointConnection + - Added Interface PrivateLinkResource + - Added Interface ProxyResource + - Interface DeploymentModel has a new optional parameter callRateLimit + - Interface DeploymentProperties has a new optional parameter callRateLimit + - Interface DeploymentProperties has a new optional parameter capabilities + - Interface DeploymentProperties has a new optional parameter raiPolicyName + + ## 7.2.0 (2022-06-10) **Features** diff --git a/sdk/cognitiveservices/arm-cognitiveservices/README.md b/sdk/cognitiveservices/arm-cognitiveservices/README.md index 95420302b562..15f2d746332b 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/README.md +++ b/sdk/cognitiveservices/arm-cognitiveservices/README.md @@ -13,7 +13,7 @@ Cognitive Services Management Client ### Currently supported environments -- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule) +- [LTS versions of Node.js](https://nodejs.org/about/releases/) - Latest versions of Safari, Chrome, Edge and Firefox. See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details. diff --git a/sdk/cognitiveservices/arm-cognitiveservices/_meta.json b/sdk/cognitiveservices/arm-cognitiveservices/_meta.json index 6859ada287ba..2976b1c0a926 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/_meta.json +++ b/sdk/cognitiveservices/arm-cognitiveservices/_meta.json @@ -1,8 +1,8 @@ { - "commit": "60cd4dbca5214118b763d1edc835a44c8386283a", + "commit": "dc50024a77afee69b1ce3db1a79830fdaaad74b8", "readme": "specification/cognitiveservices/resource-manager/readme.md", - "autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\cognitiveservices\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-beta.20 --generate-sample=true", + "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/cognitiveservices/resource-manager/readme.md --use=@autorest/typescript@6.0.0-rc.1", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.3.0", - "use": "@autorest/typescript@6.0.0-beta.20" + "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", + "use": "@autorest/typescript@6.0.0-rc.1" } \ No newline at end of file diff --git a/sdk/cognitiveservices/arm-cognitiveservices/package.json b/sdk/cognitiveservices/arm-cognitiveservices/package.json index f5cb49e2a2ad..32ff486a11d8 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/package.json +++ b/sdk/cognitiveservices/arm-cognitiveservices/package.json @@ -3,7 +3,7 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for CognitiveServicesManagementClient.", - "version": "7.2.0", + "version": "7.3.0", "engines": { "node": ">=12.0.0" }, @@ -98,8 +98,7 @@ "unit-test:browser": "echo skipped", "integration-test": "npm run integration-test:node && npm run integration-test:browser", "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "integration-test:browser": "echo skipped", - "docs": "echo skipped" + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -110,13 +109,5 @@ } ] }, - "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-cognitiveservices?view=azure-node-preview" - } + "autoPublish": true } \ No newline at end of file diff --git a/sdk/cognitiveservices/arm-cognitiveservices/review/arm-cognitiveservices.api.md b/sdk/cognitiveservices/arm-cognitiveservices/review/arm-cognitiveservices.api.md index 3132e17ede8c..c4f413e7d839 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/review/arm-cognitiveservices.api.md +++ b/sdk/cognitiveservices/arm-cognitiveservices/review/arm-cognitiveservices.api.md @@ -11,17 +11,17 @@ import { PollerLike } from '@azure/core-lro'; import { PollOperationState } from '@azure/core-lro'; // @public -export type Account = AzureEntityResource & { +export interface Account extends AzureEntityResource { + identity?: Identity; kind?: string; + location?: string; + properties?: AccountProperties; sku?: Sku; - identity?: Identity; readonly systemData?: SystemData; tags?: { [propertyName: string]: string; }; - location?: string; - properties?: AccountProperties; -}; +} // @public export interface AccountListResult { @@ -30,15 +30,15 @@ export interface AccountListResult { } // @public -export type AccountModel = DeploymentModel & { +export interface AccountModel extends DeploymentModel { baseModel?: DeploymentModel; - maxCapacity?: number; capabilities?: { [propertyName: string]: string; }; deprecation?: ModelDeprecationInfo; + maxCapacity?: number; readonly systemData?: SystemData; -}; +} // @public export interface AccountModelListResult { @@ -237,9 +237,9 @@ export interface ApiProperties { } // @public -export type AzureEntityResource = Resource & { +export interface AzureEntityResource extends Resource { readonly etag?: string; -}; +} // @public export interface CallRateLimit { @@ -332,11 +332,11 @@ export interface CommitmentPeriod { } // @public -export type CommitmentPlan = ProxyResource & { - readonly systemData?: SystemData; +export interface CommitmentPlan extends ProxyResource { readonly etag?: string; properties?: CommitmentPlanProperties; -}; + readonly systemData?: SystemData; +} // @public export interface CommitmentPlanListResult { @@ -479,11 +479,11 @@ export interface DeletedAccountsPurgeOptionalParams extends coreClient.Operation } // @public -export type Deployment = ProxyResource & { - readonly systemData?: SystemData; +export interface Deployment extends ProxyResource { readonly etag?: string; properties?: DeploymentProperties; -}; + readonly systemData?: SystemData; +} // @public export interface DeploymentListResult { @@ -493,6 +493,7 @@ export interface DeploymentListResult { // @public export interface DeploymentModel { + readonly callRateLimit?: CallRateLimit; format?: string; name?: string; version?: string; @@ -500,8 +501,13 @@ export interface DeploymentModel { // @public export interface DeploymentProperties { + readonly callRateLimit?: CallRateLimit; + readonly capabilities?: { + [propertyName: string]: string; + }; model?: DeploymentModel; readonly provisioningState?: DeploymentProvisioningState; + raiPolicyName?: string; scaleSettings?: DeploymentScaleSettings; } @@ -634,179 +640,122 @@ export interface KeyVaultProperties { // @public export enum KnownActionType { - // (undocumented) Internal = "Internal" } // @public export enum KnownCreatedByType { - // (undocumented) Application = "Application", - // (undocumented) Key = "Key", - // (undocumented) ManagedIdentity = "ManagedIdentity", - // (undocumented) User = "User" } // @public export enum KnownDeploymentProvisioningState { - // (undocumented) Accepted = "Accepted", - // (undocumented) Creating = "Creating", - // (undocumented) Deleting = "Deleting", - // (undocumented) Failed = "Failed", - // (undocumented) Moving = "Moving", - // (undocumented) Succeeded = "Succeeded" } // @public export enum KnownDeploymentScaleType { - // (undocumented) Manual = "Manual", - // (undocumented) Standard = "Standard" } // @public export enum KnownHostingModel { - // (undocumented) ConnectedContainer = "ConnectedContainer", - // (undocumented) DisconnectedContainer = "DisconnectedContainer", - // (undocumented) Web = "Web" } // @public export enum KnownKeySource { - // (undocumented) MicrosoftCognitiveServices = "Microsoft.CognitiveServices", - // (undocumented) MicrosoftKeyVault = "Microsoft.KeyVault" } // @public export enum KnownNetworkRuleAction { - // (undocumented) Allow = "Allow", - // (undocumented) Deny = "Deny" } // @public export enum KnownOrigin { - // (undocumented) System = "system", - // (undocumented) User = "user", - // (undocumented) UserSystem = "user,system" } // @public export enum KnownPrivateEndpointConnectionProvisioningState { - // (undocumented) Creating = "Creating", - // (undocumented) Deleting = "Deleting", - // (undocumented) Failed = "Failed", - // (undocumented) Succeeded = "Succeeded" } // @public export enum KnownPrivateEndpointServiceConnectionStatus { - // (undocumented) Approved = "Approved", - // (undocumented) Pending = "Pending", - // (undocumented) Rejected = "Rejected" } // @public export enum KnownProvisioningState { - // (undocumented) Accepted = "Accepted", - // (undocumented) Creating = "Creating", - // (undocumented) Deleting = "Deleting", - // (undocumented) Failed = "Failed", - // (undocumented) Moving = "Moving", - // (undocumented) ResolvingDNS = "ResolvingDNS", - // (undocumented) Succeeded = "Succeeded" } // @public export enum KnownPublicNetworkAccess { - // (undocumented) Disabled = "Disabled", - // (undocumented) Enabled = "Enabled" } // @public export enum KnownQuotaUsageStatus { - // (undocumented) Blocked = "Blocked", - // (undocumented) Included = "Included", - // (undocumented) InOverage = "InOverage", - // (undocumented) Unknown = "Unknown" } // @public export enum KnownResourceSkuRestrictionsReasonCode { - // (undocumented) NotAvailableForSubscription = "NotAvailableForSubscription", - // (undocumented) QuotaId = "QuotaId" } // @public export enum KnownSkuTier { - // (undocumented) Basic = "Basic", - // (undocumented) Enterprise = "Enterprise", - // (undocumented) Free = "Free", - // (undocumented) Premium = "Premium", - // (undocumented) Standard = "Standard" } // @public export enum KnownUnitType { - // (undocumented) Bytes = "Bytes", - // (undocumented) BytesPerSecond = "BytesPerSecond", - // (undocumented) Count = "Count", - // (undocumented) CountPerSecond = "CountPerSecond", - // (undocumented) Milliseconds = "Milliseconds", - // (undocumented) Percent = "Percent", - // (undocumented) Seconds = "Seconds" } @@ -883,11 +832,11 @@ export interface PrivateEndpoint { } // @public -export type PrivateEndpointConnection = AzureEntityResource & { +export interface PrivateEndpointConnection extends AzureEntityResource { + location?: string; properties?: PrivateEndpointConnectionProperties; readonly systemData?: SystemData; - location?: string; -}; +} // @public export interface PrivateEndpointConnectionListResult { @@ -948,9 +897,9 @@ export type PrivateEndpointConnectionsListResponse = PrivateEndpointConnectionLi export type PrivateEndpointServiceConnectionStatus = string; // @public -export type PrivateLinkResource = Resource & { +export interface PrivateLinkResource extends Resource { properties?: PrivateLinkResourceProperties; -}; +} // @public export interface PrivateLinkResourceListResult { @@ -988,7 +937,8 @@ export interface PrivateLinkServiceConnectionState { export type ProvisioningState = string; // @public -export type ProxyResource = Resource; +export interface ProxyResource extends Resource { +} // @public export type PublicNetworkAccess = string; diff --git a/sdk/cognitiveservices/arm-cognitiveservices/src/cognitiveServicesManagementClient.ts b/sdk/cognitiveservices/arm-cognitiveservices/src/cognitiveServicesManagementClient.ts index c568ecc7c3ac..0036607f9157 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/src/cognitiveServicesManagementClient.ts +++ b/sdk/cognitiveservices/arm-cognitiveservices/src/cognitiveServicesManagementClient.ts @@ -78,7 +78,7 @@ export class CognitiveServicesManagementClient extends coreClient.ServiceClient credential: credentials }; - const packageDetails = `azsdk-js-arm-cognitiveservices/7.2.0`; + const packageDetails = `azsdk-js-arm-cognitiveservices/7.3.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -125,7 +125,7 @@ export class CognitiveServicesManagementClient extends coreClient.ServiceClient // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2022-03-01"; + this.apiVersion = options.apiVersion || "2022-10-01"; this.accounts = new AccountsImpl(this); this.deletedAccounts = new DeletedAccountsImpl(this); this.resourceSkus = new ResourceSkusImpl(this); @@ -153,7 +153,7 @@ export class CognitiveServicesManagementClient extends coreClient.ServiceClient if (param.length > 1) { const newParams = param[1].split("&").map((item) => { if (item.indexOf("api-version") > -1) { - return item.replace(/(?<==).*$/, apiVersion); + return "api-version=" + apiVersion; } else { return item; } diff --git a/sdk/cognitiveservices/arm-cognitiveservices/src/models/index.ts b/sdk/cognitiveservices/arm-cognitiveservices/src/models/index.ts index 3210acec2325..af99d2b1c8bc 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/src/models/index.ts +++ b/sdk/cognitiveservices/arm-cognitiveservices/src/models/index.ts @@ -513,6 +513,11 @@ export interface DeploymentModel { name?: string; /** Deployment model version. */ version?: string; + /** + * The call rate limit Cognitive Services account. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly callRateLimit?: CallRateLimit; } /** Cognitive Services account ModelDeprecationInfo. */ @@ -745,6 +750,18 @@ export interface DeploymentProperties { model?: DeploymentModel; /** Properties of Cognitive Services account deployment model. */ scaleSettings?: DeploymentScaleSettings; + /** + * The capabilities. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly capabilities?: { [propertyName: string]: string }; + /** The name of RAI policy. */ + raiPolicyName?: string; + /** + * The call rate limit Cognitive Services account. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly callRateLimit?: CallRateLimit; } /** Properties of Cognitive Services account deployment model. */ @@ -814,25 +831,25 @@ export interface CommitmentPeriod { } /** The resource model definition for an Azure Resource Manager resource with an etag. */ -export type AzureEntityResource = Resource & { +export interface AzureEntityResource extends Resource { /** * Resource Etag. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly etag?: string; -}; +} /** A private link resource */ -export type PrivateLinkResource = Resource & { +export interface PrivateLinkResource extends Resource { /** Resource properties. */ properties?: PrivateLinkResourceProperties; -}; +} /** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ -export type ProxyResource = Resource; +export interface ProxyResource extends Resource {} /** Cognitive Services account Model. */ -export type AccountModel = DeploymentModel & { +export interface AccountModel extends DeploymentModel { /** Base Model Identifier. */ baseModel?: DeploymentModel; /** The max capacity. */ @@ -846,10 +863,10 @@ export type AccountModel = DeploymentModel & { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly systemData?: SystemData; -}; +} /** The Private Endpoint Connection resource. */ -export type PrivateEndpointConnection = AzureEntityResource & { +export interface PrivateEndpointConnection extends AzureEntityResource { /** Resource properties. */ properties?: PrivateEndpointConnectionProperties; /** @@ -859,10 +876,10 @@ export type PrivateEndpointConnection = AzureEntityResource & { readonly systemData?: SystemData; /** The location of the private endpoint connection */ location?: string; -}; +} /** Cognitive Services account is an Azure resource representing the provisioned account, it's type, location and SKU. */ -export type Account = AzureEntityResource & { +export interface Account extends AzureEntityResource { /** The Kind of the resource. */ kind?: string; /** The resource model definition representing SKU */ @@ -880,10 +897,10 @@ export type Account = AzureEntityResource & { location?: string; /** Properties of Cognitive Services account. */ properties?: AccountProperties; -}; +} /** Cognitive Services account deployment. */ -export type Deployment = ProxyResource & { +export interface Deployment extends ProxyResource { /** * Metadata pertaining to creation and last modification of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -896,10 +913,10 @@ export type Deployment = ProxyResource & { readonly etag?: string; /** Properties of Cognitive Services account deployment. */ properties?: DeploymentProperties; -}; +} /** Cognitive Services account commitment plan. */ -export type CommitmentPlan = ProxyResource & { +export interface CommitmentPlan extends ProxyResource { /** * Metadata pertaining to creation and last modification of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -912,14 +929,19 @@ export type CommitmentPlan = ProxyResource & { readonly etag?: string; /** Properties of Cognitive Services account commitment plan. */ properties?: CommitmentPlanProperties; -}; +} /** Known values of {@link SkuTier} that the service accepts. */ export enum KnownSkuTier { + /** Free */ Free = "Free", + /** Basic */ Basic = "Basic", + /** Standard */ Standard = "Standard", + /** Premium */ Premium = "Premium", + /** Enterprise */ Enterprise = "Enterprise" } @@ -938,9 +960,13 @@ export type SkuTier = string; /** Known values of {@link CreatedByType} that the service accepts. */ export enum KnownCreatedByType { + /** User */ User = "User", + /** Application */ Application = "Application", + /** ManagedIdentity */ ManagedIdentity = "ManagedIdentity", + /** Key */ Key = "Key" } @@ -958,12 +984,19 @@ export type CreatedByType = string; /** Known values of {@link ProvisioningState} that the service accepts. */ export enum KnownProvisioningState { + /** Accepted */ Accepted = "Accepted", + /** Creating */ Creating = "Creating", + /** Deleting */ Deleting = "Deleting", + /** Moving */ Moving = "Moving", + /** Failed */ Failed = "Failed", + /** Succeeded */ Succeeded = "Succeeded", + /** ResolvingDNS */ ResolvingDNS = "ResolvingDNS" } @@ -984,7 +1017,9 @@ export type ProvisioningState = string; /** Known values of {@link NetworkRuleAction} that the service accepts. */ export enum KnownNetworkRuleAction { + /** Allow */ Allow = "Allow", + /** Deny */ Deny = "Deny" } @@ -1000,7 +1035,9 @@ export type NetworkRuleAction = string; /** Known values of {@link KeySource} that the service accepts. */ export enum KnownKeySource { + /** MicrosoftCognitiveServices */ MicrosoftCognitiveServices = "Microsoft.CognitiveServices", + /** MicrosoftKeyVault */ MicrosoftKeyVault = "Microsoft.KeyVault" } @@ -1016,8 +1053,11 @@ export type KeySource = string; /** Known values of {@link PrivateEndpointServiceConnectionStatus} that the service accepts. */ export enum KnownPrivateEndpointServiceConnectionStatus { + /** Pending */ Pending = "Pending", + /** Approved */ Approved = "Approved", + /** Rejected */ Rejected = "Rejected" } @@ -1034,9 +1074,13 @@ export type PrivateEndpointServiceConnectionStatus = string; /** Known values of {@link PrivateEndpointConnectionProvisioningState} that the service accepts. */ export enum KnownPrivateEndpointConnectionProvisioningState { + /** Succeeded */ Succeeded = "Succeeded", + /** Creating */ Creating = "Creating", + /** Deleting */ Deleting = "Deleting", + /** Failed */ Failed = "Failed" } @@ -1054,7 +1098,9 @@ export type PrivateEndpointConnectionProvisioningState = string; /** Known values of {@link PublicNetworkAccess} that the service accepts. */ export enum KnownPublicNetworkAccess { + /** Enabled */ Enabled = "Enabled", + /** Disabled */ Disabled = "Disabled" } @@ -1070,7 +1116,9 @@ export type PublicNetworkAccess = string; /** Known values of {@link ResourceSkuRestrictionsReasonCode} that the service accepts. */ export enum KnownResourceSkuRestrictionsReasonCode { + /** QuotaId */ QuotaId = "QuotaId", + /** NotAvailableForSubscription */ NotAvailableForSubscription = "NotAvailableForSubscription" } @@ -1086,12 +1134,19 @@ export type ResourceSkuRestrictionsReasonCode = string; /** Known values of {@link UnitType} that the service accepts. */ export enum KnownUnitType { + /** Count */ Count = "Count", + /** Bytes */ Bytes = "Bytes", + /** Seconds */ Seconds = "Seconds", + /** Percent */ Percent = "Percent", + /** CountPerSecond */ CountPerSecond = "CountPerSecond", + /** BytesPerSecond */ BytesPerSecond = "BytesPerSecond", + /** Milliseconds */ Milliseconds = "Milliseconds" } @@ -1112,9 +1167,13 @@ export type UnitType = string; /** Known values of {@link QuotaUsageStatus} that the service accepts. */ export enum KnownQuotaUsageStatus { + /** Included */ Included = "Included", + /** Blocked */ Blocked = "Blocked", + /** InOverage */ InOverage = "InOverage", + /** Unknown */ Unknown = "Unknown" } @@ -1132,8 +1191,11 @@ export type QuotaUsageStatus = string; /** Known values of {@link Origin} that the service accepts. */ export enum KnownOrigin { + /** User */ User = "user", + /** System */ System = "system", + /** UserSystem */ UserSystem = "user,system" } @@ -1150,6 +1212,7 @@ export type Origin = string; /** Known values of {@link ActionType} that the service accepts. */ export enum KnownActionType { + /** Internal */ Internal = "Internal" } @@ -1164,8 +1227,11 @@ export type ActionType = string; /** Known values of {@link HostingModel} that the service accepts. */ export enum KnownHostingModel { + /** Web */ Web = "Web", + /** ConnectedContainer */ ConnectedContainer = "ConnectedContainer", + /** DisconnectedContainer */ DisconnectedContainer = "DisconnectedContainer" } @@ -1182,11 +1248,17 @@ export type HostingModel = string; /** Known values of {@link DeploymentProvisioningState} that the service accepts. */ export enum KnownDeploymentProvisioningState { + /** Accepted */ Accepted = "Accepted", + /** Creating */ Creating = "Creating", + /** Deleting */ Deleting = "Deleting", + /** Moving */ Moving = "Moving", + /** Failed */ Failed = "Failed", + /** Succeeded */ Succeeded = "Succeeded" } @@ -1206,7 +1278,9 @@ export type DeploymentProvisioningState = string; /** Known values of {@link DeploymentScaleType} that the service accepts. */ export enum KnownDeploymentScaleType { + /** Standard */ Standard = "Standard", + /** Manual */ Manual = "Manual" } diff --git a/sdk/cognitiveservices/arm-cognitiveservices/src/models/mappers.ts b/sdk/cognitiveservices/arm-cognitiveservices/src/models/mappers.ts index 4e37072c0bb7..f092f1177d00 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/src/models/mappers.ts +++ b/sdk/cognitiveservices/arm-cognitiveservices/src/models/mappers.ts @@ -1416,6 +1416,13 @@ export const DeploymentModel: coreClient.CompositeMapper = { type: { name: "String" } + }, + callRateLimit: { + serializedName: "callRateLimit", + type: { + name: "Composite", + className: "CallRateLimit" + } } } } @@ -1991,6 +1998,27 @@ export const DeploymentProperties: coreClient.CompositeMapper = { name: "Composite", className: "DeploymentScaleSettings" } + }, + capabilities: { + serializedName: "capabilities", + readOnly: true, + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + }, + raiPolicyName: { + serializedName: "raiPolicyName", + type: { + name: "String" + } + }, + callRateLimit: { + serializedName: "callRateLimit", + type: { + name: "Composite", + className: "CallRateLimit" + } } } } diff --git a/sdk/cognitiveservices/arm-cognitiveservices/src/models/parameters.ts b/sdk/cognitiveservices/arm-cognitiveservices/src/models/parameters.ts index 42ef559bb3c2..6bfba6abe901 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/src/models/parameters.ts +++ b/sdk/cognitiveservices/arm-cognitiveservices/src/models/parameters.ts @@ -96,7 +96,7 @@ export const accountName: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2022-03-01", + defaultValue: "2022-10-01", isConstant: true, serializedName: "api-version", type: { diff --git a/sdk/cognitiveservices/arm-cognitiveservices/test/sampleTest.ts b/sdk/cognitiveservices/arm-cognitiveservices/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/cognitiveservices/arm-cognitiveservices/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id" +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function(this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function() { + await recorder.stop(); + }); + + it("sample test", async function() { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/cognitiveservices/arm-cognitiveservices/tsconfig.json b/sdk/cognitiveservices/arm-cognitiveservices/tsconfig.json index 67e8e46df416..3e6ae96443f3 100644 --- a/sdk/cognitiveservices/arm-cognitiveservices/tsconfig.json +++ b/sdk/cognitiveservices/arm-cognitiveservices/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-cognitiveservices": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"