Skip to content

Commit 742d70f

Browse files
author
SDKAuto
committed
CodeGen from PR 15001 in Azure/azure-rest-api-specs
Merge e8f1edfd9b18970a5cd22a9d77dcb3fec8782205 into 3cf8aa90fbdf15379f62a1e8e0c3dcbd9c4d46af
1 parent b8da289 commit 742d70f

34 files changed

+589
-212
lines changed

sdk/frontdoor/arm-frontdoor/LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2020 Microsoft
3+
Copyright (c) 2021 Microsoft
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

sdk/frontdoor/arm-frontdoor/README.md

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

3-
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for FrontDoorManagementClient.
3+
This package contains an isomorphic SDK (runs both in node.js and in browsers) for FrontDoorManagementClient.
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-frontdoor @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 list networkExperimentProfiles as an example written in JavaScript.
4240

4341
##### Sample code
@@ -51,7 +49,6 @@ const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];
5149
// Please note that you can also use credentials from the `@azure/ms-rest-nodeauth` package instead.
5250
const creds = new DefaultAzureCredential();
5351
const client = new FrontDoorManagementClient(creds, subscriptionId);
54-
5552
client.networkExperimentProfiles.list().then((result) => {
5653
console.log("The result is:");
5754
console.log(result);
@@ -86,7 +83,7 @@ In browser applications, we recommend using the `InteractiveBrowserCredential` t
8683
const credential = new InteractiveBrowserCredential(
8784
{
8885
clientId: "<client id for your Azure AD app>",
89-
tenantId: "<optional tenant for your organization>"
86+
tenant: "<optional tenant for your organization>"
9087
});
9188
const client = new Azure.ArmFrontdoor.FrontDoorManagementClient(creds, subscriptionId);
9289
client.networkExperimentProfiles.list().then((result) => {

sdk/frontdoor/arm-frontdoor/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -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/main/sdk/frontdoor/arm-frontdoor",
30+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/frontdoor/arm-frontdoor",
3131
"repository": {
3232
"type": "git",
3333
"url": "https://github.com/Azure/azure-sdk-for-js.git"

sdk/frontdoor/arm-frontdoor/rollup.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ const config = {
2121
"@azure/ms-rest-azure-js": "msRestAzure"
2222
},
2323
banner: `/*
24-
* Copyright (c) Microsoft Corporation. All rights reserved.
25-
* Licensed under the MIT License. See License.txt in the project root for license information.
24+
* Copyright (c) Microsoft Corporation.
25+
* Licensed under the MIT License.
2626
*
2727
* Code generated by Microsoft (R) AutoRest Code Generator.
2828
* Changes may cause incorrect behavior and will be lost if the code is regenerated.

sdk/frontdoor/arm-frontdoor/src/frontDoorManagementClient.ts

Lines changed: 6 additions & 117 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/*
2-
* Copyright (c) Microsoft Corporation. All rights reserved.
3-
* Licensed under the MIT License. See License.txt in the project root for
4-
* license information.
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
54
*
65
* Code generated by Microsoft (R) AutoRest Code Generator.
76
* Changes may cause incorrect behavior and will be lost if the code is
@@ -12,7 +11,6 @@ import * as msRest from "@azure/ms-rest-js";
1211
import { TokenCredential } from "@azure/core-auth";
1312
import * as Models from "./models";
1413
import * as Mappers from "./models/mappers";
15-
import * as Parameters from "./models/parameters";
1614
import * as operations from "./operations";
1715
import { FrontDoorManagementClientContext } from "./frontDoorManagementClientContext";
1816

@@ -23,6 +21,8 @@ class FrontDoorManagementClient extends FrontDoorManagementClientContext {
2321
preconfiguredEndpoints: operations.PreconfiguredEndpoints;
2422
experiments: operations.Experiments;
2523
reports: operations.Reports;
24+
frontDoorNameAvailability: operations.FrontDoorNameAvailability;
25+
frontDoorNameAvailabilityWithSubscription: operations.FrontDoorNameAvailabilityWithSubscription;
2626
frontDoors: operations.FrontDoors;
2727
frontendEndpoints: operations.FrontendEndpoints;
2828
endpoints: operations.Endpoints;
@@ -48,129 +48,18 @@ class FrontDoorManagementClient extends FrontDoorManagementClientContext {
4848
this.preconfiguredEndpoints = new operations.PreconfiguredEndpoints(this);
4949
this.experiments = new operations.Experiments(this);
5050
this.reports = new operations.Reports(this);
51+
this.frontDoorNameAvailability = new operations.FrontDoorNameAvailability(this);
52+
this.frontDoorNameAvailabilityWithSubscription = new operations.FrontDoorNameAvailabilityWithSubscription(this);
5153
this.frontDoors = new operations.FrontDoors(this);
5254
this.frontendEndpoints = new operations.FrontendEndpoints(this);
5355
this.endpoints = new operations.Endpoints(this);
5456
this.rulesEngines = new operations.RulesEngines(this);
5557
this.policies = new operations.Policies(this);
5658
this.managedRuleSets = new operations.ManagedRuleSets(this);
5759
}
58-
59-
/**
60-
* Check the availability of a Front Door resource name.
61-
* @param checkFrontDoorNameAvailabilityInput Input to check.
62-
* @param [options] The optional parameters
63-
* @returns Promise<Models.CheckFrontDoorNameAvailabilityResponse>
64-
*/
65-
checkFrontDoorNameAvailability(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options?: msRest.RequestOptionsBase): Promise<Models.CheckFrontDoorNameAvailabilityResponse>;
66-
/**
67-
* @param checkFrontDoorNameAvailabilityInput Input to check.
68-
* @param callback The callback
69-
*/
70-
checkFrontDoorNameAvailability(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, callback: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): void;
71-
/**
72-
* @param checkFrontDoorNameAvailabilityInput Input to check.
73-
* @param options The optional parameters
74-
* @param callback The callback
75-
*/
76-
checkFrontDoorNameAvailability(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): void;
77-
checkFrontDoorNameAvailability(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>, callback?: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): Promise<Models.CheckFrontDoorNameAvailabilityResponse> {
78-
return this.sendOperationRequest(
79-
{
80-
checkFrontDoorNameAvailabilityInput,
81-
options
82-
},
83-
checkFrontDoorNameAvailabilityOperationSpec,
84-
callback) as Promise<Models.CheckFrontDoorNameAvailabilityResponse>;
85-
}
86-
87-
/**
88-
* Check the availability of a Front Door subdomain.
89-
* @param checkFrontDoorNameAvailabilityInput Input to check.
90-
* @param [options] The optional parameters
91-
* @returns Promise<Models.CheckFrontDoorNameAvailabilityWithSubscriptionResponse>
92-
*/
93-
checkFrontDoorNameAvailabilityWithSubscription(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options?: msRest.RequestOptionsBase): Promise<Models.CheckFrontDoorNameAvailabilityWithSubscriptionResponse>;
94-
/**
95-
* @param checkFrontDoorNameAvailabilityInput Input to check.
96-
* @param callback The callback
97-
*/
98-
checkFrontDoorNameAvailabilityWithSubscription(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, callback: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): void;
99-
/**
100-
* @param checkFrontDoorNameAvailabilityInput Input to check.
101-
* @param options The optional parameters
102-
* @param callback The callback
103-
*/
104-
checkFrontDoorNameAvailabilityWithSubscription(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): void;
105-
checkFrontDoorNameAvailabilityWithSubscription(checkFrontDoorNameAvailabilityInput: Models.CheckNameAvailabilityInput, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>, callback?: msRest.ServiceCallback<Models.CheckNameAvailabilityOutput>): Promise<Models.CheckFrontDoorNameAvailabilityWithSubscriptionResponse> {
106-
return this.sendOperationRequest(
107-
{
108-
checkFrontDoorNameAvailabilityInput,
109-
options
110-
},
111-
checkFrontDoorNameAvailabilityWithSubscriptionOperationSpec,
112-
callback) as Promise<Models.CheckFrontDoorNameAvailabilityWithSubscriptionResponse>;
113-
}
11460
}
11561

11662
// Operation Specifications
117-
const serializer = new msRest.Serializer(Mappers);
118-
const checkFrontDoorNameAvailabilityOperationSpec: msRest.OperationSpec = {
119-
httpMethod: "POST",
120-
path: "providers/Microsoft.Network/checkFrontDoorNameAvailability",
121-
queryParameters: [
122-
Parameters.apiVersion1
123-
],
124-
headerParameters: [
125-
Parameters.acceptLanguage
126-
],
127-
requestBody: {
128-
parameterPath: "checkFrontDoorNameAvailabilityInput",
129-
mapper: {
130-
...Mappers.CheckNameAvailabilityInput,
131-
required: true
132-
}
133-
},
134-
responses: {
135-
200: {
136-
bodyMapper: Mappers.CheckNameAvailabilityOutput
137-
},
138-
default: {
139-
bodyMapper: Mappers.ErrorResponse
140-
}
141-
},
142-
serializer
143-
};
144-
145-
const checkFrontDoorNameAvailabilityWithSubscriptionOperationSpec: msRest.OperationSpec = {
146-
httpMethod: "POST",
147-
path: "subscriptions/{subscriptionId}/providers/Microsoft.Network/checkFrontDoorNameAvailability",
148-
urlParameters: [
149-
Parameters.subscriptionId
150-
],
151-
queryParameters: [
152-
Parameters.apiVersion1
153-
],
154-
headerParameters: [
155-
Parameters.acceptLanguage
156-
],
157-
requestBody: {
158-
parameterPath: "checkFrontDoorNameAvailabilityInput",
159-
mapper: {
160-
...Mappers.CheckNameAvailabilityInput,
161-
required: true
162-
}
163-
},
164-
responses: {
165-
200: {
166-
bodyMapper: Mappers.CheckNameAvailabilityOutput
167-
},
168-
default: {
169-
bodyMapper: Mappers.ErrorResponse
170-
}
171-
},
172-
serializer
173-
};
17463

17564
export {
17665
FrontDoorManagementClient,

sdk/frontdoor/arm-frontdoor/src/frontDoorManagementClientContext.ts

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/*
2-
* Copyright (c) Microsoft Corporation. All rights reserved.
3-
* Licensed under the MIT License. See License.txt in the project root for
4-
* license information.
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
54
*
65
* Code generated by Microsoft (R) AutoRest Code Generator.
76
* Changes may cause incorrect behavior and will be lost if the code is
@@ -10,8 +9,8 @@
109

1110
import * as Models from "./models";
1211
import * as msRest from "@azure/ms-rest-js";
13-
import { TokenCredential } from "@azure/core-auth";
1412
import * as msRestAzure from "@azure/ms-rest-azure-js";
13+
import { TokenCredential } from "@azure/core-auth";
1514

1615
const packageName = "@azure/arm-frontdoor";
1716
const packageVersion = "4.1.0";
@@ -43,7 +42,7 @@ export class FrontDoorManagementClientContext extends msRestAzure.AzureServiceCl
4342
if (!options) {
4443
options = {};
4544
}
46-
if(!options.userAgent) {
45+
if (!options.userAgent) {
4746
const defaultUserAgent = msRestAzure.getDefaultUserAgentValue();
4847
options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
4948
}
@@ -57,10 +56,10 @@ export class FrontDoorManagementClientContext extends msRestAzure.AzureServiceCl
5756
this.credentials = credentials;
5857
this.subscriptionId = subscriptionId;
5958

60-
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
59+
if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
6160
this.acceptLanguage = options.acceptLanguage;
6261
}
63-
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
62+
if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
6463
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout;
6564
}
6665
}

sdk/frontdoor/arm-frontdoor/src/models/endpointsMappers.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (c) Microsoft Corporation. All rights reserved.
3-
* Licensed under the MIT License. See License.txt in the project root for license information.
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
44
*
55
* Code generated by Microsoft (R) AutoRest Code Generator.
66
* Changes may cause incorrect behavior and will be lost if the code is regenerated.

sdk/frontdoor/arm-frontdoor/src/models/experimentsMappers.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (c) Microsoft Corporation. All rights reserved.
3-
* Licensed under the MIT License. See License.txt in the project root for license information.
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
44
*
55
* Code generated by Microsoft (R) AutoRest Code Generator.
66
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -48,10 +48,14 @@ export {
4848
Resource,
4949
RouteConfiguration,
5050
RoutingRule,
51+
RoutingRuleLink,
52+
RoutingRuleUpdateParametersWebApplicationFirewallPolicyLink,
5153
RulesEngine,
5254
RulesEngineAction,
5355
RulesEngineMatchCondition,
5456
RulesEngineRule,
57+
SecurityPolicyLink,
58+
Sku,
5559
SubResource,
5660
Timeseries,
5761
TimeseriesDataPoint,
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
discriminators,
11+
CheckNameAvailabilityInput,
12+
CheckNameAvailabilityOutput,
13+
ErrorResponse
14+
} from "../models/mappers";
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
discriminators,
11+
CheckNameAvailabilityInput,
12+
CheckNameAvailabilityOutput,
13+
ErrorResponse
14+
} from "../models/mappers";

0 commit comments

Comments
 (0)