Skip to content

Commit b4e21db

Browse files
authored
apimanagement-track1 (Azure#18716)
1 parent 3e0878d commit b4e21db

File tree

74 files changed

+4371
-368
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+4371
-368
lines changed

sdk/apimanagement/arm-apimanagement/README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
## Azure ApiManagementClient SDK for JavaScript
22

3-
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for ApiManagementClient.
3+
This package contains an isomorphic SDK (runs both in node.js and in browsers) for ApiManagementClient.
44

55
### Currently supported environments
66

77
- [LTS versions of Node.js](https://nodejs.org/about/releases/)
8-
- Latest versions of Safari, Chrome, Edge, and Firefox.
8+
- Latest versions of Safari, Chrome, Edge and Firefox.
99

1010
### Prerequisites
1111

@@ -21,7 +21,6 @@ Install both packages using the below command:
2121
```bash
2222
npm install --save @azure/arm-apimanagement @azure/identity
2323
```
24-
2524
> **Note**: You may have used either `@azure/ms-rest-nodeauth` or `@azure/ms-rest-browserauth` in the past. These packages are in maintenance mode receiving critical bug fixes, but no new features.
2625
If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/), or are writing a client side browser application, we strongly encourage you to upgrade to `@azure/identity` which uses the latest versions of Azure Active Directory and MSAL APIs and provides more authentication options.
2726

@@ -37,7 +36,6 @@ If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/
3736

3837
In the below samples, we pass the credential and the Azure subscription id to instantiate the client.
3938
Once the client is created, explore the operations on it either in your favorite editor or in our [API reference documentation](https://docs.microsoft.com/javascript/api) to get started.
40-
4139
#### nodejs - Authentication, client creation, and listByService api as an example written in JavaScript.
4240

4341
##### Sample code
@@ -92,7 +90,7 @@ In browser applications, we recommend using the `InteractiveBrowserCredential` t
9290
const credential = new InteractiveBrowserCredential(
9391
{
9492
clientId: "<client id for your Azure AD app>",
95-
tenantId: "<optional tenant for your organization>"
93+
tenant: "<optional tenant for your organization>"
9694
});
9795
const client = new Azure.ArmApimanagement.ApiManagementClient(creds, subscriptionId);
9896
const resourceGroupName = "testresourceGroupName";

sdk/apimanagement/arm-apimanagement/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@azure/arm-apimanagement",
33
"author": "Microsoft Corporation",
44
"description": "ApiManagementClient Library with typescript type definitions for node.js and browser.",
5-
"version": "7.1.2",
5+
"version": "7.2.0",
66
"dependencies": {
77
"@azure/ms-rest-azure-js": "^2.1.0",
88
"@azure/ms-rest-js": "^2.2.0",
@@ -27,7 +27,7 @@
2727
"rollup-plugin-sourcemaps": "^0.4.2",
2828
"uglify-js": "^3.6.0"
2929
},
30-
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/feature/v4/sdk/apimanagement/arm-apimanagement",
30+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/apimanagement/arm-apimanagement",
3131
"repository": {
3232
"type": "git",
3333
"url": "https://github.com/Azure/azure-sdk-for-js.git"

sdk/apimanagement/arm-apimanagement/src/apiManagementClient.ts

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@
99

1010
import * as msRest from "@azure/ms-rest-js";
1111
import { TokenCredential } from "@azure/core-auth";
12+
import * as msRestAzure from "@azure/ms-rest-azure-js";
1213
import * as Models from "./models";
1314
import * as Mappers from "./models/mappers";
15+
import * as Parameters from "./models/parameters";
1416
import * as operations from "./operations";
1517
import { ApiManagementClientContext } from "./apiManagementClientContext";
1618

@@ -60,13 +62,15 @@ class ApiManagementClient extends ApiManagementClientContext {
6062
notificationRecipientUser: operations.NotificationRecipientUser;
6163
notificationRecipientEmail: operations.NotificationRecipientEmail;
6264
openIdConnectProvider: operations.OpenIdConnectProvider;
65+
outboundNetworkDependenciesEndpoints: operations.OutboundNetworkDependenciesEndpoints;
6366
policy: operations.Policy;
6467
policyDescription: operations.PolicyDescription;
6568
portalRevision: operations.PortalRevision;
6669
portalSettings: operations.PortalSettings;
6770
signInSettings: operations.SignInSettings;
6871
signUpSettings: operations.SignUpSettings;
6972
delegationSettings: operations.DelegationSettings;
73+
privateEndpointConnection: operations.PrivateEndpointConnectionOperations;
7074
product: operations.Product;
7175
productApi: operations.ProductApi;
7276
productGroup: operations.ProductGroup;
@@ -147,13 +151,15 @@ class ApiManagementClient extends ApiManagementClientContext {
147151
this.notificationRecipientUser = new operations.NotificationRecipientUser(this);
148152
this.notificationRecipientEmail = new operations.NotificationRecipientEmail(this);
149153
this.openIdConnectProvider = new operations.OpenIdConnectProvider(this);
154+
this.outboundNetworkDependenciesEndpoints = new operations.OutboundNetworkDependenciesEndpoints(this);
150155
this.policy = new operations.Policy(this);
151156
this.policyDescription = new operations.PolicyDescription(this);
152157
this.portalRevision = new operations.PortalRevision(this);
153158
this.portalSettings = new operations.PortalSettings(this);
154159
this.signInSettings = new operations.SignInSettings(this);
155160
this.signUpSettings = new operations.SignUpSettings(this);
156161
this.delegationSettings = new operations.DelegationSettings(this);
162+
this.privateEndpointConnection = new operations.PrivateEndpointConnectionOperations(this);
157163
this.product = new operations.Product(this);
158164
this.productApi = new operations.ProductApi(this);
159165
this.productGroup = new operations.ProductGroup(this);
@@ -177,9 +183,77 @@ class ApiManagementClient extends ApiManagementClientContext {
177183
this.userConfirmationPassword = new operations.UserConfirmationPassword(this);
178184
this.apiExport = new operations.ApiExport(this);
179185
}
186+
187+
/**
188+
* Performs a connectivity check between the API Management service and a given destination, and
189+
* returns metrics for the connection, as well as errors encountered while trying to establish it.
190+
* @param resourceGroupName The name of the resource group.
191+
* @param serviceName The name of the API Management service.
192+
* @param connectivityCheckRequestParams Connectivity Check request parameters.
193+
* @param [options] The optional parameters
194+
* @returns Promise<Models.PerformConnectivityCheckAsyncResponse>
195+
*/
196+
performConnectivityCheckAsync(resourceGroupName: string, serviceName: string, connectivityCheckRequestParams: Models.ConnectivityCheckRequest, options?: msRest.RequestOptionsBase): Promise<Models.PerformConnectivityCheckAsyncResponse> {
197+
return this.beginPerformConnectivityCheckAsync(resourceGroupName,serviceName,connectivityCheckRequestParams,options)
198+
.then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.PerformConnectivityCheckAsyncResponse>;
199+
}
200+
201+
/**
202+
* Performs a connectivity check between the API Management service and a given destination, and
203+
* returns metrics for the connection, as well as errors encountered while trying to establish it.
204+
* @param resourceGroupName The name of the resource group.
205+
* @param serviceName The name of the API Management service.
206+
* @param connectivityCheckRequestParams Connectivity Check request parameters.
207+
* @param [options] The optional parameters
208+
* @returns Promise<msRestAzure.LROPoller>
209+
*/
210+
beginPerformConnectivityCheckAsync(resourceGroupName: string, serviceName: string, connectivityCheckRequestParams: Models.ConnectivityCheckRequest, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
211+
return this.sendLRORequest(
212+
{
213+
resourceGroupName,
214+
serviceName,
215+
connectivityCheckRequestParams,
216+
options
217+
},
218+
beginPerformConnectivityCheckAsyncOperationSpec,
219+
options);
220+
}
180221
}
181222

182223
// Operation Specifications
224+
const serializer = new msRest.Serializer(Mappers);
225+
const beginPerformConnectivityCheckAsyncOperationSpec: msRest.OperationSpec = {
226+
httpMethod: "POST",
227+
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/connectivityCheck",
228+
urlParameters: [
229+
Parameters.resourceGroupName,
230+
Parameters.serviceName,
231+
Parameters.subscriptionId
232+
],
233+
queryParameters: [
234+
Parameters.apiVersion
235+
],
236+
headerParameters: [
237+
Parameters.acceptLanguage
238+
],
239+
requestBody: {
240+
parameterPath: "connectivityCheckRequestParams",
241+
mapper: {
242+
...Mappers.ConnectivityCheckRequest,
243+
required: true
244+
}
245+
},
246+
responses: {
247+
200: {
248+
bodyMapper: Mappers.ConnectivityCheckResponse
249+
},
250+
202: {},
251+
default: {
252+
bodyMapper: Mappers.ErrorResponse
253+
}
254+
},
255+
serializer
256+
};
183257

184258
export {
185259
ApiManagementClient,

sdk/apimanagement/arm-apimanagement/src/apiManagementClientContext.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99

1010
import * as Models from "./models";
1111
import * as msRest from "@azure/ms-rest-js";
12-
import { TokenCredential } from "@azure/core-auth";
1312
import * as msRestAzure from "@azure/ms-rest-azure-js";
13+
import { TokenCredential } from "@azure/core-auth";
1414

1515
const packageName = "@azure/arm-apimanagement";
16-
const packageVersion = "7.1.2";
16+
const packageVersion = "7.2.0";
1717

1818
export class ApiManagementClientContext extends msRestAzure.AzureServiceClient {
1919
credentials: msRest.ServiceClientCredentials | TokenCredential;
@@ -50,7 +50,7 @@ export class ApiManagementClientContext extends msRestAzure.AzureServiceClient {
5050

5151
super(credentials, options);
5252

53-
this.apiVersion = '2020-12-01';
53+
this.apiVersion = '2021-08-01';
5454
this.acceptLanguage = 'en-US';
5555
this.longRunningOperationRetryTimeout = 30;
5656
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";

sdk/apimanagement/arm-apimanagement/src/models/apiDiagnosticMappers.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,13 @@
99
export {
1010
AccessInformationContract,
1111
AdditionalLocation,
12+
ApiContactInformation,
1213
ApiContract,
1314
ApiDiagnosticCreateOrUpdateHeaders,
1415
ApiDiagnosticGetEntityTagHeaders,
1516
ApiDiagnosticGetHeaders,
1617
ApiDiagnosticUpdateHeaders,
18+
ApiLicenseInformation,
1719
ApiManagementServiceIdentity,
1820
ApiManagementServiceResource,
1921
ApiManagementServiceSkuProperties,
@@ -23,10 +25,12 @@ export {
2325
ApiVersionConstraint,
2426
ApiVersionSetContract,
2527
ApiVersionSetContractDetails,
28+
ArmIdWrapper,
2629
AssociationContract,
2730
AuthenticationSettingsContract,
2831
AuthorizationServerContract,
2932
AuthorizationServerUpdateContract,
33+
AzureEntityResource,
3034
BackendAuthorizationHeaderCredentials,
3135
BackendContract,
3236
BackendCredentialsContract,
@@ -52,6 +56,7 @@ export {
5256
EmailTemplateParametersContractProperties,
5357
ErrorFieldContract,
5458
ErrorResponse,
59+
ErrorResponseBody,
5560
GatewayCertificateAuthorityContract,
5661
GatewayContract,
5762
GatewayHostnameConfigurationContract,
@@ -75,7 +80,10 @@ export {
7580
OpenIdAuthenticationSettingsContract,
7681
OpenidConnectProviderContract,
7782
OperationContract,
83+
OperationResultContract,
84+
OperationResultLogItemContract,
7885
ParameterContract,
86+
ParameterExampleContract,
7987
PipelineDiagnosticSettings,
8088
PolicyContract,
8189
PolicyDescriptionContract,
@@ -84,11 +92,17 @@ export {
8492
PortalSettingsContract,
8593
PortalSigninSettings,
8694
PortalSignupSettings,
95+
PrivateEndpoint,
96+
PrivateEndpointConnection,
97+
PrivateLinkResource,
98+
PrivateLinkServiceConnectionState,
8799
ProductContract,
100+
ProxyResource,
88101
RecipientEmailContract,
89102
RecipientsContractProperties,
90103
RecipientUserContract,
91104
RegistrationDelegationSettingsProperties,
105+
RemotePrivateEndpointConnectionWrapper,
92106
RepresentationContract,
93107
RequestContract,
94108
Resource,
@@ -99,11 +113,14 @@ export {
99113
SubscriptionContract,
100114
SubscriptionKeyParameterNamesContract,
101115
SubscriptionsDelegationSettingsProperties,
116+
SystemData,
102117
TagContract,
103118
TagDescriptionContract,
119+
TenantConfigurationSyncStateContract,
104120
TenantSettingsContract,
105121
TermsOfServiceProperties,
106122
TokenBodyParameterContract,
123+
TrackedResource,
107124
UserContract,
108125
UserIdentityContract,
109126
UserIdentityProperties,

sdk/apimanagement/arm-apimanagement/src/models/apiIssueAttachmentMappers.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@
99
export {
1010
AccessInformationContract,
1111
AdditionalLocation,
12+
ApiContactInformation,
1213
ApiContract,
1314
ApiIssueAttachmentCreateOrUpdateHeaders,
1415
ApiIssueAttachmentGetEntityTagHeaders,
1516
ApiIssueAttachmentGetHeaders,
17+
ApiLicenseInformation,
1618
ApiManagementServiceIdentity,
1719
ApiManagementServiceResource,
1820
ApiManagementServiceSkuProperties,
@@ -22,10 +24,12 @@ export {
2224
ApiVersionConstraint,
2325
ApiVersionSetContract,
2426
ApiVersionSetContractDetails,
27+
ArmIdWrapper,
2528
AssociationContract,
2629
AuthenticationSettingsContract,
2730
AuthorizationServerContract,
2831
AuthorizationServerUpdateContract,
32+
AzureEntityResource,
2933
BackendAuthorizationHeaderCredentials,
3034
BackendContract,
3135
BackendCredentialsContract,
@@ -50,6 +54,7 @@ export {
5054
EmailTemplateParametersContractProperties,
5155
ErrorFieldContract,
5256
ErrorResponse,
57+
ErrorResponseBody,
5358
GatewayCertificateAuthorityContract,
5459
GatewayContract,
5560
GatewayHostnameConfigurationContract,
@@ -74,7 +79,10 @@ export {
7479
OpenIdAuthenticationSettingsContract,
7580
OpenidConnectProviderContract,
7681
OperationContract,
82+
OperationResultContract,
83+
OperationResultLogItemContract,
7784
ParameterContract,
85+
ParameterExampleContract,
7886
PipelineDiagnosticSettings,
7987
PolicyContract,
8088
PolicyDescriptionContract,
@@ -83,11 +91,17 @@ export {
8391
PortalSettingsContract,
8492
PortalSigninSettings,
8593
PortalSignupSettings,
94+
PrivateEndpoint,
95+
PrivateEndpointConnection,
96+
PrivateLinkResource,
97+
PrivateLinkServiceConnectionState,
8698
ProductContract,
99+
ProxyResource,
87100
RecipientEmailContract,
88101
RecipientsContractProperties,
89102
RecipientUserContract,
90103
RegistrationDelegationSettingsProperties,
104+
RemotePrivateEndpointConnectionWrapper,
91105
RepresentationContract,
92106
RequestContract,
93107
Resource,
@@ -98,11 +112,14 @@ export {
98112
SubscriptionContract,
99113
SubscriptionKeyParameterNamesContract,
100114
SubscriptionsDelegationSettingsProperties,
115+
SystemData,
101116
TagContract,
102117
TagDescriptionContract,
118+
TenantConfigurationSyncStateContract,
103119
TenantSettingsContract,
104120
TermsOfServiceProperties,
105121
TokenBodyParameterContract,
122+
TrackedResource,
106123
UserContract,
107124
UserIdentityContract,
108125
UserIdentityProperties,

0 commit comments

Comments
 (0)