Skip to content

Commit

Permalink
CodeGen from PR 19960 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge d35fb5f90a7fdae0ea6545cef6f41a5f80744195 into 402c7fb924c5c0a30650d1c11338d4d516585933
  • Loading branch information
SDKAuto committed Jul 26, 2022
1 parent 9899204 commit 25b50fd
Show file tree
Hide file tree
Showing 10 changed files with 336 additions and 64 deletions.
26 changes: 16 additions & 10 deletions sdk/healthcareapis/arm-healthcareapis/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
# Release History

## 2.2.0 (2022-07-26)

**Features**

## 2.1.2 (Unreleased)

### Features Added

### Breaking Changes

### Bugs Fixed

### Other Changes

- Added Interface CorsConfiguration
- Added Interface FhirServiceImportConfiguration
- Added Interface ServiceImportConfigurationInfo
- Interface MetricSpecification has a new optional parameter enableRegionalMdmAccount
- Interface MetricSpecification has a new optional parameter isInternal
- Interface MetricSpecification has a new optional parameter metricFilterPattern
- Interface MetricSpecification has a new optional parameter resourceIdDimensionNameOverride
- Interface MetricSpecification has a new optional parameter sourceMdmAccount
- Interface ServicesProperties has a new optional parameter importConfiguration
- Type Alias DicomService has a new parameter corsConfiguration
- Type Alias FhirService has a new parameter importConfiguration

## 2.1.1 (2022-04-26)

**Features**
Expand Down
12 changes: 6 additions & 6 deletions sdk/healthcareapis/arm-healthcareapis/_meta.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"commit": "1f1d5b0b9ce6cc94605b2fd619dce374fb6e033a",
"readme": "specification\\healthcareapis\\resource-manager\\readme.md",
"autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\work\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\healthcareapis\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-alpha.19.20220408.1 --generate-sample=true",
"commit": "f893d78aca0270108c7683d86a9893bd796cfc19",
"readme": "specification/healthcareapis/resource-manager/readme.md",
"autorest_command": "",
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
"release_tool": "@azure-tools/js-sdk-release-tools@2.2.6",
"use": "@autorest/typescript@6.0.0-alpha.19.20220408.1"
}
"release_tool": "@azure-tools/js-sdk-release-tools@2.4.1",
"use": "@autorest/typescript@6.0.0-alpha.19.20220425.1"
}
22 changes: 8 additions & 14 deletions sdk/healthcareapis/arm-healthcareapis/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"sdk-type": "mgmt",
"author": "Microsoft Corporation",
"description": "A generated SDK for HealthcareApisManagementClient.",
"version": "2.1.2",
"version": "2.2.0",
"engines": {
"node": ">=12.0.0"
},
Expand Down Expand Up @@ -40,9 +40,11 @@
"uglify-js": "^3.4.9",
"rimraf": "^3.0.0",
"@azure/identity": "^2.0.1",
"@azure-tools/test-recorder": "^1.0.0",
"@azure-tools/test-recorder": "^2.0.0",
"@azure-tools/test-credential": "^1.0.0",
"mocha": "^7.1.1",
"cross-env": "^7.0.2"
"cross-env": "^7.0.2",
"@azure/dev-tool": "^1.0.0"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/healthcareapis/arm-healthcareapis",
"repository": {
Expand Down Expand Up @@ -93,7 +95,7 @@
"unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node",
"unit-test:browser": "echo skipped",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"integration-test:node": "mocha -r esm --require ts-node/register --timeout 1200000 --full-trace test/*.ts --reporter ../../../common/tools/mocha-multi-reporter.js",
"integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'",
"integration-test:browser": "echo skipped",
"docs": "echo skipped"
},
Expand All @@ -106,13 +108,5 @@
}
]
},
"autoPublish": true,
"//sampleConfiguration": {
"productName": "",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-healthcareapis?view=azure-node-preview"
}
}
"autoPublish": true
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ export interface CheckNameAvailabilityParameters {
type: string;
}

// @public
export interface CorsConfiguration {
allowCredentials?: boolean;
headers?: string[];
maxAge?: number;
methods?: string[];
origins?: string[];
}

// @public
export type CreatedByType = string;

