Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.

[AutoPR] apimanagement/resource-manager #2651

Merged
9 commits merged into from
Jul 27, 2018
42 changes: 21 additions & 21 deletions lib/services/apimanagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
The MIT License (MIT)
Copyright (c) 2018 Microsoft
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
86 changes: 43 additions & 43 deletions lib/services/apimanagement/README.md
Original file line number Diff line number Diff line change
@@ -1,43 +1,43 @@
---
uid: azure-arm-apimanagement
summary: *content

---
# Microsoft Azure SDK for Node.js - ApiManagementClient
This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**

## Features


## How to Install

```bash
npm install azure-arm-apimanagement
```

## How to use

### Authentication, client creation and listByService policy as an example.

```javascript
const msRestAzure = require("ms-rest-azure");
const ApiManagementClient = require("azure-arm-apimanagement");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new ApiManagementClient(creds, subscriptionId);
const resourceGroupName = "testresourceGroupName";
const serviceName = "testserviceName";
const scope = "Tenant";
return client.policy.listByService(resourceGroupName, serviceName, scope).then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error ocurred:');
console.dir(err, {depth: null, colors: true});
});

## Related projects

- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)
---
uid: azure-arm-apimanagement
summary: *content
---
# Microsoft Azure SDK for Node.js - ApiManagementClient
This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**
## Features
## How to Install
```bash
npm install azure-arm-apimanagement
```
## How to use
### Authentication, client creation and listByService policy as an example.
```javascript
const msRestAzure = require("ms-rest-azure");
const ApiManagementClient = require("azure-arm-apimanagement");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new ApiManagementClient(creds, subscriptionId);
const resourceGroupName = "testresourceGroupName";
const serviceName = "testserviceName";
const scope = "Tenant";
return client.policy.listByService(resourceGroupName, serviceName, scope).then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error occurred:');
console.dir(err, {depth: null, colors: true});
});
## Related projects
- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)
11 changes: 6 additions & 5 deletions lib/services/apimanagement/lib/apiManagementClient.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ export default class ApiManagementClient extends AzureServiceClient {
*
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy
*
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response.
* @param {string} [options.acceptLanguage] - The preferred language for the response.
*
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30.
* @param {number} [options.longRunningOperationRetryTimeout] - The retry timeout in seconds for Long Running Operations. Default value is 30.
*
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.
* @param {boolean} [options.generateClientRequestId] - Whether a unique x-ms-client-request-id should be generated. When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.
*
*/
constructor(credentials: ServiceClientCredentials, subscriptionId: string, baseUri?: string, options?: AzureServiceClientOptions);
Expand Down Expand Up @@ -68,14 +68,15 @@ export default class ApiManagementClient extends AzureServiceClient {
apiPolicy: operations.ApiPolicy;
apiSchema: operations.ApiSchema;
apiDiagnostic: operations.ApiDiagnostic;
apiDiagnosticLogger: operations.ApiDiagnosticLogger;
apiIssue: operations.ApiIssue;
apiIssueComment: operations.ApiIssueComment;
apiIssueAttachment: operations.ApiIssueAttachment;
authorizationServer: operations.AuthorizationServer;
backend: operations.Backend;
certificate: operations.Certificate;
apiManagementOperations: operations.ApiManagementOperations;
apiManagementService: operations.ApiManagementService;
diagnostic: operations.Diagnostic;
diagnosticLogger: operations.DiagnosticLogger;
emailTemplate: operations.EmailTemplate;
group: operations.Group;
groupUser: operations.GroupUser;
Expand Down
13 changes: 7 additions & 6 deletions lib/services/apimanagement/lib/apiManagementClient.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ class ApiManagementClient extends ServiceClient {
* @param {object} [options.requestOptions] - Options for the underlying request object
* {@link https://github.com/request/request#requestoptions-callback Options doc}
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response.
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30.
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.
* @param {string} [options.acceptLanguage] - The preferred language for the response.
* @param {number} [options.longRunningOperationRetryTimeout] - The retry timeout in seconds for Long Running Operations. Default value is 30.
* @param {boolean} [options.generateClientRequestId] - Whether a unique x-ms-client-request-id should be generated. When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.
*/
constructor(credentials, subscriptionId, baseUri, options) {
if (credentials === null || credentials === undefined) {
Expand All @@ -50,7 +50,7 @@ class ApiManagementClient extends ServiceClient {

super(credentials, options);

this.apiVersion = '2018-01-01';
this.apiVersion = '2018-06-01-preview';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.generateClientRequestId = true;
Expand Down Expand Up @@ -84,14 +84,15 @@ class ApiManagementClient extends ServiceClient {
this.apiPolicy = new operations.ApiPolicy(this);
this.apiSchema = new operations.ApiSchema(this);
this.apiDiagnostic = new operations.ApiDiagnostic(this);
this.apiDiagnosticLogger = new operations.ApiDiagnosticLogger(this);
this.apiIssue = new operations.ApiIssue(this);
this.apiIssueComment = new operations.ApiIssueComment(this);
this.apiIssueAttachment = new operations.ApiIssueAttachment(this);
this.authorizationServer = new operations.AuthorizationServer(this);
this.backend = new operations.Backend(this);
this.certificate = new operations.Certificate(this);
this.apiManagementOperations = new operations.ApiManagementOperations(this);
this.apiManagementService = new operations.ApiManagementService(this);
this.diagnostic = new operations.Diagnostic(this);
this.diagnosticLogger = new operations.DiagnosticLogger(this);
this.emailTemplate = new operations.EmailTemplate(this);
this.group = new operations.Group(this);
this.groupUser = new operations.GroupUser(this);
Expand Down
24 changes: 22 additions & 2 deletions lib/services/apimanagement/lib/models/additionalLocation.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,13 @@ class AdditionalLocation {
* 'Developer', 'Standard', 'Premium', 'Basic'
* @member {number} [sku.capacity] Capacity of the SKU (number of deployed
* units of the SKU). The default value is 1.
* @member {array} [publicIPAddresses] Static IP addresses of the location's
* virtual machines.
* @member {array} [publicIPAddresses] Public Static Load Balanced IP
* addresses of the API Management service in the additional location.
* Available only for Basic, Standard and Premium SKU.
* @member {array} [privateIPAddresses] Private Static Load Balanced IP
* addresses of the API Management service which is deployed in an Internal
* Virtual Network in a particular additional location. Available only for
* Basic, Standard and Premium SKU.
* @member {object} [virtualNetworkConfiguration] Virtual network
* configuration for the location.
* @member {string} [virtualNetworkConfiguration.vnetid] The virtual network
Expand Down Expand Up @@ -87,6 +92,21 @@ class AdditionalLocation {
}
}
},
privateIPAddresses: {
required: false,
readOnly: true,
serializedName: 'privateIPAddresses',
type: {
name: 'Sequence',
element: {
required: false,
serializedName: 'StringElementType',
type: {
name: 'String'
}
}
}
},
virtualNetworkConfiguration: {
required: false,
serializedName: 'virtualNetworkConfiguration',
Expand Down
2 changes: 2 additions & 0 deletions lib/services/apimanagement/lib/models/apiCollection.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class ApiCollection extends Array {
modelProperties: {
value: {
required: false,
readOnly: true,
serializedName: '',
type: {
name: 'Sequence',
Expand All @@ -53,6 +54,7 @@ class ApiCollection extends Array {
},
nextLink: {
required: false,
readOnly: true,
serializedName: 'nextLink',
type: {
name: 'String'
Expand Down
22 changes: 22 additions & 0 deletions lib/services/apimanagement/lib/models/apiContract.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ class ApiContract extends models['Resource'] {
* revision.
* @member {boolean} [isOnline] Indicates if API revision is accessible via
* the gateway.
* @member {string} [apiRevisionDescription] Description of the Api Revision.
* @member {string} [apiVersionDescription] Description of the Api Version.
* @member {string} [apiVersionSetId] A resource identifier for the related
* ApiVersionSet.
* @member {string} [displayName] API name.
Expand Down Expand Up @@ -179,6 +181,26 @@ class ApiContract extends models['Resource'] {
name: 'Boolean'
}
},
apiRevisionDescription: {
required: false,
serializedName: 'properties.apiRevisionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionDescription: {
required: false,
serializedName: 'properties.apiVersionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionSetId: {
required: false,
serializedName: 'properties.apiVersionSetId',
Expand Down
20 changes: 20 additions & 0 deletions lib/services/apimanagement/lib/models/apiContractProperties.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,26 @@ class ApiContractProperties extends models['ApiEntityBaseContract'] {
name: 'Boolean'
}
},
apiRevisionDescription: {
required: false,
serializedName: 'apiRevisionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionDescription: {
required: false,
serializedName: 'apiVersionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionSetId: {
required: false,
serializedName: 'apiVersionSetId',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ class ApiCreateOrUpdateParameter {
* revision.
* @member {boolean} [isOnline] Indicates if API revision is accessible via
* the gateway.
* @member {string} [apiRevisionDescription] Description of the Api Revision.
* @member {string} [apiVersionDescription] Description of the Api Version.
* @member {string} [apiVersionSetId] A resource identifier for the related
* ApiVersionSet.
* @member {string} [displayName] API name.
Expand Down Expand Up @@ -167,6 +169,26 @@ class ApiCreateOrUpdateParameter {
name: 'Boolean'
}
},
apiRevisionDescription: {
required: false,
serializedName: 'properties.apiRevisionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionDescription: {
required: false,
serializedName: 'properties.apiVersionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionSetId: {
required: false,
serializedName: 'properties.apiVersionSetId',
Expand Down
22 changes: 22 additions & 0 deletions lib/services/apimanagement/lib/models/apiEntityBaseContract.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ class ApiEntityBaseContract {
* revision.
* @member {boolean} [isOnline] Indicates if API revision is accessible via
* the gateway.
* @member {string} [apiRevisionDescription] Description of the Api Revision.
* @member {string} [apiVersionDescription] Description of the Api Version.
* @member {string} [apiVersionSetId] A resource identifier for the related
* ApiVersionSet.
*/
Expand Down Expand Up @@ -131,6 +133,26 @@ class ApiEntityBaseContract {
name: 'Boolean'
}
},
apiRevisionDescription: {
required: false,
serializedName: 'apiRevisionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionDescription: {
required: false,
serializedName: 'apiVersionDescription',
constraints: {
MaxLength: 256
},
type: {
name: 'String'
}
},
apiVersionSetId: {
required: false,
serializedName: 'apiVersionSetId',
Expand Down
Loading