Expand All @@ -27,6 +36,7 @@ export type DicomService = TaggedResource & ServiceManagedIdentity & {
readonly systemData?: SystemData;
readonly provisioningState?: ProvisioningState;
authenticationConfiguration?: DicomServiceAuthenticationConfiguration;
corsConfiguration?: CorsConfiguration;
readonly serviceUrl?: string;
readonly privateEndpointConnections?: PrivateEndpointConnection[];
publicNetworkAccess?: PublicNetworkAccess;
Expand Down Expand Up @@ -157,6 +167,7 @@ export type FhirService = TaggedResource & ServiceManagedIdentity & {
publicNetworkAccess?: PublicNetworkAccess;
readonly eventState?: ServiceEventState;
resourceVersionPolicyConfiguration?: ResourceVersionPolicyConfiguration;
importConfiguration?: FhirServiceImportConfiguration;
};

// @public
Expand Down Expand Up @@ -197,6 +208,13 @@ export interface FhirServiceExportConfiguration {
storageAccountName?: string;
}

// @public
export interface FhirServiceImportConfiguration {
enabled?: boolean;
initialImportMode?: boolean;
integrationDataStore?: string;
}

// @public
export type FhirServiceKind = string;

Expand Down Expand Up @@ -637,8 +655,13 @@ export interface MetricSpecification {
dimensions?: MetricDimension[];
displayDescription?: string;
displayName?: string;
enableRegionalMdmAccount?: boolean;
fillGapWithZero?: boolean;
isInternal?: boolean;
metricFilterPattern?: string;
name?: string;
resourceIdDimensionNameOverride?: string;
sourceMdmAccount?: string;
sourceMdmNamespace?: string;
supportedAggregationTypes?: string[];
supportedTimeGrainTypes?: string[];
Expand Down Expand Up @@ -905,6 +928,13 @@ export interface ServiceExportConfigurationInfo {
storageAccountName?: string;
}

// @public
export interface ServiceImportConfigurationInfo {
enabled?: boolean;
initialImportMode?: boolean;
integrationDataStore?: string;
}

// @public
export interface ServiceManagedIdentity {
identity?: ServiceManagedIdentityIdentity;
Expand Down Expand Up @@ -1045,6 +1075,7 @@ export interface ServicesProperties {
corsConfiguration?: ServiceCorsConfigurationInfo;
cosmosDbConfiguration?: ServiceCosmosDbConfigurationInfo;
exportConfiguration?: ServiceExportConfigurationInfo;
importConfiguration?: ServiceImportConfigurationInfo;
privateEndpointConnections?: PrivateEndpointConnection[];
readonly provisioningState?: ProvisioningState;
publicNetworkAccess?: PublicNetworkAccess;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@

import * as coreClient from "@azure/core-client";
import * as coreRestPipeline from "@azure/core-rest-pipeline";
import {
PipelineRequest,
PipelineResponse,
SendRequest
} from "@azure/core-rest-pipeline";
import * as coreAuth from "@azure/core-auth";
import {
ServicesImpl,
Expand Down Expand Up @@ -73,7 +78,7 @@ export class HealthcareApisManagementClient extends coreClient.ServiceClient {
credential: credentials
};

const packageDetails = `azsdk-js-arm-healthcareapis/2.1.2`;
const packageDetails = `azsdk-js-arm-healthcareapis/2.2.0`;
const userAgentPrefix =
options.userAgentOptions && options.userAgentOptions.userAgentPrefix
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
Expand Down Expand Up @@ -120,7 +125,7 @@ export class HealthcareApisManagementClient extends coreClient.ServiceClient {

// Assigning values to Constant parameters
this.$host = options.$host || "https://management.azure.com";
this.apiVersion = options.apiVersion || "2021-11-01";
this.apiVersion = options.apiVersion || "2022-06-01";
this.services = new ServicesImpl(this);
this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this);
this.privateLinkResources = new PrivateLinkResourcesImpl(this);
Expand All @@ -140,6 +145,35 @@ export class HealthcareApisManagementClient extends coreClient.ServiceClient {
);
this.operations = new OperationsImpl(this);
this.operationResults = new OperationResultsImpl(this);
this.addCustomApiVersionPolicy(options.apiVersion);
}

/** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */
private addCustomApiVersionPolicy(apiVersion?: string) {
if (!apiVersion) {
return;
}
const apiVersionPolicy = {
name: "CustomApiVersionPolicy",
async sendRequest(
request: PipelineRequest,
next: SendRequest
): Promise<PipelineResponse> {
const param = request.url.split("?");
if (param.length > 1) {
const newParams = param[1].split("&").map((item) => {
if (item.indexOf("api-version") > -1) {
return item.replace(/(?<==).*$/, apiVersion);
} else {
return item;
}
});
request.url = param[0] + "?" + newParams.join("&");
}
return next(request);
}
};
this.pipeline.addPolicy(apiVersionPolicy);
}

services: Services;
Expand Down
52 changes: 51 additions & 1 deletion sdk/healthcareapis/arm-healthcareapis/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ export interface ServicesProperties {
publicNetworkAccess?: PublicNetworkAccess;
/** The azure container registry settings used for convert data operation of the service instance. */
acrConfiguration?: ServiceAcrConfigurationInfo;
/** The settings for the import operation of the service instance. */
importConfiguration?: ServiceImportConfigurationInfo;
}

/** An access policy entry. */
Expand Down Expand Up @@ -133,6 +135,16 @@ export interface ServiceOciArtifactEntry {
digest?: string;
}

/** Import operation configuration information */
export interface ServiceImportConfigurationInfo {
/** The name of the default integration storage account. */
integrationDataStore?: string;
/** If the FHIR service is in InitialImportMode. */
initialImportMode?: boolean;
/** If the import operation is enabled. */
enabled?: boolean;
}

/** Metadata pertaining to creation and last modification of the resource. */
export interface SystemData {
/** The identity that created the resource. */
Expand Down Expand Up @@ -350,6 +362,20 @@ export interface DicomServiceAuthenticationConfiguration {
readonly audiences?: string[];
}

/** The settings for the CORS configuration of the service instance. */
export interface CorsConfiguration {
/** The origins to be allowed via CORS. */
origins?: string[];
/** The headers to be allowed via CORS. */
headers?: string[];
/** The methods to be allowed via CORS. */
methods?: string[];
/** The max age to be allowed via CORS. */
maxAge?: number;
/** If credentials are allowed via CORS. */
allowCredentials?: boolean;
}

/** Managed service identity (system assigned and/or user assigned identities) */
export interface ServiceManagedIdentity {
/** Setting indicating whether the service has a managed identity associated with it. */
Expand Down Expand Up @@ -489,6 +515,16 @@ export interface ResourceVersionPolicyConfiguration {
resourceTypeOverrides?: { [propertyName: string]: FhirResourceVersionPolicy };
}

/** Import operation configuration information */
export interface FhirServiceImportConfiguration {
/** The name of the default integration storage account. */
integrationDataStore?: string;
/** If the FHIR service is in InitialImportMode. */
initialImportMode?: boolean;
/** If the import operation is enabled. */
enabled?: boolean;
}

/** Available operations of the service */
export interface ListOperations {
/**
Expand Down Expand Up @@ -599,10 +635,20 @@ export interface MetricSpecification {
supportedTimeGrainTypes?: string[];
/** Optional. If set to true, then zero will be returned for time duration where no metric is emitted/published. */
fillGapWithZero?: boolean;
/** Pattern for the filter of the metric. */
metricFilterPattern?: string;
/** Dimensions of the metric */
dimensions?: MetricDimension[];
/** Name of the MDM namespace. Optional. */
/** Whether the metric is internal. */
isInternal?: boolean;
/** The source MDM account. */
sourceMdmAccount?: string;
/** The source MDM namespace. */
sourceMdmNamespace?: string;
/** Whether regional MDM account enabled. */
enableRegionalMdmAccount?: boolean;
/** The resource Id dimension name override. */
resourceIdDimensionNameOverride?: string;
}

/** Specifications of the Dimension of metrics */
Expand Down Expand Up @@ -731,6 +777,8 @@ export type DicomService = TaggedResource &
readonly provisioningState?: ProvisioningState;
/** Dicom Service authentication configuration. */
authenticationConfiguration?: DicomServiceAuthenticationConfiguration;
/** Dicom Service Cors configuration. */
corsConfiguration?: CorsConfiguration;
/**
* The url of the Dicom Services.
* NOTE: This property will not be serialized. It can only be populated by the server.
Expand Down Expand Up @@ -803,6 +851,8 @@ export type FhirService = TaggedResource &
readonly eventState?: ServiceEventState;
/** Determines tracking of history for resources. */
resourceVersionPolicyConfiguration?: ResourceVersionPolicyConfiguration;
/** Fhir Service import configuration. */
importConfiguration?: FhirServiceImportConfiguration;
};

/** IoT Connector destination properties for an Azure FHIR service. */
Expand Down
Loading

0 comments on commit 25b50fd

Please sign in to comment.